Quasar
Moderator

Posts: 5158
Registered: 08-00 |
The bullet puff bug was already explained and has been fixed in beta 5. The bug was in the 3D object clipping code, and has nothing to do with the aiming of tracers (that code has not been touched since BOOM, except to fix the spawning of puffs when tracers pass ceilings or floors way back several years ago). Turn off 3D object clipping in beta 4 and you will see that bullet puff behavior becomes normal again.
The error? P_ZMovement has to do an additional clipping pass in case things which are now moving on the Z axis but did NOT move on the X/Y plane during the same gametic are over/under other solid objects. Without an update at this point, said things' floorz and ceilingz fields are incorrect, and the things will be allowed to move up or down into other solid things and then become stuck.
But, the code we had there in betas 3 and 4 (the bug was supposed to be fixed in 4, but time restrictions delayed it until beta 5) clipped things against both other things AND against floors and ceilings their radius contacted. If an inert thing like a bullet puff was moving up along a 2S line, this code would catch it, and force it up to the line's backsector floor height, since things aren't normally allowed to be below floors, and the puff's radius passes through the 2S line. The solution was to create a separate clipping function that only considers other things, and not floor/ceiling heights or linedef crossings. This causes the thing's floorz/ceilingz values to only be updated to more restrictive values acquired from thing-vs-thing clipping. If values from thing-vs-thing clipping aren't more restrictive, then the floorz/ceilingz should already be correct with respect to the rest of the level.
|