Activating monsters via script?

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!

Moderator: GZDoom Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Post Reply
User avatar
::Bloodfury::
Posts: 332
Joined: Mon Aug 01, 2011 7:39 pm
Graphics Processor: nVidia (Modern GZDoom)
Location: Finland

Activating monsters via script?

Post by ::Bloodfury:: »

Hi!

I like to use interactive portals, as they open lots of complicated architectural possibilities.
However.

One limitation of these portals, is that the dormant monsters do not see you through them.
If you shoot (make a sound) in the area the portal is connected, this does wake the monster
up and it begins to act normally.

I have tried to use Thing_Activate (Among some others) in a script, so when player crosses a linedef the enemies would
be alert etc. As I do not want to force the player to make a sound.

But the enemies just stay dormant. Thing_Activate does not wake the enemies. (set them in their chase state.)

Any solution to make the enemies active so that you wouldn't encounter a blind monster standing in front of you on
the opposite end of a portal? :D

(One way could be to make the monsters patrol between points. But I would assume that
the same problem would persist as if they are in the other side of the portal, while patrolling, they still would not see the player
even if they would face directly to him.)

Thx in advance for any help!
Blue Shadow
Posts: 5043
Joined: Sun Nov 14, 2010 12:59 am

Re: Activating monsters via script?

Post by Blue Shadow »

Have you tried NoiseAlert?
User avatar
::Bloodfury::
Posts: 332
Joined: Mon Aug 01, 2011 7:39 pm
Graphics Processor: nVidia (Modern GZDoom)
Location: Finland

Re: Activating monsters via script?

Post by ::Bloodfury:: »

Ah! Thank you. I shall give this a try!
Post Reply

Return to “Scripting”