Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Multiple triggers
The Shanus Offline
Member

Posts: 134
Threads: 15
Joined: Jun 2012
Reputation: 3
#10
RE: Multiple triggers

(06-19-2012, 09:41 PM)FastHunteR Wrote: http://www.frictionalgames.com/forum/thread-10798.html
Number 18, wake up script
Okay so these are the errors I'm now getting:
"main (26,1) : INFO : Compiling void OnPickup (string&in string&in)
main (34,3) : ERR : Expected ';' "
And my script as of now:
PHP Code: (Select All)
void OnStart()
{
}

////////////////////////////
// Run when entering map

void OnEnter()
{
AddUseItemCallback("""room101key""room101""UsedKeyOnDoor"true);
AddUseItemCallback("""room100key""room100""UsedKeyOnDoor"true);
SetEntityCallbackFunc("room100key""OnPickup");
SetEntityCallbackFunc("NOTETWO""OnPickup");
AddUseItemCallback("""hatch101key""hatch101""UsedKeyOnDoor"true);
}

void UsedKeyOnDoor(string &in asItemstring &in asEntity)
{
SetSwingDoorLocked(asEntityfalsetrue);
PlaySoundAtEntity(""asEntity"room101"0false);
PlaySoundAtEntity(""asEntity"room100"0false);
PlaySoundAtEntity(""asEntity"hatch101"0false);
RemoveItem(asItem);
}

void OnPickup(string &in asEntitystring &in type)
{
    if(
asEntity == "room100key")
{
  
SetEntityActive("poofer1"true);
  
ShowEnemyPlayerPosition("poofer1");
  
PlaySoundAtEntity("""04_break.snt""poofer1"0false);
  
StartPlayerLookAt("poofer1",2,2,"")
  
StopPlayerLookAt();
}
    if(
asEntity == "NOTETWO")
{
  
SetSwingDoorLocked("room102",false,false);
  
SetEntityActive("brute1",true);
  
StartPlayerLookAt("brute1",2,2,"");
  
StopPlayerLookAt();
}


Can't tell what's wrong Confused

[Image: theshanusyoutube.jpg]
(This post was last modified: 06-19-2012, 10:56 PM by The Shanus.)
06-19-2012, 10:56 PM
Find


Messages In This Thread
Multiple triggers - by The Shanus - 06-19-2012, 08:02 PM
RE: Multiple triggers - by Cruzore - 06-19-2012, 08:56 PM
RE: Multiple triggers - by The Shanus - 06-19-2012, 08:59 PM
RE: Multiple triggers - by Cruzore - 06-19-2012, 09:01 PM
RE: Multiple triggers - by The Shanus - 06-19-2012, 09:05 PM
RE: Multiple triggers - by Cruzore - 06-19-2012, 09:13 PM
RE: Multiple triggers - by The Shanus - 06-19-2012, 09:38 PM
RE: Multiple triggers - by Cruzore - 06-19-2012, 09:41 PM
RE: Multiple triggers - by The Shanus - 06-19-2012, 09:44 PM
RE: Multiple triggers - by The Shanus - 06-19-2012, 10:56 PM
RE: Multiple triggers - by Your Computer - 06-19-2012, 11:17 PM
RE: Multiple triggers - by The Shanus - 06-19-2012, 11:22 PM
RE: Multiple triggers - by Your Computer - 06-20-2012, 12:00 AM
RE: Multiple triggers - by The Shanus - 06-20-2012, 12:18 AM
RE: Multiple triggers - by Your Computer - 06-20-2012, 01:35 AM
RE: Multiple triggers - by The Shanus - 06-20-2012, 09:35 AM
RE: Multiple triggers - by drunkmonk - 06-20-2012, 01:21 AM



Users browsing this thread: 1 Guest(s)