![]() |
Enemy Patrol Problem - Printable Version +- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum) +-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html) +--- Forum: Custom Stories, TCs & Mods - Development (https://www.frictionalgames.com/forum/forum-38.html) +---- Forum: Development Support (https://www.frictionalgames.com/forum/forum-39.html) +---- Thread: Enemy Patrol Problem (/thread-24110.html) |
Enemy Patrol Problem - pawsUp1703 - 12-13-2013 Hey guys, So I was using this guide to set up a grunt that patrols his route more than just once, but it just won't work. I set ActivationDistance to 1000 and added <Var Name="AutoRemoveAtPathEnd" Value="false" /> to the .ent file what am I missing? RE: Enemy Patrol Problem - Neelke - 12-14-2013 Just a question here. Why would you need such big activation distance? And besides, if that don't work, try to just add a script at the last pathnode the enemy takes. For example: This triggers void GruntPatrolNode(string &in asParent, string &in asChild, int alState) { SetEntityActive("nomusic_grunt_1", true); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_27", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_21", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_18", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_31", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_17", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_14", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_8", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_4", 0, ""); } void LoopGruntPatrol(string &in asParent, string &in asChild, int alState) { AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_27", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_21", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_18", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_31", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_17", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_14", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_8", 0, ""); AddEnemyPatrolNode("nomusic_grunt_1", "PathNodeArea_4", 0, ""); } void OnStart() { AddEntityCollideCallback("Player", "AreaStartGrunt", "GruntPatrolNode", true, 1); AddEntityCollideCallback("nomusic_grunt_1", "AreaGruntLoopPatrol", "LoopGruntPatrol", false, 1); } |