Jump to content
TheRobberPanda

How do I open up a box with a script and make a message pop afterwards?

Recommended Posts

I know this must be easy, but I've been looking on online and there's nothing I found that was useful.

In my mission I want players to be able to open up a rugged portable cabinet, after that I want a message to pop up somewhere to tell them that the box was empty.

How do I do this?  I already have the system in place thanks to 3den enhanced, I just need the script to alter the state of the cabinet and to pop the message

 

Share this post


Link to post
Share on other sites

In the cabinets Init attribute...

this addEventHandler[ "ContainerOpened", {
	_this spawn {
		waitUntil{ !isNull( uiNamespace getVariable "RscDisplayInventory" ) };
		( uiNamespace getVariable "RscDisplayInventory" ) closeDisplay 1;
		hint "You find nothing of interest";
	};	
}];

 

  • Like 4
  • Thanks 1

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×