Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Sign in to follow this  

Newb script question

Recommended Posts

I'm currently writing my first ACS script. I've got the script functioning just fine. the only problem is it is activated by walking over several different lines. I want the script to activate only the first time the player walks over any of the lines, and not to activate again when the player crosses a different line saying to execute the same script. how do I make it so a script only gets executed once and all other lines after the initial activation are ignored?



Share this post

Link to post

#include "zcommon.acs" //or common.acs if using only hexen

bool run = false; //you may need to use int in hexen. doesn't really matter though

script 1 (void)
    if (!run)
        //do stuff
        run = true;

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
Sign in to follow this