FLATSPRITE discussion

Advanced OpenGL source port fork from ZDoom, picking up where ZDoomGL left off.
[Home] [Download] [Git builds (Win)] [Git builds (Mac)] [Wiki] [Repo] [Bugs&Suggestions]

Moderator: Graf Zahl

Major Cooke
Developer
Developer
Posts: 240
Joined: Wed Mar 04, 2009 19:25

Re: FLATSPRITE discussion

Post by Major Cooke »

Code: Select all

		float rightfac = -r.left;
		float leftfac = rightfac - r.width;
		float bottomfac = -r.top;
		float topfac = bottomfac - r.height;

		case RF_FLATSPRITE:
		{	//needs careful rethinking
			x1 = x + leftfac;
			x2 = x + rightfac;
			y1 = y - bottomfac;
			y2 = y - topfac;
		}
Going off of what right and leftfac were, does this look correct? I just tried intermixing them a bit and had no change in results at all.

I've pushed the result so you can see if I'm missing anything.

Updated test actor:

Code: Select all

Actor A
{
	+NOINTERACTION
	+ROLLSPRITE
	+FLATSPRITE
	+DONTFLIP
	+SPRITEANGLE
	//+ROLLCENTER
	States
	{
	Spawn:
		CYBR A 1 
		{
			angle += 1;
			angle %= 360;
			pitch += 1;
			pitch %= 360;
		}
		Loop
	}
}
Instead of pivoting around the bottom and rotating it along, it puts it off to the side instead... Hmm...
I still don't know what to do after this point however and I've hit a dead stop on how to fix this rotated issue. I.e. the cyberdemon's supposed to be pivoting from the hooves, not the wired arm.
Major Cooke
Developer
Developer
Posts: 240
Joined: Wed Mar 04, 2009 19:25

Re: FLATSPRITE discussion

Post by Major Cooke »

It's done. New thread here.
Major Cooke
Developer
Developer
Posts: 240
Joined: Wed Mar 04, 2009 19:25

Re: FLATSPRITE discussion

Post by Major Cooke »

So rather than reintroduce DONTFLIP, I thought this would be a good idea that benefits both (G)ZDoom. That could be our DONTFLIP in a nutshell with more flexibility.
Locked

Return to “GZDoom”