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:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Monster activation newb
zaggnut Offline
Member

Posts: 62
Threads: 2
Joined: Jul 2012
Reputation: 1
#1
Sad  Monster activation newb

i am trying to learn/practice scripting by activating a grunt and have it follow path nodes. i can load my map fine but when i enter the script area nothing happens. i believe the names of my entities/areas match between the .map and .hps .... i need someone that has mastered the dark arts of scripting

i spent like 2 hours trying to do this simple task. Angry
is there anything wrong with my syntax or something?


////////////////////////////
// Run first time starting map
void onstart()
{
AddEntityCollideCallback("Player", "Scr_enemyspawn1", "MonsterFunction", true, 1);
}

void MonsterFunction(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("Grunt_1", true);
AddEnemyPatrolNode("Grunt_1", "PathNode_1", 0, "");
AddEnemyPatrolNode("Grunt_1", "PathNode_2", 0, "");
AddEnemyPatrolNode("Grunt_1", "PathNode_3", 0, "");
}

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

void OnEnter()
{

}

////////////////////////////
// Run when leaving map

void OnLeave()
{

}

The human race will Bleed, they will serve my
need!
(This post was last modified: 07-29-2012, 06:07 AM by zaggnut.)
07-28-2012, 11:31 PM
Find


Messages In This Thread
Monster activation newb - by zaggnut - 07-28-2012, 11:31 PM
RE: Monster activation newb - by Kazakarumariou - 07-28-2012, 11:33 PM
RE: Monster activation newb - by zaggnut - 07-29-2012, 01:31 AM



Users browsing this thread: 1 Guest(s)