TeleportGroup doesn't rotate velocities

Is there something that doesn't work right in the latest GZDoom? Post about it here.

Moderator: GZDoom Developers

Forum rules
Please construct and post a simple demo whenever possible for all bug reports. Please provide links to everything.

If you can include a wad demonstrating the problem, please do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.

Please make a new topic for every bug. Don't combine multiple bugs into a single topic. Thanks!
User avatar
Eevee
Posts: 592
Joined: Wed Jul 16, 2003 5:26 am
Contact:

TeleportGroup doesn't rotate velocities

Post by Eevee »

TeleportGroup preserves all the teleported actors' positions relative to the source and destination teleport spots, so that if the source and destination have different angles, the actors will be "rotated" as a group.

However, the actors' velocities are not adjusted in any way. So if the player and a demon are charging at each other, and a script uses TeleportGroup to move them in such a way that their orientation is rotated 180°, their momentum will suddenly be pushing them away from each other.

I ran into this when trying to use TeleportGroup to fake a two-way Teleport_Line from a script (as it doesn't quite work right from ACS), and if the two lines were facing in different directions, the actor's own momentum would carry them back into the line and briefly trap them in a teleport loop.

Is this intentional? It's probably too late to retroactively fix now, but the movesource or fog arguments could be expanded into flags.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49056
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: TeleportGroup doesn't rotate velocities

Post by Graf Zahl »

This would have to be an option because changing it unconditionally could seriously mess with some assumptions. Using it from a script should be safe, but you can never discount the possibility that some actor is triggering this from a linedef and teleporting itself, and that would not work correctly.
Post Reply

Return to “Bugs [GZDoom]”