Jump to content

Question about showing a message when first encountering an object


LHNX

Recommended Posts

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!

Link to comment
Share on other sites

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

 

endif

set DoOnce to 1

 

endif

 

endif

end

 

If you want to use a trigger box, then use:

 

begin on TriggerEnter player

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...