[Ready][MDB IGNORE] Bot Multi-Z Movement
About The Pull Request
Right, first of all! Resolves #1973 Resolves #732
Edit: Ports the a modified version of the PR from upstream: BeeStation/BeeStation-Hornet/pull/7587 Also dependant on PR: BeeStation/NSV13/pull/2050
Information the Mappers need to know Bot Elevators are placed down in the same manner that Ladders are placed down, IE, on the same tile coordinates on different Z-levels.
Navigation Beacons are now linked to the overmap ship itself, this means two things:
- The Bots will now go through the entire list of all beacons on the map, whenever they’re looking for their next beacon, potentially slowing them down if there are too many beacons.
- In order to form a network with a beacon on another level the beacon closest to the elevator will need to have their destination be a beacon on the next Z-level, like Deck1Up with the destination being Deck2Receive.
-
- Now the beacon telling them to go upstairs doesn’t have to be directly next to the elevator as that was an example, however the pathfinding will try to find the fastest path to get to the elevator and the search might not cover the entire ship before the pathfinding gives up, so test if they can find a path to the elevator.
Back to your regular schedule program
While this PR is capable of being used on any ship that has a bot elevator on it, if the AI is the one doing the summoning, however it can't do the Multi-Z Patrol thing just yet, as that requires all ships to have their navigation beacons reprogrammed from going in one big loop to instead going from destination to destination and then finally up a ladder, after which the next deck will also need a route that has a navigation beacon programmed to make the bot go downwards.
(This can easily be implemented by copying over the location name of a beacon downstairs, as the next_patrol destination of some navbeacon upstairs)
Ports some of the code introduced by this PR: tgstation/tgstation/pull/65906 Full credit for the code used to find the closest ladder goes to cacogen. Although the code has been modified
- [x] Implements the ability for bots to go between z-levels
- [x] Implement the ability for bots to patrol through z-levels
- [x] Implement the ability to summon bots from other z-levels
- [x] Implement the ability for the AI to call bots to other z-levels
- [x] Implement this ability for Mulebots to deliver stuff between z-levels
- [x] Implement Patrol Network for Eclipse
- [x] Implement multi-Z patrol network to all the currently played maps
-
- [x] Atlas
-
- [x] Aetherwhisp
-
- [x] Tycoon
-
- [x] Galactica
-
- [x] Snake
- [x] Implement Mulebot Delivery areas on all the maps where it makes sense for them
-
- [x] Atlas
-
- [x] Aetherwhisp
-
- [x] Tycoon
-
- [x] Galactica
-
- [x] Snake
Second of all! Some bots, possibly all of them, are now capable of moving between Z-levels if one of the following conditions are met:
- The AI has slammed down a waypoint on another Z-level, like on the bottom deck or the upper deck.
-
- If this happens then the bot will instantly head for the nearest bot elevator it can find from its current position, upon arriving to this bot elevator it will check the original waypoint and use the bot elevator to either go up or down, afterwards it resets the bot call command before promptly running it yet again, this time with the original waypoint as the final destination.
-
-
- This annoyingly produces a text message in the chat saying that the call command has been reset.
-
- A Navigation Beacon has a destination that's located on another Z-level, currently it's restricted to only check Z-level 2 and 3 which seems to always be the Z-levels the ships various decks are located on.
-
- Upon detecting the beacons location on another deck, the bot will try heading for the nearest bot elevator possible.
-
- I've introduced a new structure which uses the same code as the ladders however this thing is specifically designed to be used by bots and will reject anyone else trying to use it to go up or down, this thing is called a bot elevator, the reason I introduced this thing is because...well it's easier for mappers to just replicate what they do with ladders for these things and then no longer have to worry about it.
-
-
- Upon reaching the bot elevator it will go down, or up it, and promptly forget the original destination and start heading for the nearest beacon it can find (could possibly also be trying to reach the next beacon from the original destination one)
-
- A PDA has Summoned this bot.
Third of all! The Bot Elevators They're currently using a temporary upside down version of the bin icon from the mining folder and act the same as ladders except for only being usable by bots, these things are created because coughMoisturizercough wanted ladders for bots only.
Anyways for any future mappers reading this, basically just do the same thing you do with ladders for these things.
Currently only the Atlas has a somewhat semi-working patrol network, although it sometimes gets stuck upstairs if the bot originally started its route on the navigation beacon outside the Head of Security's office.
And now for the horrible, horrible reveal, these bots are using KNPC Z-level travel to be capable of doing this stuff.
Why It's Good For The Game
Bot uses bot elevators. Bot is now advanced boi capable of patrolling.
Changelog
:cl: add: Added the ability for bots to go up and down bot elevators. add: Added the ability for bots to find a route to another Z-level if called to it. add: Added the ability for bots to have a patrol route going downstairs or upstairs using bot elevators. add: Added the ability for bots to be summoned using a PDA on another z-level. add: Added the ability for mulebots to travel between Z-levels. add: Gave Medibots Maintenance Access, this is an NSV13 only thing as some maps have bot elevators in maintenance areas. add: Added some Mulebots to various maps for multi-Z delivery testing. add: Added the ability to summon bots from other station Z-levels in the bot control computer program /:cl:
This pull request has conflicts, please resolve those before we can evaluate the pull request.