Bot ignored player

Report bugs of MFPS 2.0 here
Post Reply
User avatar
haskoman
Contributor
Contributor
Posts: 85
Joined: Wed Aug 22, 2018 1:57 pm

Sat Jul 18, 2020 12:10 pm

Hi Lovatto,

Bots not attack player, you need attack first and after bot work and attack, can you help me please,

Its strange this bug and no error ;(
User avatar
Lovatto
Admin
Admin
Posts: 1541
Joined: Sun Dec 07, 2014 3:18 pm
Contact:

Sat Jul 18, 2020 1:12 pm

Which MFPS version are you using?
Happens in all game modes?
User avatar
haskoman
Contributor
Contributor
Posts: 85
Joined: Wed Aug 22, 2018 1:57 pm

Sat Jul 18, 2020 1:25 pm

i have the last update 1.7.5, is work good on TDM but no for FFA ;(
User avatar
Lovatto
Admin
Admin
Posts: 1541
Joined: Sun Dec 07, 2014 3:18 pm
Contact:

Sun Jul 19, 2020 3:50 am

I check this and I find an easy solution for this:

in bl_AIShooterAgent.cs -> RandomPatrol(bool precision) ->
Add these lines:

Code: Select all

 if (agentBehave == AIAgentBehave.Agressive && Target == null)
            {
                Target = GetNearestPlayer;
            }
after these lines:

Code: Select all

      else
            {
                SetDebugState(25);
                AgentState = agentBehave == AIAgentBehave.Agressive ? AIAgentState.Following : AIAgentState.Searching;
                precisionArea = 8;
            }
        }
        else
        {
            SetDebugState(26);
            AgentState = AIAgentState.Patroling;
So it should look like this:
Image
Let me know if this works for you.
User avatar
haskoman
Contributor
Contributor
Posts: 85
Joined: Wed Aug 22, 2018 1:57 pm

Sun Jul 19, 2020 5:51 am

woooooooooooooow now is work 1000000% you need update asset i think this bug is for all have buy MFPS, thanks my friend
Post Reply