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
Despawns after following path
Karai16 Offline
Member

Posts: 164
Threads: 24
Joined: Apr 2011
Reputation: 0
#1
Despawns after following path

Hey guys, I'm testing my new map right now (it's a test map so don't worry about me publishing it) the thing is. I make a suitor follow a path. I never made a script area to dispawn it, so it should follow its path back and forth for all eternity. The thing is, it doesn't. after following its path, it despawns... what am I doing wrong? O.o

Custom stories:
Her Games (100% Complete)
Her Games, All Bugs Fixed (100% Complete)
(This post was last modified: 05-27-2011, 11:37 AM by Karai16.)
05-27-2011, 11:18 AM
Find
Mooserider Offline
Member

Posts: 64
Threads: 11
Joined: Jan 2011
Reputation: 2
#2
RE: Despawns after following path

I had the same problem, I think all enemies despawn after reaching their last node. I made an area around my last node that led him back to his first node and it works pretty well but I had to have every single pathnode in his first patrol in the new function. Hope this helps

Working on a FC: "Don't Let Go "
05-27-2011, 02:02 PM
Find
Greven Offline
Member

Posts: 106
Threads: 13
Joined: May 2011
Reputation: 3
#3
RE: Despawns after following path

Say you have like 3 path nodes. Pathnode1 2 and 3 the only thing you gotta do is add the pathnodes.
void Function()
{
AddEnemyPatrolNode("Monster", "Pathnode1", float afWaitTime, string& asAnimation);
AddEnemyPatrolNode("Monster", "Pathnode2", float afWaitTime, string& asAnimation);
AddEnemyPatrolNode("Monster", "Pathnode3", float afWaitTime, string& asAnimation);
}
And then you just add the pathnode1 again.
void AddEnemyPatrolNode("Monster", "Pathnode1", float afWaitTime, string& asAnimation);

So it will look like this:
void Function()
{
AddEnemyPatrolNode("Monster", "Pathnode1", float afWaitTime, string& asAnimation);
AddEnemyPatrolNode("Monster", "Pathnode2", float afWaitTime, string& asAnimation);
AddEnemyPatrolNode("Monster", "Pathnode3", float afWaitTime, string& asAnimation);
AddEnemyPatrolNode("Monster", "Pathnode1", float afWaitTime, string& asAnimation);
}
Then when it reaches the pathnode1 it will repeat the action by going to number 2 then 3 and then continue patrolling

[WIP] Recidivus
(This post was last modified: 05-27-2011, 02:15 PM by Greven.)
05-27-2011, 02:07 PM
Find




Users browsing this thread: 1 Guest(s)