ACS - Simple Text Message

Archive of the old editing forum
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.
Locked
John Gaughan

ACS - Simple Text Message

Post by John Gaughan »

I am a complete newbie when it comes to ACS. I understand the basics, but I just can't seem to figure out if this is possible. Is there a way to bind a function to a tag? I.e., have a LINEDEF with a sector tag, and when the user hits it, it triggers a function in addition to its normal action.

It seems to me that this would be far easier than calling a function that calls a bunch of other functions. All I want to do is display some text like "a platform raised in the other room" when the player flips a switch, in addition to actually raising the platform.
User avatar
cccp_leha
Posts: 1816
Joined: Wed Jul 16, 2003 7:21 am
Location: NJ, USA
Contact:

Post by cccp_leha »

Look at this:
Attachments
Wad3.zip
(813 Bytes) Downloaded 22 times
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49252
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: ACS - Simple Text Message

Post by Graf Zahl »

John Gaughan wrote:I am a complete newbie when it comes to ACS. I understand the basics, but I just can't seem to figure out if this is possible. Is there a way to bind a function to a tag? I.e., have a LINEDEF with a sector tag, and when the user hits it, it triggers a function in addition to its normal action.

It seems to me that this would be far easier than calling a function that calls a bunch of other functions. All I want to do is display some text like "a platform raised in the other room" when the player flips a switch, in addition to actually raising the platform.

Each line can only have one function. Executing a script is one. In your case you will have to perform your main action in the script. Where's the problem because you'd need the script anyway for printing your message?

Of course you could add a second linedef with a passthru flag so one activates your action and the other your script but that is so much more complicated than simply doing all your stuff in the script that it really isn't worth it.
John Gaughan

Post by John Gaughan »

Hey, I'm just a computer programmer! Oh, nevermind... ;-)

Anyway, I am new to ACS. Whenever I learn a new language I am always lost at first. I'll get it eventually.

It would be nice to have this compatible with ports such as PrBoom. As awesome as ZDoom is, not everyone likes it. Oh well. I'd rather have less ambiguity in places (like switches where you have no clue what they do).
User avatar
cccp_leha
Posts: 1816
Joined: Wed Jul 16, 2003 7:21 am
Location: NJ, USA
Contact:

Post by cccp_leha »

John Gaughan wrote:...As awesome as ZDoom is, not everyone likes it...
No way dude! Get outta town, that can't possibly be true.
User avatar
HotWax
Posts: 10002
Joined: Fri Jul 18, 2003 6:18 pm
Location: Idaho Falls, ID

Post by HotWax »

ZDoom supports Boom extensions. If you just avoid using ACS scripts, and slopes, and stealth monsters, and KEYCONF, and DECALDEF, and ANIMDEFS, and.. you know... other awesome stuff, then you can make a level compatible with Boom/PRBoom and ZDoom.

And we'll all laugh at you.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49252
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Post by Graf Zahl »

HotWax wrote:ZDoom supports Boom extensions. If you just avoid using ACS scripts, and slopes, and stealth monsters, and KEYCONF, and DECALDEF, and ANIMDEFS, and.. you know... other awesome stuff, then you can make a level compatible with Boom/PRBoom and ZDoom.

And we'll all laugh at you.
In other words: Something like Phobos: Anomaly Reborn is shit, right?

Restricting oneself to a lower standard does not automatically make a level bad - even though they can't compete with the truly impressive stuff.
User avatar
HotWax
Posts: 10002
Joined: Fri Jul 18, 2003 6:18 pm
Location: Idaho Falls, ID

Post by HotWax »

Where did I say it did?
Locked

Return to “Editing (Archive)”