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
Script Help Puzzle Help
GoranGaming Offline
Member

Posts: 183
Threads: 30
Joined: Feb 2012
Reputation: 7
#6
RE: Puzzle Help

void OnStart()
{
AddEntityCollideCallback("Stone1", "Stone1Area", "CollideStoneArea1", false, 0);
AddEntityCollideCallback("Stone2", "Stone2Area", "CollideStoneArea2", false, 0);
AddEntityCollideCallback("Stone3", "Stone3Area", "CollideStoneArea3", false, 0);

}

void CollideStoneArea1(string &in asParent, string &in asChild, int alState)
{
SetLocalVarInt("Stone1", 1);

//THIS CHECKS IF THE PUZZLE IS FINISHED
if(GetLocalVarInt("Stone1") == 1 && GetLocalVarInt("Stone2") == 1 && GetLocalVarInt("Stone3") ==1){
//FINISH THE PUZZLE, DO WHATEVER YOU WANT

}
}


void CollideStoneArea2(string &in asParent, string &in asChild, int alState)
{
SetLocalVarInt("Stone2", 1);

//THIS CHECKS IF THE PUZZLE IS FINISHED
if(GetLocalVarInt("Stone1") == 1 && GetLocalVarInt("Stone2") == 1 && GetLocalVarInt("Stone3") ==1){
//FINISH THE PUZZLE, DO WHATEVER YOU WANT

}
}


void CollideStoneArea3(string &in asParent, string &in asChild, int alState)
{
SetLocalVarInt("Stone3", 1);

//THIS CHECKS IF THE PUZZLE IS FINISHED
if(GetLocalVarInt("Stone1") == 1 && GetLocalVarInt("Stone2") == 1 && GetLocalVarInt("Stone3") ==1){
//FINISH THE PUZZLE, DO WHATEVER YOU WANT

}
}

Current projects:

The Dark Prison 85 % (Stopped working on this one)

Unnamed Project 7 %
(This post was last modified: 06-25-2012, 08:44 PM by GoranGaming.)
06-25-2012, 08:43 PM
Website Find


Messages In This Thread
Puzzle Help - by SilentHideButFine - 06-25-2012, 08:17 PM
RE: Puzzle Help - by Cruzore - 06-25-2012, 08:22 PM
RE: Puzzle Help - by SilentHideButFine - 06-25-2012, 08:23 PM
RE: Puzzle Help - by GoranGaming - 06-25-2012, 08:35 PM
RE: Puzzle Help - by SilentHideButFine - 06-25-2012, 08:43 PM
RE: Puzzle Help - by Cruzore - 06-25-2012, 08:37 PM
RE: Puzzle Help - by GoranGaming - 06-25-2012, 08:43 PM
RE: Puzzle Help - by GoranGaming - 06-25-2012, 08:44 PM
RE: Puzzle Help - by SilentHideButFine - 06-25-2012, 09:07 PM



Users browsing this thread: 1 Guest(s)