BetterBorgs: droppable, swappable cyborg item interactions #2766
+383
−18
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
About the PR
Currently a work in progress, but not far off of an in-game MVP.
Certain items in cyborg modules (ore/plant bags, beakers, shakers, lighters) can be dropped. When dropped, the slot receives a placeholder item, which works similarly to, but distinct from, VirtualItems (used for dragging, carrying 2-handed things, piloting vehicles). When modules are swapped out, the state of these placeholders are kept along with the other modules in the device. The empty "hand" is unusable apart from picking up any item meeting a whitelist for the particular slot.
Droppable module items are specified with a starting item and a whitelist of items they can receive. This gives the possibility of upgradeable borg tools without needing separate modules. These items can be dropped, thrown, or inserted into machines (e.g. inserting a beaker into a chemical dispenser or chemmaster). You can pass someone your lighter, mix a drink or chems in a dispenser and pass the results to someone else.
TODOs:
[ ] In-hand visuals and item names similar to VirtualItem ("beaker slot" instead of "blocked by beaker")
[ ] Further testing.
Why / Balance
Better cyborg gameplay.
Would be useful for #2751 - a borg would be able to insert their jetpack into a canister, refuel it, eject it and pick it up again.
With this, the clowning module could accept and use banana peels and banana cream pies.
How to test
WIP
Media
WIP
Requirements
Breaking changes
Changelog
WIP
🆑