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
Simple help with scripting?
KenOfAllTrades Offline
Member

Posts: 53
Threads: 2
Joined: Apr 2011
Reputation: 0
#1
Simple help with scripting?

Okay so I've been searching the forum, and I've found a lot of useful scripts. So far I've been able to spawn a monster when I walk to a certain spot, but I don't know how to make it go to a path node.

I've found some lines I can't find again on how to make it instantly spot my location or go to the path node, but I don't know HOW to add them. I've tried a lot of different things. My problem is just that I don't know how to ADD stuff to the OnStart part.

////////////////////////////
// Run when entering map
void OnEnter()
{

}

////////////////////////////
// Run when leaving map
void OnLeave()
{

}

////////////////////////////
// Run first time starting map
void OnStart()
{
AddEntityCollideCallback("Player" , "MonsterArea" , "MonsterFunc1" , true , 1);
}
void MonsterFunc1(string &in asParent , string &in asChild , int alState)
{
SetEntityActive("Monsterguy" , true);
}
ShowEnemyPlayerPosition("Monsterguy");
}

If I want my monster to go to "Path01", EXACTLY what do I have to add where? Can anyone write me a modified version of this script that would make him head for "Path01"? And maybe try to explain how it works? Help is VERY much appreciated

I probably made a LP of this! Youtube channel here!
05-22-2011, 12:19 AM
Find


Messages In This Thread
Simple help with scripting? - by KenOfAllTrades - 05-22-2011, 12:19 AM
RE: Simple help with scripting? - by Kyle - 05-22-2011, 12:30 AM



Users browsing this thread: 1 Guest(s)