Do bots have memory?

Discussions about Coding and Scripting

Do bots have memory?

Postby MEAT » Wed Jan 25, 2017 3:30 am

Reason why I ask is...on a few occasions I've been in a couple different maps (playing sniper redeemer) and have killed bots at a long range only to have them spawn back into the game and immediately fire back at me.
And the weird part is...in addition to being a great distance away I was also in a somewhat hidden spot within the map.
So how does the bot know where I am? :?
Image
User avatar
MEAT
Skilled
 
Posts: 234
Joined: Tue Apr 22, 2008 4:14 am
Personal rank: better then you...

Re: Do bots have memory?

Postby EvilGrins » Wed Jan 25, 2017 3:36 am

MEAT wrote:So how does the bot know where I am?

Image
Do you bathe regularly?
http://unreal-games.livejournal.com/
Image
medor wrote:Replace Skaarj with EvilGrins :mrgreen:
User avatar
EvilGrins
Godlike
 
Posts: 6118
Joined: Thu Jun 30, 2011 8:12 pm
Location: Palo Alto, CA
Personal rank: God of Fudge

Re: Do bots have memory?

Postby papercoffee » Wed Jan 25, 2017 3:57 am

MEAT wrote:Reason why I ask is...on a few occasions I've been in a couple different maps (playing sniper redeemer) and have killed bots at a long range only to have them spawn back into the game and immediately fire back at me.
And the weird part is...in addition to being a great distance away I was also in a somewhat hidden spot within the map.
So how does the bot know where I am? :?

From my rudimentary knowledge:
Because bots cheat and can see you all the time but they are coded not to care as long as you can't see them. If you can see them kicks another code routine in and they react according to their settings, alertnesses, fight style, movement etc...

But Sektor and Higor can explain this much better and in detail.
User avatar
papercoffee
Site Staff
 
Posts: 9037
Joined: Wed Jul 15, 2009 11:36 am
Location: Cologne, the city with the big cathedral.
Personal rank: coffee addicted !!!

Re: Do bots have memory?

Postby sektor2111 » Wed Jan 25, 2017 9:34 am

Creatures (and not only them) have a variable/slot called "enemy" which is not always removed post killed due to Unreal Engine timings.
Aside Bot is a script not a live person, for my DM I wrote a few lines dedicated to ScriptedPawn making it to play DM because It won't forget enemy so soon as Bot does. Yes, after some time they forget/quit tracking enemy. But I told at the monster a secret:
Code: Select all
LastSeenPos=Enemy.Location;
GoToState('Attacking');
After this sequence you don't wanna Skaarj with Insta tracking you. Bot is more enhanced - usually is busy with items but it might hang on a combat state post killed, code telling based on internal timers to fire weapon into enemy direction getting over killed occurrence (without checking if do still has weapon).
In heavy loaded maps and a slower CPU, Bot might be ghosting exactly like monster - returning to roaming and forgetting to respawn post death, or because an external code was dropping it into a state without checking Health - if any of you is checking wrappers added by me at MBot you'll say that I'm mad, but I had reasons to slap those things. More you play with them, the more you'll want them replaced - is what I did after all.

Edit: In other order of ideas for me this is not a problem, Bot is generally stupid (even utterly idiot) and at least a bit of aggressiveness makes things more challenging than being an easy target. I wrote some lines on purpose when Bot has a direct line with any Pawn from any angle to manage situation as a threat so it will react accordingly. I'm tired randomly to see the same reaction on combat running to some health around and if you have a heavy weapon you can fire at Inventory and Bot will find health and death in the spot because the loser always needs a load unable to understand that in such tactical situation is better to chicken out rather than running useless in a spot that can be aimed by enemy and delivering a successful frag.
User avatar
sektor2111
Godlike
 
Posts: 3768
Joined: Sun May 09, 2010 6:15 pm
Location: On the roof.

Re: Do bots have memory?

Postby MEAT » Thu Jan 26, 2017 3:44 pm

Pretty cool...thank you for the input.
Now I need to study up on the Mbot.
Image
User avatar
MEAT
Skilled
 
Posts: 234
Joined: Tue Apr 22, 2008 4:14 am
Personal rank: better then you...


Return to Coding, Scripting

Who is online

Users browsing this forum: No registered users and 2 guests