object oTarget;
oTarget = GetObjectByTag("shindia");
AssignCommand(oTarget, ActionMoveToObject(GetObjectByTag("WP_shindia_02")));
AssignCommand(oTarget, ActionPlayAnimation(ANIMATION_LOOPING_KNEELIDLE, 1.0f, 600.0f));
SetWalkCondition(NW_WALK_FLAG_PAUSED, TRUE);
I put that segment at the end of the default heartbeat script and saved it as a copy with it named the way it's supposed to be (wp_shindia), and the copy of the NPC that's placed in the area has the variable set as it should be, WP_TAG = "shindia". But when I run the module in-game, sometimes the NPC will do what she's supposed to do and sometimes she won't, without me making any changes at all. Sometimes she'll start out at the second waypoint instead of the first and won't kneel down, other times she'll start there and be facing the wrong direction. It seems to be random, and I don't know why. I had originally had a line in the script telling her to go to the first waypoint before going to the second, but when that line was in there, she'd show up at the 2nd waypoint, go back to the first, then back to the 2nd and then kneel or sometimes not kneel. Any help would be greatly appreciated, or if any of you script gurus know a better way of accomplishing this goal, I'd be very grateful. I'm still a bit new to mod-making, so I'm always open to new ideas about how to do things. Thanks!
Modifié par pkniess77, 05 décembre 2011 - 03:09 .





Retour en haut






