Decorations won't float
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Decorations won't float
I'm trying to place a dead marine on the ground and no matter what I set it always falls a little bit through the floor and ends up looking dumb. How do I make the bottom of decorations actually rest on the floor? Setting gravity to 0 does nothing and I can't find anything else that would affect Z axis placement.
- Kappes Buur
-

- Posts: 4200
- Joined: Thu Jul 17, 2003 12:19 am
- Graphics Processor: nVidia (Legacy GZDoom)
- Location: British Columbia, Canada
- Contact:
Re: Decorations won't float
Open your map with Slade3.
Give your sprite(s) appropriate offsets.
Give your sprite(s) appropriate offsets.
Re: Decorations won't float
So is there no way in GZDoom Builder to make a decoration not affected by gravity? I'd really like to avoid having to go into a different editor just for this one decoration to look right.
- Caligari87
- Admin
- Posts: 6241
- Joined: Thu Feb 26, 2004 3:02 pm
- Preferred Pronouns: He/Him
- Contact:
Re: Decorations won't float
You may be misunderstanding what's going on (forgive me if I presume). If your decoration height is at zero (0) then it is resting on the floor, according to physics calculations. Nothing "falls a little bit through" the floor. What you're seeing is a visual issue (mostly a GZDoom one, ZDoom usually isn't affected by this), where the sprite graphic being used for the decoration is not clipped correctly. See [wiki]OpenGL_preferences[/wiki] on the wiki for more details. Relevant section quoted here:
So, your options are:Adjust sprite clipping (Never/Smart/Always/Smarter)
The OpenGL renderer clips off sprites when they go "within" a floor or ceiling; whereas the software renderer overdraws them, a fact which has been willfully exploited to fake certain perspective effects. The result is that many sprites are abruptly cut off when they shouldn't be. The adjustment cheats by adjusting their offset so that they are less cut off.
- Never: Offsets are not adjusted at all.
- Smart: Offsets are only adjusted if they meet certain criteria.
- Always: Offsets are always adjusted if they make the sprite sink in the ground.
- Smarter: Offsets are adjusted in a wider range of cases than with "smart", including if they sink in the ceiling. The amount by which they are adjusted is scaled according to the overall height of the sprite. Very small sprites (such as POB2A0) are visible, contrarily to "smart", even if they are offset in the ceiling (such as CDRP[ABCD]0); and tall sprites (such as TGRNA0) do not seem to hover above the floor, contrarily to "always".
- Change your OpenGL options to adjust the sprite clipping to your liking.
- Adjust that particular sprite offset yourself in Slade. If the sprite is in an IWAD, this may involve copying the sprite to your wad/pk3 or using [wiki]TEXTURES[/wiki], since you should never edit the IWADs
Re: Decorations won't float
Thanks man, setting sprite clipping to "always" fixed the problem for me.