Frictional Games Forum (read-only)
Patrolling issue - 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: Patrolling issue (/thread-15195.html)



Patrolling issue - Manbearpig116 - 04-30-2012

I'm trying to make this brute walk around the map. He does walk about but for some reason, he pauses at each one before moving on to the next one.

Here is the script in full

////////////////////////////
// Run when entering map
void OnEnter()
{
FadeOut(0);

FadeIn(25);
AddUseItemCallback("", "monsterdoorkey_1", "monsterdoor", "UsedKeyOnDoor", true);
AddEntityCollideCallback("Player", "Cheapscare", "Boom", true, 0);
AddEntityCollideCallback("Player", "PlayerCollide", "SpawnMonster", true, 0);
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("monsterdoor", false, true);
PlaySoundAtEntity("", "unlock_door", "monsterdoor", 0, false);
RemoveItem("monsterdoorkey_1");
}

void Boom(string &in asParent, string &in asChild, int alstate)
{
SetEntityActive("armournice", true);
PlayGuiSound("12_girl_scream.snt", 1);
GiveSanityDamage(80 , true);
}

void SpawnMonster(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_brute_1", true);
PlayGuiSound("amb_idle01.snt", 1);
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_1", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_2", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_3", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_4", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_5", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_6", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_7", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_8", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_9", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_10", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_11", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_12", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_13", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_14", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_15", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_16", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_17", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_18", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_19", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_20", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_21", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_22", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_23", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_24", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_25", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_26", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_27", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_28", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_29", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_30", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_31", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_32", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_33", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_34", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_35", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_36", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_37", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_38", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_39", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_40", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_41", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_42", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_43", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_44", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_45", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_46", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_47", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_48", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_49", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_50", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_51", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_52", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_53", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_54", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_55", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_56", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_57", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_58", 0, "");
AddEnemyPatrolNode("servant_brute_1", "PathNodeArea_59", 0, "");
}
////////////////////////////
// Run when leaving map
void OnLeave()
{

}

Can anyone resolve this issue?



RE: Patrolling issue - Your Computer - 04-30-2012

Change 0 to 0.001.


RE: Patrolling issue - narutohokager - 04-30-2012

Hello

I already had this problem... This was not a problem of 0 time, But because you put too much pathnode.

If during the map will have one corridor, avoid putting much pathnodes, put in a long corridor to 2-3 pathnodes.
Try reducing the numbers of pathnodes, It's about what I did and my problem was resolved Wink
Infact, the monster every Pathnode, it stops for about 1 second, it's automatic







RE: Patrolling issue - Manbearpig116 - 05-02-2012

(04-30-2012, 07:59 PM)narutohokager Wrote: Hello

I already had this problem... This was not a problem of 0 time, But because you put too much pathnode.

If during the map will have one corridor, avoid putting much pathnodes, put in a long corridor to 2-3 pathnodes.
Try reducing the numbers of pathnodes, It's about what I did and my problem was resolved Wink
Infact, the monster every Pathnode, it stops for about 1 second, it's automatic
Actually changing it to 0.001 worked for me