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 My script doesn't work?
elbichopt Offline
Junior Member

Posts: 14
Threads: 2
Joined: Aug 2012
Reputation: 0
#19
RE: My script doesn't work?

Sorry to bother you again, but what if I want to call more grunts?
I added more fresh meats and made this code. But only the one you made works xD

Spoiler below!
///////////////////////////
//Run when entering map

void OnStart()
{
SetEntityPlayerInteractCallback("fresh_one", "ActivateMonster", true);
SetEntityPlayerInteractCallback("fresh_two", "ActivateMonster_2", true);
SetEntityPlayerInteractCallback("fresh_three", "ActivateMonster_3", true);
SetEntityPlayerInteractCallback("fresh_four", "ActivateMonster_4", true);
}

void ActivateMonster(string &in asEntity)
{
SetEntityActive("grunt", true);
AddEnemyPatrolNode("grunt", "PathNodeArea_1", 0.0f, "");
AddEnemyPatrolNode("grunt", "PathNodeArea_2", 0.0f, "");
AddEnemyPatrolNode("grunt", "PathNodeArea_3", 6.0f, "");
}

  void ActivateMonster_2(string &in asEntity)
{
SetEntityActive("grunt_2", true);
AddEnemyPatrolNode("grunt_2", "PathNodeArea_1", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_2", 0.0f, "");
AddEnemyPatrolNode("grunt_2", "PathNodeArea_3", 6.0f, "");
}

   void ActivateMonster_3(string &in asEntity)
{
SetEntityActive("grunt_3", true);
AddEnemyPatrolNode("grunt_3", "PathNodeArea_1", 0.0f, "");
AddEnemyPatrolNode("grunt_3", "PathNodeArea_2", 0.0f, "");
AddEnemyPatrolNode("grunt_3", "PathNodeArea_3", 6.0f, "");
}

   void ActivateMonster_4(string &in asEntity)
{
SetEntityActive("grunt_4", true);
AddEnemyPatrolNode("grunt_4", "PathNodeArea_1", 0.0f, "");
AddEnemyPatrolNode("grunt_4", "PathNodeArea_2", 0.0f, "");
AddEnemyPatrolNode("grunt_4", "PathNodeArea_3", 6.0f, "");
}




Screenshot:

Spoiler below!
[Image: 11207641.png]
08-16-2012, 02:08 PM
Find


Messages In This Thread
My script doesn't work? - by elbichopt - 08-15-2012, 06:09 PM
RE: My script doesn't work? - by Steve - 08-15-2012, 09:01 PM
RE: My script doesn't work? - by elbichopt - 08-15-2012, 10:10 PM
RE: My script doesn't work? - by Adny - 08-15-2012, 10:14 PM
RE: My script doesn't work? - by elbichopt - 08-15-2012, 10:17 PM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 10:35 AM
RE: My script doesn't work? - by fuytko - 08-16-2012, 11:31 AM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 11:42 AM
RE: My script doesn't work? - by fuytko - 08-16-2012, 11:51 AM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 11:53 AM
RE: My script doesn't work? - by fuytko - 08-16-2012, 12:00 PM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 12:05 PM
RE: My script doesn't work? - by fuytko - 08-16-2012, 12:09 PM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 12:11 PM
RE: My script doesn't work? - by ZyLogicX - 08-16-2012, 12:16 PM
RE: My script doesn't work? - by fuytko - 08-16-2012, 12:20 PM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 12:33 PM
RE: My script doesn't work? - by fuytko - 08-16-2012, 12:44 PM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 02:08 PM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 07:36 PM
RE: My script doesn't work? - by TheGreatCthulhu - 08-16-2012, 07:45 PM
RE: My script doesn't work? - by elbichopt - 08-16-2012, 07:47 PM
RE: My script doesn't work? - by Theforgot3n1 - 08-16-2012, 09:11 PM



Users browsing this thread: 1 Guest(s)