IGabx
Junior Member
Posts: 10
Threads: 3
Joined: Aug 2012
Reputation:
0
|
Monster despawn
I've seen forums like this before but none have helped. Usually when a monster gets out of vision it disappears, but I want to make it so he doesn't disappear at all. I already got him to stay after death it's just when he's out of sight.
Is there any way of doing this, and if so please explain 'cause I can be a noob at these kind of things! :S
|
|
09-15-2012, 10:27 PM |
|
Melvin
Member
Posts: 245
Threads: 38
Joined: Jun 2012
Reputation:
5
|
RE: Monster despawn
Hey buddy I'm having the same problem over here.. It seems to be a common thing.
If you are REALLY a noob, you should post your script. If you find a solution (though scripting) I would be happy to fix it for you. I'll just stay tuned on this thread on the background.
|
|
09-16-2012, 01:12 AM |
|
IGabx
Junior Member
Posts: 10
Threads: 3
Joined: Aug 2012
Reputation:
0
|
RE: Monster despawn
I'm not sure what the script has to do with anything, considering that I didn't really try anything other than just place him. I'm completely clueless, but if you need the script, here ya go ;D
Quote: void OnStart()
{
AddEntityCollideCallback("Player", "PlayerCollide", "Monster", false, 1);
}
void Monster(string &in asChild, string &in asParent, int alState)
{
SetEntityActive("brute_1", true);
AddEnemyPatrolNode("brute_1", "PathNodeArea_1", 2, "");
AddEnemyPatrolNode("brute_1", "PathNodeArea_2", 0, "");
AddEnemyPatrolNode("brute_1", "PathNodeArea_3", 0, "");
AddEnemyPatrolNode("brute_1", "PathNodeArea_4", 3, "");
AddEnemyPatrolNode("brute_1", "PathNodeArea_5", 0, "");
}
|
|
09-16-2012, 02:28 AM |
|
Kreekakon
Pick a god and pray!
Posts: 3,063
Threads: 70
Joined: Mar 2012
Reputation:
124
|
RE: Monster despawn
You should try reading this:
http://wiki.frictionalgames.com/hpl2/tut...rpathnodes
It states that the monster will despawn if it runs out of nodes, and the player isn't looking at it. There's a nice tutorial in there to make the monster move indefinitely.
|
|
09-16-2012, 04:17 AM |
|
Unearthlybrutal
Posting Freak
Posts: 775
Threads: 12
Joined: May 2011
Reputation:
26
|
RE: Monster despawn
You can edit the .ent file to change the distance when enemy is disappearing.
|
|
09-16-2012, 09:36 AM |
|
Melvin
Member
Posts: 245
Threads: 38
Joined: Jun 2012
Reputation:
5
|
RE: Monster despawn
Hey, I've tested the editing of the .ent file (the grunt). I opened up the ModelEditor and then went to settings. Here, you can edit the behavior of the enemy (like awareness, search time etc.) Well, I've edited the search time, and set it from 10, to 200.
So far so good it works.
|
|
09-16-2012, 12:09 PM |
|
IGabx
Junior Member
Posts: 10
Threads: 3
Joined: Aug 2012
Reputation:
0
|
RE: Monster despawn
Okay thanks for the tips. Btw the nodes are a straight line and he already goes back and forth it's just when he's out of sight anyways I'll give that a try. Thanks!
(09-16-2012, 04:17 AM)Kreekakon Wrote: You should try reading this:
http://wiki.frictionalgames.com/hpl2/tut...rpathnodes
It states that the monster will despawn if it runs out of nodes, and the player isn't looking at it. There's a nice tutorial in there to make the monster move indefinitely. Btw thanks, I read that before though and I have some trouble understanding "if" statements and what not so for my first story I would like to keep it simple. If I have to though then maybe I will!
(This post was last modified: 09-16-2012, 06:00 PM by IGabx.)
|
|
09-16-2012, 05:58 PM |
|
|