Posted: Sun Aug 21, 2022 12:14 am Post subject: Weird "things" collision in zdaemon
We had a problem on TNS 575(Altars of Madness) on map12 near the exit area.
The normal behavior:
Killing the cyberdemon, a looped barrel will teleport to the cyberdemon's sector and a voodoo doll that was previously blocked by the barrel will cross a line that opens a door for the barons and cacodemons to teleport to the last area. Access to a switch will be unlocked to be used by the player to lower a sector and finally go to the exit.
This clever system works fine at first glance, but it will start to fail after some time.
This is the usual case, nothign ground breaking here:
When using scripts, floors or such that push directly east, north, south or west, they are not exactly such. There's most of the time a tiny fractional unit to some other direction. For example, if there's a push floor to east, it is actually pushin mainly to east, but also a fractional unit south. This mean over long period of time things will go a bit out of the "usual line". For example: if you create a map that spawns a rocket with angle 0 (east), and give it only +-1 extra space, it will eventually hit the walls, because it is not going directly east. Here is an example of how the rocket (or the barrel) moves:
Similar thing with the doom guy's movement: There's no angle that let's it go directly north, south, east or west. This tiny "side movement", as it is called in speedrunning, is what allows precise positioning of the player, and is used with glides and other tricks that require high precision.
Funnily enough, this tiny side movement is what I used to zigzag in this other thread I just made (Something off with the player(s) position). Well, I used steeper angles, but the idea is exactly the same.
You can fix a bug like this in a map by not letting the barrel slide too much south or north, thus blocking the tiny side movement. If you are concerned about the object hitting a wall, which will cause the object (barrel in this case) lose 0-100% of the momentum for a frame (making it a bit out of sync potentially), you can use lanterns, candlesticks or some other 'soft' map objects like fences to block the object which won't affect the momentum with collisions.
To be honest, I am not sure if barrels lose momentum identical to players when colliding with a wall, but at least voodoo dolls should.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum