[GZDoom]Flat, Wall, and Roll Sprites v2

Moderator: GZDoom Developers

User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49252
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Graf Zahl »

I'd have to see first what your code does.
User avatar
Major Cooke
Posts: 8218
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Major Cooke »

Currently they're just drawn backwards when viewed from the flipside.

https://drive.google.com/file/d/0B6VLnV ... sp=sharing

If you download and summon FC (including the one here), get his attention and noclip out of a room, he'll chase after you. But when he is turned around, you'll notice his sprite is reversed, so yeah. Was thinking there should definitely be a flag to flip the flipside over whenever viewing it. The effect would still be desired in quite a number of circumstances, naturally, such as still boards.
You do not have the required permissions to view the files attached to this post.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49252
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Graf Zahl »

Can you please explain what the FlatAngle is? Was it absolutely necessary to add a fourth rotation?
User avatar
Major Cooke
Posts: 8218
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Major Cooke »

FlatAngle sets the orientation on which you see the flattest side. This was made to spare the inconvenience of having to create a new sprite for different angles. The leftmost caco in these pics has a FlatAngle of 90. The right has 0.
Image
Image
Seriously, that would be a tremendous pain in the ass to deal with if this property isn't included.

Also:
Image
This is the flipside issue I was describing earlier. Taken directly opposite of the second picture. Due to rotations, this is why I was thinking of including a flag to flip the other side over based on viewer.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49252
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Graf Zahl »

I'm sorry but in its current state I see no point adding this.

First I need to see how this is going to be useful in realistic scenarios. The demo fails to demonstrate the usefulness completely by that stupid looking monster rotation.
Right now I cannot even see how all this stuff works together, so please make a demo WAD that shows the different sprite types in a scenario that you plan to use this in.

Most importantly, make some clear use cases for how the different angles affect the different sprite types.
User avatar
Major Cooke
Posts: 8218
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Major Cooke »

I'll do that in a separate code submission. For now I've removed it entirely. I don't have a lot of time at the moment and I don't want to hold this submission back just because of one property, so I'll give it a proper demonstration in another submission later.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49252
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Graf Zahl »

Just to make it clear: In its current state this is closer to 'no' than to 'added'. I can't say that what I have seen makes much sense to me.
User avatar
Major Cooke
Posts: 8218
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Major Cooke »

Alright, alright. I'll come up with a demonstration wad. Wish Nash was here to present his floor gore system.

In the mean time:
  • ROLLSPRITE: Allows an actor's roll to rotate the actor's actual sprite.
  • FLATSPRITE: Sprites are flat against the floor or ceiling but can be rotated with the angle parameter. Adding ROLLSPRITE to it allows the flat sprite to alter its direction using roll without altering its angle.
  • WALLSPRITE: Similar to Y billboard, except the flatness is in the direction the actor's angle is instead.
  • PITCHFLATSPRITE: Decals on 3D sloped floors, anyone? A combination of flat and wall sprites. Pitch rotates the actor's sprite up and down.
User avatar
Nash
 
 
Posts: 17512
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Nash »

I can only write right now, because I don't have any test material right now, but the two most important one are:

ROLLSPRITE: If you want to do rolling smoke particle effects, this is crucial. This was all over in my private builds before this; but when the AActor rewrite started, I had to revert all of my effects. Can't use shaders because A) I don't know how to write SHADERS B) I need a way to control the effects on a scripting level C) Shaders animation aren't clocked separately so you see all the smokes moving in equal motion in the entire level, which ruins the effect (no randomized individualization)

FLATSPRITE: I needed this because I needed a way to spawn planar actors with full alpha, for clouds in the sky, "damage" or "grunge" decorations for level design, and planar blood effects. MODELDEF flats are no-go because alpha doesn't work correctly on them.

If there's a way to draw MODELDEFS with proper alpha, then FLATSPRITE isn't needed and that leaves only ROLLSPRITE as being crucial, IMO.

Unfortunately I can't build homebrew fork with these features for the time being, but I will prepare some assets (DECORATE and sprites) for MajorCooke to assemble an actual runnable test WAD later today, please wait!
User avatar
Major Cooke
Posts: 8218
Joined: Sun Jan 28, 2007 3:55 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: GZBoomer Town

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Major Cooke »

User avatar
Nash
 
 
Posts: 17512
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Nash »

PM'ed a link to the demo WAD to both Graf Zahl and Major Cooke (because demo WAD contains graphics I don't want to make public).

Contains real-life use cases that I use in my project. The clouds, blood and the smoke in particular are what I use for my project, that wall grunge thing is just for demonstration's sake.
User avatar
The Zombie Killer
Posts: 1528
Joined: Thu Jul 14, 2011 12:06 am
Location: Gold Coast, Queensland, Australia

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by The Zombie Killer »

Nash wrote:If there's a way to draw MODELDEFS with proper alpha, then FLATSPRITE isn't needed and that leaves only ROLLSPRITE as being crucial, IMO.
Nuh-uh! Using models has a performance hitch
It's also hard to get models to a specific size, unless you have a model that is equivalent to 1x1x1 units
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49252
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by Graf Zahl »

Ok, here's my issues:

1. Why are FLATSPRITE and PITCHFLATSPRITE different types? Why not use the pitch in a flat sprite to make the difference?
2. Why the FlatAngle? I absolutely cannot see why this is needed and what purpose it serves.
3. There need to be clear semantics how rotations are to be applied to these different sprite types. Just leaving everything as-is is not going to work for rotated sprites.
User avatar
The Zombie Killer
Posts: 1528
Joined: Thu Jul 14, 2011 12:06 am
Location: Gold Coast, Queensland, Australia

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by The Zombie Killer »

Think it might be worthwhile to just leave the rotation behavior as-is, but add something like a +NOROTATIONS flag?
Although then comes the issue of which rotation would get used when NOROTATIONS is in effect
User avatar
arookas
Posts: 265
Joined: Mon Jan 24, 2011 6:04 pm

Re: [GZDoom]Flat, Wall, and Roll Sprites v2

Post by arookas »

I feel like these would be better as a property (a la RenderStyle, BounceType) than a full-fledged set of Cookeflags™. Their being flags makes it seem you can combine them when logically you shouldn't be able to (a sprite can't be flat- and wall- aligned at the same time). Other than that, I'm all for this!

Return to “Closed Feature Suggestions [GZDoom]”