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


Thread Rating:
  • 1 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Two problems
Storfigge Offline
Member

Posts: 101
Threads: 31
Joined: Sep 2012
Reputation: 0
#11
RE: Two problems

(12-19-2012, 11:57 AM)beecake Wrote: Ah! It's because it's SetEnemyDisableTriggers
I don't get any errors now but the monsters keep chasing me even though I've enter the CollideArea so their chase music keeps playing Sad I wrote it like this

void OnStart()



{
AddEntityCollideCallback("Player", "SpawnMonsters", "SpawnFunction_1", false, 1);
AddEntityCollideCallback("Player", "SpawnMonsters_2", "SpawnFunction_2", false, 1);
AddEntityCollideCallback("Player", "SpawnMonsters_3", "SpawnFunction_3", false, 1);
AddEntityCollideCallback("Player", "SpawnMonsters_4", "SpawnFunction_4", false, 1);
AddEntityCollideCallback("Player", "SpawnMonsters_5", "SpawnFunction_5", false, 1);
AddEntityCollideCallback("Player", "Start_Credits", "Main_Credits", false, 1);
AddEntityCollideCallback("Player", "DisableMonster", "Disable", true, 1);
}

void SpawnFunction_1(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("grunt_1", true);
ShowEnemyPlayerPosition("grunt_1");
SetEntityActive("grunt_2", true);
ShowEnemyPlayerPosition("grunt_2");
}

void SpawnFunction_2(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("grunt_3", true);
ShowEnemyPlayerPosition("grunt_3");
SetEntityActive("grunt_4", true);
ShowEnemyPlayerPosition("grunt_4");
}

void SpawnFunction_3(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("grunt_5", true);
ShowEnemyPlayerPosition("grunt_5");
SetEntityActive("grunt_6", true);
ShowEnemyPlayerPosition("grunt_6");
}

void SpawnFunction_4(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("grunt_7", true);
ShowEnemyPlayerPosition("grunt_7");
SetEntityActive("grunt_8", true);
ShowEnemyPlayerPosition("grunt_8");
}

void SpawnFunction_5(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("grunt_9", true);
ShowEnemyPlayerPosition("grunt_9");
SetEntityActive("grunt_10", true);
ShowEnemyPlayerPosition("grunt_10");
}


void Main_Credits(string &in asParent, string &in asChild, int alState)
{
FadeOut(2);
PlayMusic("Music.ogg", false, 1, 1, 1, false);
StartCredits("what's going on.ogg", true, "Ending", "MainCredits", 9001);
}

void Disable(string &in asParent, string &in asChild, int alState)
{
SetEnemyDisableTriggers("grunt_1", true);
SetEnemyDisableTriggers("grunt_2", true);
SetEnemyDisableTriggers("grunt_3", true);
SetEnemyDisableTriggers("grunt_4", true);
SetEnemyDisableTriggers("grunt_5", true);
SetEnemyDisableTriggers("grunt_6", true);
SetEnemyDisableTriggers("grunt_7", true);
SetEnemyDisableTriggers("grunt_8", true);
SetEnemyDisableTriggers("grunt_9", true);
SetEnemyDisableTriggers("grunt_10", true);
}


void OnEnter()
{

}


void OnLeave()
{

}

12-19-2012, 12:11 PM
Find


Messages In This Thread
Two problems - by Storfigge - 12-13-2012, 01:49 PM
RE: Two problems - by The chaser - 12-13-2012, 02:12 PM
RE: Two problems - by Storfigge - 12-18-2012, 12:36 PM
RE: Two problems - by Kreekakon - 12-18-2012, 01:44 PM
RE: Two problems - by Storfigge - 12-18-2012, 02:06 PM
RE: Two problems - by The chaser - 12-18-2012, 02:13 PM
RE: Two problems - by Storfigge - 12-19-2012, 01:25 AM
RE: Two problems - by FlawlessHappiness - 12-19-2012, 06:48 AM
RE: Two problems - by Storfigge - 12-19-2012, 11:54 AM
RE: Two problems - by FlawlessHappiness - 12-19-2012, 11:57 AM
RE: Two problems - by Storfigge - 12-19-2012, 12:11 PM
RE: Two problems - by FlawlessHappiness - 12-19-2012, 12:39 PM
RE: Two problems - by Storfigge - 12-19-2012, 02:00 PM
RE: Two problems - by FlawlessHappiness - 12-19-2012, 02:02 PM
RE: Two problems - by Storfigge - 12-19-2012, 02:03 PM
RE: Two problems - by FlawlessHappiness - 12-19-2012, 02:58 PM
RE: Two problems - by Storfigge - 12-19-2012, 03:58 PM
RE: Two problems - by Your Computer - 12-19-2012, 05:21 PM
RE: Two problems - by FlawlessHappiness - 12-19-2012, 04:21 PM



Users browsing this thread: 1 Guest(s)