Spoiler: nullptr traces1. Grab D4D here http://forum.zdoom.org/viewtopic.php?f=19&t=52164
2. Give D4Chaingun + SovietToken + SovietActive
3. Chasecam on
4. Start firing. Bam.
Moderator: Graf Zahl
Spoiler: nullptr traces1. Grab D4D here http://forum.zdoom.org/viewtopic.php?f=19&t=52164
I'm not sure what you mean by actual rendering values. Do you mean things similar to how the billboard sprites are handled using xcenter and all?Graf Zahl wrote:Yes, of course this can happen. With the chasecam on there is no viewactor. And even disregarding that, the viewactor's position is not necessarily the actual camera position for the current frame. If you want to do checks against the camera, do not check against ViewActor but against ViewPos. And you should check the actual rendering values, not the actor they are derived from. This also needs to take into account what pivot you are using for rotation.
And I'm honestly just as confused as you are, because I didn't do most of this work. I simply maintained it for the people who made it (although the noflip is my fault).Graf Zahl wrote:Essentially the code to determine flipping does not look correct at all. What this really needs to do is to check is that the actual camera point (ViewPos) is above or below the tilted sprite. To be honest, I have no clue what you are actually doing there.
When I last tried it a while ago, I think it did something to the decals. I'll check again to see if that's still the case.Graf Zahl wrote:Which also begs the question: Why is the 'noflip' check only present for flat sprites and not for wall sprites?
It's actually quite simple:Major Cooke wrote:I'm not sure what you mean by actual rendering values. Do you mean things similar to how the billboard sprites are handled using xcenter and all?Graf Zahl wrote:Yes, of course this can happen. With the chasecam on there is no viewactor. And even disregarding that, the viewactor's position is not necessarily the actual camera position for the current frame. If you want to do checks against the camera, do not check against ViewActor but against ViewPos. And you should check the actual rendering values, not the actor they are derived from. This also needs to take into account what pivot you are using for rotation.
Spoiler: ImageThat splitting issue has been prevalent especially with camera facing sprites and has been existing from said cam-facing sprites introduction.
Code: Select all
else if (spritetype == RF_WALLSPRITE)
{
mat.Rotate(0, 1, 0, 0);
if (drawRollSpriteActor)
{
if (useOffsets) mat.Translate(xx, zz, yy); //Handled here
mat.Rotate(yawvecX, 0, yawvecY, rollDegrees);
if (useOffsets) mat.Translate(-xx, -zz, -yy); //And here
}
}