Actor Hits Floor CTD

Bugs that have been investigated and resolved somehow.

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.
Post Reply
User avatar
Remmirath
Posts: 2561
Joined: Sun Dec 23, 2007 3:53 am
Graphics Processor: nVidia with Vulkan support
Location: My house
Contact:

Actor Hits Floor CTD

Post by Remmirath »

I've ran into this bug while making a map.

I've setup 2 teleporters with Actor Hits Floor trigger. However if you drop on the teleporter from a height greater than your jump height, ZDoom will crash to desktop.

To reproduce this:

1) Use fly cheat to hover over one of the teleporters, or alternatively, position yourself on the 3D floor placed in the map with said cheat
2) Deactivate cheat and land on one of the teleporters
3) The landing should make ZDoom crash to desktop

I've attached a test map with the bug to this post.

Tested in latest revision.
Attachments
actor_hits_floor_bug.wad
(7.98 KiB) Downloaded 52 times
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49067
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: Actor Hits Floor CTD

Post by Graf Zahl »

Known problem. The sector actions cause the teleports to recursively call each other, eventually causing a stack overflow.
The thing is, it's either this or broken sector actions, fortunately there is a workaround which I added recently to fix an older map using a similar setup.
You have to set compat_teleport in your MAPINFO to restore the behavior of older ZDoom versions, then it will work as you intend.

In general, teleports are dangerous, if there's any chance that a teleport can trigger another teleport. Since they are performed deep inside the movement checking code, this will inevitably lead to a crash.
User avatar
Remmirath
Posts: 2561
Joined: Sun Dec 23, 2007 3:53 am
Graphics Processor: nVidia with Vulkan support
Location: My house
Contact:

Re: Actor Hits Floor CTD

Post by Remmirath »

Thanks for the info, Graf. :)

Since I'm working on a map for Zandronum, I guess the compatibility flag hasn't been ported yet, so I've found a workaround to this using a script with a small delay. This stops the engine from flooding the stack with recursive teleport calls.
User avatar
NeuralStunner
 
 
Posts: 12326
Joined: Tue Jul 21, 2009 12:04 pm
Preferred Pronouns: He/Him
Graphics Processor: nVidia with Vulkan support
Location: capital N, capital S, no space
Contact:

Re: Actor Hits Floor CTD

Post by NeuralStunner »

The method I used: Have the script teleport immediately, followed by a 1-tic delay. Then using ACS_Execute (rather than ExecuteAlways) prevents the script from reactivating during the same tic.
Post Reply

Return to “Closed Bugs [GZDoom]”