I've come to find that, if a monster is too close to a wall (technically, if any part of their radius overlaps with the wall), the monster needs a minimum movement speed to be able to 'break free', as it were. This minimum speed is equal to how many units of overlap there are. For example, if a monster's radius overlaps the wall by 8 units, the monster will need a speed of 8 or greater to be able to walk away when A_Chase (or similar) is called. Anything slower, and the monster will be anchored down. So, for ZombieMan, who has a speed of 8, a mapper can safely place him up to 8 units 'into' a wall and it will still work in gameplay. I see this done strikingly often. Now, the custom monsters I make are designed to move smoothly, meaning a lower speed property and more frequent calls to A_Chase. Because of this, they are often anchored to walls where the 'vanilla' monsters would have no problem. Does anyone have suggestions on how I can overcome this issue?
Here is a demonstration of monsters getting stuck to walls: http://edthebat.com/doom/slowtest.wad
From left to right, these ZombieMen have speeds of 8 (default), 3, 2, and 1. All have been placed three units 'into' the wall. As you see, anyone with a speed of 3 or higher can move freely. Anyone else is stuck.
Slow monsters stick to walls
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
- Ed the Bat
- Posts: 3060
- Joined: Thu May 03, 2012 1:18 pm
- Graphics Processor: nVidia with Vulkan support
- Location: Maryland, US
- Contact:
Re: Slow monsters stick to walls
+FIXMAPTHINGPOS may help. They also may start non-solid once they start to act, and once it's detected they no longer are inside any geometry, make them solid again.
- Ed the Bat
- Posts: 3060
- Joined: Thu May 03, 2012 1:18 pm
- Graphics Processor: nVidia with Vulkan support
- Location: Maryland, US
- Contact:
Re: Slow monsters stick to walls
Good thought, but +FIXMAPTHINGPOS doesn't seem to have any effect.
Any suggestions on how to detect that?ZzZombo wrote:...and once it's detected they no longer are inside any geometry...
Re: Slow monsters stick to walls
FIXMAPTHINGPOS is for moving actors away from the wall when they are right on it.
Re: Slow monsters stick to walls
A_CheckBlockOrSomethingYouCanLookupOnTheWiki().
- Ed the Bat
- Posts: 3060
- Joined: Thu May 03, 2012 1:18 pm
- Graphics Processor: nVidia with Vulkan support
- Location: Maryland, US
- Contact:
Re: Slow monsters stick to walls
Thank you. A_CheckBlock seems to give me what I need for detecting walls. I can give actors the NOCLIP flag until they're unstuck, then take it away. I just worry that they would take advantage of that to go wandering off INTO the walls or something instead of getting themselves out of them...