[Fixed] Map15 door + decorations physics weirdness
Moderator: GZDoom Developers
Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
Map15 door + decorations physics weirdness
Three decorations in Doom2 map15 bounce up & down when I open/close the door located at 1400,-3300. View a demo (recorded using ZDoom 2.0.63) of this here.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
http://forum.zdoom.org/viewtopic.php?t=1287
But thanks to pointing out a position in a level where it can be tested. It's probably just a minor stupid thing...
But thanks to pointing out a position in a level where it can be tested. It's probably just a minor stupid thing...
Oh great... that links to a thread which links to a thread which links to Telebase.wad, one of the most god-awful wads ever made.Graf Zahl wrote:http://forum.zdoom.org/viewtopic.php?t=1287

- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
There are actually 2 bugs at work here:
This code in P_CeilingRaise is responsible for the gib moving up while the door raises:
The gib on the right side on the inside of the door overlaps with the torch nearby. So while raising the door the code tries to put the gib at the highest possible position below its 'floor' (the top of the torch). The problem is that this code only makes sense for objects which have the MF2_PASSMOBJ flag set. For decorations (especially non-solid ones) it should never be executed.
The second effect (The gib jumping up while the door is moving down) is caused by the following incorrect check in P_PushDown:
It should be '<=' instead of '<'.
Anyway, P_PushDown should always check whether the z-position it wants to place an object in is actually lower than its current z-position. It doesn't do that either.
This code in P_CeilingRaise is responsible for the gib moving up while the door raises:
Code: Select all
else if (!isgood && thing->z + thing->height < thing->ceilingz )
{
if (!P_TestMobjZ (thing) && onmobj->z <= thing->z)
{
thing->z = MIN (thing->ceilingz - thing->height,
onmobj->z + onmobj->height);
}
}
The second effect (The gib jumping up while the door is moving down) is caused by the following incorrect check in P_PushDown:
Code: Select all
if (thing->z < thing->floorz)
{
return 1;
}
Anyway, P_PushDown should always check whether the z-position it wants to place an object in is actually lower than its current z-position. It doesn't do that either.
Last edited by Graf Zahl on Sun Feb 15, 2004 1:23 pm, edited 1 time in total.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Xaser wrote:Oh great... that links to a thread which links to a thread which links to Telebase.wad, one of the most god-awful wads ever made.Graf Zahl wrote:http://forum.zdoom.org/viewtopic.php?t=1287
It's the same bug so the link is valid, don't you think?

Yes, but did you HAVE to link to telebase.wad? Well, I guess you did, so I'll shut up now.Graf Zahl wrote:Xaser wrote:Oh great... that links to a thread which links to a thread which links to Telebase.wad, one of the most god-awful wads ever made.Graf Zahl wrote:http://forum.zdoom.org/viewtopic.php?t=1287
It's the same bug so the link is valid, don't you think?
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Xaser wrote: Yes, but did you HAVE to link to telebase.wad? Well, I guess you did, so I'll shut up now.
A) What's your problem with Telebase? (I don't know this level.)
B) The bug in Telebase will not be fixed by this. Overlapping monsters in a map is just sloppy mapping and the code I mentioned is designed to unblock them. (But maybe it's a good idea to limit this only to monsters which overlap to such a degree that they cannot move out of each other.)
For decorations it's another matter. They can overlap and overlapping must be allowed at any time.
A) I Made Telebase. It's a very bad level, and it brings back bad memories.Graf Zahl wrote:Xaser wrote: Yes, but did you HAVE to link to telebase.wad? Well, I guess you did, so I'll shut up now.
A) What's your problem with Telebase? (I don't know this level.)
B) The bug in Telebase will not be fixed by this. Overlapping monsters in a map is just sloppy mapping and the code I mentioned is designed to unblock them. (But maybe it's a good idea to limit this only to monsters which overlap to such a degree that they cannot move out of each other.)
For decorations it's another matter. They can overlap and overlapping must be allowed at any time.

B) Darnit. That baddie stuck together thing is driving me mad! Then again, in that case, I gues it doesn't affect me that much.

- Cutmanmike
- Posts: 11353
- Joined: Mon Oct 06, 2003 3:41 pm
- Operating System Version (Optional): Windows 10
- Location: United Kingdom
- Contact:
Hey, we were all 13 once...
BTW, be ashamed of this, you supposed "programmer!!"
BTW, be ashamed of this, you supposed "programmer!!"
Graf Zahl wrote:The second effect (The gib jumping up while the door is moving down is caused by the following incorrect check in P_PushDown:
Code: Select all
C_ERR 215: Unexpected end-of-line. Expected: ')'