Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
  • 0
Zulk RS

How to make monsters take damage whenever it touches a floor? (GZDoom UDMF)

Question

So, I'm making a train map and using ACS, I was able to get the floor to scroll and the player to die when it touches the scrolling floor. However, I want to make it so that if any monster or barrel touches the scrolling floor, it also dies. I've been looking though Zdoom Wiki but I can't figure out how to do this. Can someone help?

Share this post


Link to post

4 answers to this question

Recommended Posts

  • 1

For making monsters die, you could use the sector action "Actor Hits Floor", and give it the AMBUSH flag ("Monsters activate" in GZDB, "Deaf" in DB2), so that monsters will also trigger it.

y1oqIGB.pngvNoxi6e.png

 

You can give the sector action one of the action specials that deals damage: DamageThing or Thing_Damage.

WD7j2RM.png

 

Or you can use ACS_ExecuteAlways, and call a script that uses the built-in acs function Thing_Damage2.

 


For making barrels die, there are many ways to go about it, but not sure what the best method would be. One method would be to make a barrel replacement with the ISMONSTER flag, to make them also trigger the sector action. This method might have some side effects under some circumstances.

actor ExplosiveBarrelM : ExplosiveBarrel replaces ExplosiveBarrel
{
  +ISMONSTER
}

 

Share this post


Link to post
  • 0

If you did this, would it also make monsters avoid the damaging floor? Or would they just start trying to get to you regardless of what they had to walk across, effectively committing suicide?

Share this post


Link to post
  • 0
5 hours ago, Pegleg said:

If you did this, would it also make monsters avoid the damaging floor? Or would they just start trying to get to you regardless of what they had to walk across, effectively committing suicide?

Well, I've walled off the damaging floor with Block Monster Lines so no, they wouldn't walk across it.

Share this post


Link to post
  • 0
14 hours ago, Worst said:

For making monsters die, you could use the sector action "Actor Hits Floor", and give it the AMBUSH flag ("Monsters activate" in GZDB, "Deaf" in DB2), so that monsters will also trigger it.

y1oqIGB.pngvNoxi6e.png

 

You can give the sector action one of the action specials that deals damage: DamageThing or Thing_Damage.

WD7j2RM.png

 

 

Okay I did this thing and it worked like a charm. Even barrels explode when they hit the ground.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×