men11
Junior vMember
Posts: 25
|
Post by men11 on May 10, 2020 19:18:33 GMT
Code: forum.GetComponent<Invector_Team>.Summon.Invectorteam.SolveIssue.Please :D End_Code.
Hi ^^, basically when AI is in wander state... he just walks 4f toward random direction without stopping so in my game he is everywhere and stuck on slops and objects :(
My Plan was to create a bubble for each AI to wander within only.
To create a limited area around the AI to choose random NAVmesh points within it is not too hard and there are plenty of ways and methods to do that but all of them requires the spawn position as it defines the spawn position as the center of the sphere around the AI that is allowed to choose random waypoints within.
I'm not very good with C# but so far I've been able to make a small modification to record the "first_Position" of the AI once it enters this state.
but I'm using "1" spawner for multiple prefabs .... for some reason, all of them had the same coordinates of "first_Position" even tho I had multiple spawn points
this is how I did it (( I still don't know how the FSM AI Script works but that is my own way around it))
bool checker = true;
if (checker)
{
// to make sure that this only run one time only
first_Position = fsmBehaviour.aiController.transform.position;
checker = false;
}
For Stuck issue, My plan is to check the velocity of the AI if he stuck the velocity would drop down
How can I check for the AI velocity within the STATE?
Invector team could u help me understand why is this happening? I know u guys are not every active but please hurry, I've also sent an email.
If anyone would like to help please do as I need to move on from this ASAP please.
|
|