The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



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


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to have more scripts then one at a time.[Solved]
clock123 Offline
Member

Posts: 76
Threads: 18
Joined: Jul 2011
Reputation: 0
#1
How to have more scripts then one at a time.[Solved]

Hey, when ever I add more then one script into my game files to my custom map it crashes, how should I fix that?, here's what I'm trying to add.

Spoiler below!
void OnStart()

{
AddUseItemCallback("", "Key1", "Door1", "KeyOnDoor", true);
}

void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Door1", false, true);
PlaySoundAtEntity("", "unlock_door", "door1", 0, false);
RemoveItem("Key1");
}

{
ConnectEntities("door_connection", //Name of connection
"Lever1", //Parent entity (Affects)
"Shelf", //Child entity (Affected)
false, //Invert the state sent
1, //States used (0=both), checked before invertion.
"CreateDust"); //callback
}
(This post was last modified: 07-29-2011, 09:26 AM by clock123.)
07-28-2011, 10:27 AM
Find


Messages In This Thread
How to have more scripts then one at a time.[Solved] - by clock123 - 07-28-2011, 10:27 AM



Users browsing this thread: 1 Guest(s)