Im new to scripting but...

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.
User avatar
Lexus Alyus
Posts: 4220
Joined: Tue Jul 15, 2003 5:07 pm
Location: Nottingham, UK
Contact:

Post by Lexus Alyus »

Urm, next question...

So, I want a really cool mission system where you call your objectives via a puke script and it shows you your mission with a cool background using hudmessages and imagetool... thats fine, but how do I actually do this? I mean, how do I set the hudmessage to print what I want it to say when the player presses the key to activate the script, then only get rid of it when the player presses that key again (toggaling it on and off)? How do I change the message? I'm basically trying to recreate Quake 2's mission system via ACS... I know it's possible, but honestly, my scripting isn't that great...

Thanks in advance.

:twisted:
User avatar
HotWax
Posts: 10002
Joined: Fri Jul 18, 2003 6:18 pm
Location: Idaho Falls, ID

Post by HotWax »

Lexus Alyus wrote:Urm, next question...

So, I want a really cool mission system where you call your objectives via a puke script and it shows you your mission with a cool background using hudmessages and imagetool... thats fine, but how do I actually do this? I mean, how do I set the hudmessage to print what I want it to say when the player presses the key to activate the script, then only get rid of it when the player presses that key again (toggaling it on and off)? How do I change the message? I'm basically trying to recreate Quake 2's mission system via ACS... I know it's possible, but honestly, my scripting isn't that great...

Thanks in advance.

:twisted:
Bind the control to a puke function that runs one of your scripts. That script will check a map variable to see if the "Mission HUD" is already active. If not, it runs a routine which first draws the background (custom font) using a certain TID and set to stay forever (duration 0.0), then draws the text using map/world variables containing the current objectives, again using a unique TID and set to display forever. Then the script sets the "Mission HUD ON" variable and exits. (The graphic and text should stay on the screen indefinately)

Once the player presses it again, the script checks the Mission HUD variable, finds that it's already on, and prints two blank messages using the same TIDs as the graphic and text ones setup before. That should clear them out. The Mission HUD variable is then cleared and the script exits.

Rinse and repeat.
User avatar
Lexus Alyus
Posts: 4220
Joined: Tue Jul 15, 2003 5:07 pm
Location: Nottingham, UK
Contact:

Post by Lexus Alyus »

Right, thanx for the advise :-). I'm gonna try and script this myself :-), now I know what to do, i just don't know how to do it, but I'm gonna give it a try :-). Thanx again :-).

:twisted:
Locked

Return to “Editing (Archive)”