cathook icon indicating copy to clipboard operation
cathook copied to clipboard

Add more ways for bots to get health and ammo

Open EngineerGaming69 opened this issue 3 years ago • 5 comments

Resupply lockers could cause bots to try and go in enemy spawns but they do that anyways.

EngineerGaming69 avatar Jun 11 '22 09:06 EngineerGaming69

As far as I know, there's no way of checking which team's supply cabinet is which. Bots will try and path to into the enemy spawn and will not be able to get in, making them stuck and vulnerable for a good couple of seconds, if not until they get killed. Going for edibles dropped by heavies is also not a very good idea, since people will be able to exploit the bots and get them stuck (i.e. throwing an edible into the water to make the bot drown, throwing it on some cliff edge, so the bot may fall to its death, etc.). If you can figure out a way to distinguish each team's resupply locker, then that'd be great, but as of right now this cannot and will not be merged.

explowz avatar Jun 11 '22 19:06 explowz

I wanted to implement this once, seems to not be feasable with normal means. Enemy lockers do not count, and in some maps lockers change locations based on the stage of the game. Additionally, there is atleast one instance where the locker goee under the floor, the bot would indefinetly path towards it and waste a ton of time. The "proper" and basically only ways to do this without issues would be:

  • Process the triggers around the resupply station or
  • Listen for resupply events and figure out which lockers your team can touch, and work on a timer so you do not path to lockers your team has not rouched for a certain amount of time

The latter option is not going to work if noone on your team touches the resupply cabinet, but on maps like 2fort you may accidentally brush it, and avoid the need for outside interference.

The former option is not doable normally, as the server keeps all the triggers on its own end. The only way to make it possible would be to copy the entire game state and simulate the servers end of things.

Former option thus would be preferred, and could be reinforced with some additional methods, e.g. on respawn, mark nearest resupply cabinet as valid (within a certain range to avoid issues with cabinet less spawns).

Also, resupply cabinets don't strictly need to be cabinets, they can be any texture, this cannot be solved without the latter approach, but we'd have to deal with that.

LemonatedCat avatar Jun 22 '22 14:06 LemonatedCat