LHNX Posted January 9, 2012 Posted January 9, 2012 Hi everyone, I've been trying to show a message when the player first encounters a certain object, but I can't seem to figure out how to do this the right way. I only want to show it the first time the player adds a certain object to his inventory, after that the message doesn't have to appear anymore. Does somebody know how to do this? Thanks!
achillesdave Posted January 9, 2012 Posted January 9, 2012 This can be done by attatching a script to the object or to a trigger box around it. First make your message then make your script. The example script is for the message appearing when added to the players inventory. Scn nameofScript begin onAdd player Short DoOnce if ( DoOnce == 0 )showmessage nameofyourmessage endifset DoOnce to 1 endif endifend If you want to use a trigger box, then use: begin on TriggerEnter player
LHNX Posted January 10, 2012 Author Posted January 10, 2012 Thank you for the answer! The script was almost good, I had to tweak it a little, but now it works perfectly.
Recommended Posts