mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-28 18:41:37 +00:00
c83b14b15da5a6e28e38b423edef71569f9a8ca3
123 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
589cf0a904 |
Refactors how item actions are handled (#89654)
## About The Pull Request This PR tackles our piss-poor item action handling. Currently in order to make an item only have actions when its equipped to a certain slot you need to override a proc, which I've changed by introducing an action_slots variable. I've also cleaned up a ton of action code, and most importantly moved a lot of Trigger effects on items to do_effect, which allows actions to not call ui_action_click or attack_self on an item without bypassing IsAvailible and comsigs that parent Trigger has. This resolves issues like jump boots being usable from your hands, HUDs being toggleable out of your pockets, etc. Also moved a few actions from relying on attack_self to individual handling on their side. This also stops welding masks/hardhats from showing their action while you hold them, this part of the change is just something I thought didn't make much sense - you can use their action by using them in-hand, and flickering on your action bar can be annoying when reshuffling your backpack. Closes #89653 ## Why It's Good For The Game Makes action handling significantly less ass, allows us to avoid code like this ```js /obj/item/clothing/mask/gas/sechailer/ui_action_click(mob/user, action) if(istype(action, /datum/action/item_action/halt)) halt() else adjust_visor(user) ``` |
||
|
|
90b67b0541 |
A Small Circuit Expansion: Wallmounts, Undertiles, and Wire Bundles (#89122)
## About The Pull Request
This PR adds several circuit features, and changes several
assembly-related features to make them a bit more logical in how they
work. Included are the following changes/additions:
- Assemblies and wires have been refactored with vars that describe
their behavior:
- Assemblies have an `assembly_behavior` bitflag instead of a
`attachable` var. This var has 3 flags:
- `ASSEMBLY_INPUT`: The assembly is able to pulse the wire it is
attached to.
- `ASSEMBLY_TOGGLE_ARMED`: On activation, the assembly toggles whether
it can pulse the wire it is attached to.
- `ASSEMBLY_FUNCTIONAL_OUTPUT`: On activation, the assembly does
something other than just toggling whether it's armed.
- Wires have a `wires_behavior` bitflag with 3 flags:
- `WIRES_INPUT`: The object the wires are attached to does something
when the wires are pulsed.
- `WIRES_TOGGLE_ARMED`: The object the wires are attached to can
activate assemblies attached to those wires, and is fine if all that
activating that assembly does is toggle whether it's armed.
- `WIRES_FUNCTIONAL_OUTPUT`: The object the wires are attached to
expects that assemblies attached to its wires do something other than
toggling themselves when activated.
- Buttons can only accept assemblies with `ASSEMBLY_FUNCTIONAL_OUTPUT`.
- Pressure plates can now accept any assembly with
`ASSEMBLY_FUNCTIONAL_OUTPUT`, not just signalers. Assembly shells
attached to pressure plates will draw power from the powernet if the
pressure plate is under a tile.
- Adds a new circuit component - the wire bundle.
- This component gives the circuit a number of wires corresponding to
the size of the shell.
- Each wire has a corresponding port on the component that can pulse,
and receive pulses from, that wire.
- A circuit can only have one wire bundle component.
- Assembly shells cannot be attached to these wires, and no wires will
be created if the component is added to an assembly shell.
- Available with roundstart tech.
- Adds two new shells.
- The wallmounted shell is a large shell that can be hung on walls, and
uses power from the area it's placed in.
- Frame icon:

- Constructed icon:

- The undertile shell is a small shell that only works when fit under a
floor tile, but uses power from the area it's placed in.

- Both shells support usb cables.
- The above shells are available with the Advanced Shells techweb node.
## Why It's Good For The Game
The wire bundle component complements the functionality of the assembly
shell by allowing circuits to use assemblies directly in their logic.
The wallmounted and undertile shells provide ways of placing circuits
that don't necessarily take up space for machines. The undertile shell
is particularly useful for relaying usb component data over wirenets.
Pressure plates being able to accept assemblies other than signalers
expands their uses significantly.
## Changelog
🆑
refactor: Wires and assemblies have been refactored to have
directionality to them. This mostly makes it so that assemblies can only
be attached to wires it would make sense for them to be attached to.
qol: Pressure plates can now also accept igniters, condensers, flashes,
assembly shells, and door controllers.
add: Undertile circuit shells. They only work when placed under floor
tiles, but support USB cables and use APC power instead of cell power.
add: Wallmounted circuit shells. Large shells that support USB cables
and use APC power instead of cell power.
add: Wire bundle component. Adds a number of wires to the circuit
proportional to the capacity of the shell, allowing you to use
assemblies in circuit logic.
/🆑
|
||
|
|
f057705c4f |
machine board naming convention pass (#88888)
## About The Pull Request Adjusts a bunch of machine board names to comply with the general machine board naming patterns I see. First pass just removed a bunch of errant (Machine Board)s that were still on board names despite them being automatically appended on initialization, second pass set some board designs to actually have "Board" on the end to specify that it's a board and not a whole machine. ## Why It's Good For The Game Machine board naming consistency is probably good, actually. ## Changelog 🆑 spellcheck: A handful of machine boards should no longer have two (Machine Board)s showing up in their name. spellcheck: Boulder machinery boards are now labeled as boards from autolathes/circuit imprinters. /🆑 --------- Co-authored-by: Hatterhat <Hatterhat@users.noreply.github.com> |
||
|
|
a54009fd67 |
Circuit Wirenet Components + Assembly Shell Tweaks (#88593)
## About The Pull Request Assembly shells now use power from whatever machine/borg/mech/modsuit they are attached to the wires of, instead of their own power cell, when appropriate. As for the meat of this PR, circuit wirenet components function like NTnet and NFC components, but their signals are transmitted across whatever cable network the shell (or in the case of assembly shells, the machine or button it's inserted into) is connected to. These components are available with roundstart tech. ## Why It's Good For The Game Provides a somewhat intuitive way to make circuit networks that aren't dependent on external factors to continue functioning. NTnet components require a functional NTnet relay, which usually means they need telecomms to be working. NFC components have a range limit, and you need to provide a specific reference to the circuit being communicated with. Wirenet components, on the other hand, just need the shell to be anchored (or for assembly circuits, the thing whose wire it is attached to), and for the shell to have a cable under it. Also might indirectly provide a reason to use cable layers other than the default one. ## Changelog 🆑 add: Adds circuit wirenet components, allowing data to be transmitted and received over cable networks. qol: When attached to a machine, mech, modsuit, or borg, assembly circuit shells will use power from those instead of the circuit's own cell. /🆑 |
||
|
|
2e4d70afe5 |
Updates href uses for 516 (#88699)
## About The Pull Request Was just scrolling through the Paradise github since they seem to have more work done for 516 to see if there's anything I can port over, found this and thought why not. Ports parts of https://github.com/ParadiseSS13/Paradise/pull/25105 Specifically, updaing all hrefs to use the internal ``byond://``, and adding it to grep. ## Why It's Good For The Game More work towards 516. ## Changelog Nothing player-facing. |
||
|
|
6272b3680c |
You can use a fishing rod to snatch organs during organ manipulation surgery (feat organs sanity fix) (#87774)
## About The Pull Request This allows you to use a fishing rod during the "manipulate organs" step of the aforementioned surgery to snatch organs from a target. Unlike other fish sources, this one has a negative fishing difficulty of -20, which when summed with the default minigame difficulty should still result in a negative difficulty. In layman terms, this means the minigame is skipped here (unless you're wearing some clunky stuff like insulated or boxing gloves). It also has a wait time of 8 to 13 seconds versus the more random standard 3 to 25 seconds. A small side-effect of this is that explosions during the "manipulate organs" step will basically disembowel you, but it kinda fits anyway. By the by, because of this, there is a tiny chance bluespace fishing rods can yield you random organs. Worry not, they're newly generated, so you won't be snatching it from another player by accident (at least for now). ## Why It's Good For The Game It adds more possible weird and rare shenanigans involving surgery. ## Changelog 🆑 Add: You can use a fishing rod to snatch organs during organ manipulation surgery /🆑 |
||
|
|
778ed9f1ab |
The death or internal/external organ pathing (ft. fixed fox ears and recoloring bodypart overlays with dye sprays) (#87434)
## About The Pull Request This PR kills the abstract internal and external typepaths for organs, now replaced by an EXTERNAL_ORGAN flag to distinguish the two kinds. This PR also fixes fox ears (from #87162, no tail is added) and mushpeople's caps (they should be red, the screenshot is a tad outdated). And yes, you can now use a hair dye spray to recolor body parts like most tails, podpeople hair, mushpeople caps and cat ears. The process can be reversed by using the spray again. ## Why It's Good For The Game Time-Green put some effort during the last few months to untie functions and mechanics from external/internal organ pathing. Now, all that this pathing is good for are a few typechecks, easily replaceable with bitflags. Also podpeople and mushpeople need a way to recolor their "hair". This kind of applies to fish tails from the fish infusion, which colors can't be selected right now. The rest is just there if you ever want to recolor your lizard tail for some reason. Proof of testing btw (screenshot taken before mushpeople cap fix, right side has dyed body parts, moth can't be dyed, they're already fabolous):  ## Changelog 🆑 code: Removed internal/external pathing from organs in favor of a bit flag. Hopefully this shouldn't break anything about organs. fix: Fixed invisible fox ears. fix: Fixed mushpeople caps not being colored red by default. add: You can now dye most tails, podpeople hair, mushpeople caps etc. with a hair dye spray. /🆑 |
||
|
|
2c7c76a53d |
Fixes BCI messaging and circuit laser pointers (#86978)
## About The Pull Request Closes #86968 Closes #86969 ## Changelog 🆑 fix: Fixed BCIs sending messages twice and circuit laser pointers sometimes failing to work /🆑 |
||
|
|
58501dce77 |
Reorganizes the sound folder (#86726)
## About The Pull Request <details> - renamed ai folder to announcer -- announcer -- - moved vox_fem to announcer - moved approachingTG to announcer - separated the ambience folder into ambience and instrumental -- ambience -- - created holy folder moved all related sounds there - created engineering folder and moved all related sounds there - created security folder and moved ambidet there - created general folder and moved ambigen there - created icemoon folder and moved all icebox-related ambience there - created medical folder and moved all medbay-related ambi there - created ruin folder and moves all ruins ambi there - created beach folder and moved seag and shore there - created lavaland folder and moved related ambi there - created aurora_caelus folder and placed its ambi there - created misc folder and moved the rest of the files that don't have a specific category into it -- instrumental -- - moved traitor folder here - created lobby_music folder and placed our songs there (title0 not used anywhere? - server-side modification?) -- items -- - moved secdeath to hailer - moved surgery to handling -- effects -- - moved chemistry into effects - moved hallucinations into effects - moved health into effects - moved magic into effects -- vehicles -- - moved mecha into vehicles created mobs folder -- mobs -- - moved creatures folder into mobs - moved voice into mobs renamed creatures to non-humanoids renamed voice to humanoids -- non-humanoids-- created cyborg folder created hiss folder moved harmalarm.ogg to cyborg -- humanoids -- -- misc -- moved ghostwhisper to misc moved insane_low_laugh to misc I give up trying to document this. </details> - [X] ambience - [x] announcer - [x] effects - [X] instrumental - [x] items - [x] machines - [x] misc - [X] mobs - [X] runtime - [X] vehicles - [ ] attributions ## Why It's Good For The Game This folder is so disorganized that it's vomit inducing, will make it easier to find and add new sounds, providng a minor structure to the sound folder. ## Changelog 🆑 grungussuss refactor: the sound folder in the source code has been reorganized, please report any oddities with sounds playing or not playing server: lobby music has been repathed to sound/music/lobby_music /🆑 |
||
|
|
a4328ae1f9 |
Audits tgui_input_text() for length issues (#86741)
Fixes #86784
## About The Pull Request
Although some of the issues found were a direct result from #86692
(
|
||
|
|
3690bd3d8a |
Add distance output to direction circuit component, resizes several shells (#86577)
## About The Pull Request The direction component outputs the direction of an entity if it's within 7 tiles of the circuit. Since it already checks the distance, I added distance as one of its outputs. Besides that, I did a pass over the generics and shells and resized many of them. Most I resized to be small or tiny, except for the airlock shell, which I set to be bulky because it's a whole ass door. The shells I didn't touch remain at 'normal' size. 1) All handheld shells set to small, compact remote set to tiny 2) all components and the generic of the circuit set to tiny 3) drone shell set to small 4) airlock shell set to bulky ## Why It's Good For The Game Returning the distance spares any would be circuiteers from having to do a labyrinthine set of calculations to determine distance themselves. Making most circuits more portable makes them more attractive for people to tote around. ## Changelog 🆑 Bisar qol: The 'direction' circuit component now also returns the distance of its target. balance: Most circuit shells and the generic component and generic circuit have had their size reduced. balance: The airlock circuit shell has had its size increased. /🆑 --------- Co-authored-by: Metekillot <ubuntu@ip-172-26-7-23.us-east-2.compute.internal> Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com> |
||
|
|
9a9b428b61 |
Wallening Revert [MDB Ignore][IDB Ignore] (#86161)
This PR is reverting the wallening by reverting everything up to
|
||
|
|
891394181f |
Computer console sounds (#85358)
## About The Pull Request https://github.com/user-attachments/assets/b756bc49-70f0-4c86-8b04-5f0566d606a2 I've made the sound really quiet (quieter than most other sounds in the game) so it shouldn't be too annoying, there is 7 variants of the clicks so ear fatigue shouldn't strike too bad. ## Why It's Good For The Game Clicky sounds release a dopamine surge for players and gives you audio feedback when you're doing something, it also triggers when someone is else working at a computer which tells you that they're using it. ## Changelog 🆑 grungussuss sound: computers now make clicky clacky sounds /🆑 |
||
|
|
095f7e3b70 |
Death of mutant bodyparts AND external organs (#85137)
## About The Pull Request Removes mutant bodyparts and external organs from the game completely Digitgrade behaviour was mutant bodypart for no reason Cat ears now work with the bodyparts overlay system, same as all the other external organs (since all their behaviour is now just on /organ It doesn't remove all the /external types, but moves all behaviour to /organ. I'll follow up with a PR wiping all the /external organ types, but it's just conflict heaven so not this PR I've also streamlined a lot of duplicate/weird species regeneration code Melbert did the same PR as well but due to a lack of time (?) I have absorbed his PR to double nuke mutant bodyparts ## Why It's Good For The Game Frees us from the chain of unmodular code, and kills my greatest nemesis (after the shuttle meteor murder bug) ## Changelog 🆑 Time-Green and MrMelbert Refactor: External organ behaviour has been moved to /organ, ears now use the same system as the other organs Refactor: Mutant bodyparts are dead! This likely does not mean much to the average person but it's very dear to me code: Improves digitgrade handling in preference code /🆑 I have absorbed #85126, using Melberts code to improve and add some missing changes. Mainly improving the functioning of preferences and digitgrade legs. I didn't take over the hairstyle improvements. --------- Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com> |
||
|
|
fd0ac2c533 |
Fixes circuit drone pixel/shadow offsets (#85940)
## About The Pull Request Lil guy no longer flies above ground with his shadow on the turf below him  ## Changelog 🆑 fix: Fixed circuit drone pixel/shadow offsets /🆑 |
||
|
|
8a16be72ee |
Fix carbons deathgasping twice (#84347)
## About The Pull Request They deathgasped once on the carbon level and once on the living level I also realized this check I added a while back breaks lag check mechanism so let's just change that around ## Changelog 🆑 Melbert fix: Lizards and Moths don't deathgasp twice when they die /🆑 |
||
|
|
9c9a5d28ff |
Some alt & ctrl click improvements (#84203)
## About The Pull Request
Improved code quality of both so they resemble each other. Some of the
new specs are as follows
1. Moved` COMSIG_CLICK_ALT` & `COMSIG_CLICK_ALT_SECONDARY` up i.e.
before `can_perform_action()` making them pure hooks not bound by any
action checks giving components full control over them
2. Removed range check(`CAN_I_SEE`) & view check(`is_blind()`) out of
the base alt click proc. They now only apply to living mobs and don't
apply to ghosts(ghosts don't get blind & see everything) & revenants
(the range check still applies for revenants though).
This was actually a bug because these 2 checks were only meant to see if
the loot panel could be opened (as stated in
https://github.com/tgstation/tgstation/pull/83736#discussion_r1628097941)
but because they are at the top of the proc they also apply to all alt
click actions which is not intended. Also, by moving these checks down
to mob subtype levels some of the snowflake checks like this
|
||
|
|
0db2a23faf |
Adds a new power storage type: The Megacell. Drastically reduces power cell consumption/storage. [MDB Ignore] (#84079)
## About The Pull Request As the title says. A standard power cell now only stores 10 KJ and drains power similar to how it did before the refactor to all power appliances. The new standard megacell stock part stores 1 MJ (what cells store right now). APCs and SMESs have had their power cells replaced with these megacell stock parts instead. Megacells can only be used in APCs and SMESs. It shouldn't be possible to use megacells in any typical appliance. This shouldn't change anything about how much 'use' you can get out of a power cell in regular practice. Most should operate the same and you should still get the same amount of shots out of a laser gun, and we can look at expanding what can be switched over to megacells, e.g. if we want mechs to require significantly more power than a typical appliance. Thanks to Meyhazah for the megacell icon sprites. ## Why It's Good For The Game Power cell consumption is way too high ever since the power appliance refactor that converted most things to be in joules. It's a bit ridiculous for most of our machinery to drain the station's power supply this early on. The reason it's like this is because regular appliances (laser guns, borgs, lights) all have a cell type that is identical to the APC/SMES cell type. And it means that if we want to provide an easy way to charge these appliances without making it easy to charge APCs/SMESs through a power bug exploit, we need to introduce a new cell type to differentiate between what supplies power and regular appliances that use power. This is primarily what the megacell stock part does. This moves us back to what it was originally like before the power refactor, where recharging power cells wouldn't drain an exorbitant amount of energy. However, it maintains the goal of the original refactor which was to prevent people from cheesing power generation to produce an infinite amount of power, as the power that APCs and SMESs operate at is drastically different from the power that a regular appliance uses. ## Changelog 🆑 Watermelon, Mayhazah balance: Drastically reduces the power consumption and max charge of power cells balance: Added a new stock part called the battery, used primarily in the construction of APCs and SMESs. add: Suiciding with a cell/battery will shock you and potentially dust you/shock the people around you if the charge is great enough. /🆑 --------- Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com> Co-authored-by: Pickle-Coding <58013024+Pickle-Coding@users.noreply.github.com> |
||
|
|
6fea9d999d |
Small playsound audit, particularly involving portal sounds (#83893)
## About The Pull Request I was looking at sounds (as you do) and I noticed this  These sounds don't exist We have `portal_open_1`, not `portal_open1`. This wasn't caught on compile because they used `""` and not `''`. So I went through and audited a bunch of playsound uses that don't use `''`. Only one error, fortunately Likewise there was a ton of places running `get_sfx` pointlessly (because `playsound` does it for you) so I clened that up. However while auditing the portal stuff I noticed a few oddities, so I cleaned it up a bit. Also also I added the portal sounds to the wormholes event and gave it a free ™️ optimization because it was an in-world loop ## Changelog 🆑 Melbert sound: Portals made by portal guns now make sounds as expected sound: Wormholes from the wormhole event now make sounds when formed /🆑 |
||
|
|
ff6b41aa07 |
Afterattack is dead, long live Afterattack (#83818)
## About The Pull Request - Afterattack is a very simple proc now: All it does is this, and all it's used for is for having a convenient place to put effects an item does after a successful attack (IE, the attack was not blocked)  - An overwhelming majority of afterattack implementations have been moved to `interact_with_atom` or the new `ranged_interact_with_atom` I have manually tested many of the refactored procs but there was 200+ so it's kinda hard ## Why It's Good For The Game Afterattack is one of the worst parts of the attack chain, as it simultaneously serves as a way of doing random interactions NOT AT ALL related to attacks (despite the name) while ALSO serving as the defacto way to do a ranged interaction with an item This means careless coders (most of them) may throw stuff in afterattack without realizing how wide reaching it is, which causes bugs. By making two well defined, separate procs for handing adjacent vs ranged interactions, it becomes WAY WAY WAY more easy to develop for. If you want to do something when you click on something else and you're adjacent, use `interact_with_atom` If you want to do something when you click on something else and you're not adjacent, use 'ranged_interact_with_atom` This does result in some instances of boilerplate as shown here:  But I think it's acceptable, feel free to oppose if you don't I'm sure we can think of another solution ~~Additionally it makes it easier to implement swing combat. That's a bonus I guess~~ ## Changelog 🆑 Melbert refactor: Over 200 item interactions have been refactored to use a newer, easier-to-use system. Report any oddities with using items on other objects you may see (such as surgery, reagent containers like cups and spray bottles, or construction devices), especially using something at range (such as guns or chisels) refactor: Item-On-Modsuit interactions have changed slightly. While on combat mode, you will attempt to "use" the item on the suit instead of inserting it into the suit's storage. This means being on combat mode while the suit's panel is open will block you from inserting items entirely via click (but other methods such as hotkey, clicking on the storage boxes, and mousedrop will still work). refactor: The detective's scanner will now be inserted into storage items if clicked normally, and will scan the storage item if on combat mode /🆑 |
||
|
|
f6d28662a3 |
Add circuit component cameras (#83578)
## About The Pull Request This PR introduces a limited set of camera components that can be used by surveillance security consoles and the PDA/laptop camera app. <img width="366" alt="components" src="https://github.com/tgstation/tgstation/assets/80724828/0e628863-9998-46d6-8822-e0a44543b4c2"> There is four camera components, each limited to a specified shell circuit type. Additionally, drone circuit shells can now use the recharge stations too, much like how mobs with BCIs can recharge. ### New Components <img width="136" alt="drone camera" src="https://github.com/tgstation/tgstation/assets/80724828/fd045871-56bf-44a6-bb4f-ebe895d56d3d"> * Drone Camera This camera component captures the surrounding area. It has an option to set the camera range (near 5x5/far 14x14). <img width="136" alt="bci camera" src="https://github.com/tgstation/tgstation/assets/80724828/16bf2dd1-823b-4d66-8249-5d0f1bb1b779"> * BCI Camera This camera component uses the active user's eyes as a camera function. If the user's sights are damaged, the range will be forced to the near setting. If the user is unconscious/dead/blinded or has no eyes, the stream will be cut off. It has an option to set the camera range (near 5x5/far 14x14). <img width="136" alt="polaroid camera" src="https://github.com/tgstation/tgstation/assets/80724828/7c4d53df-b4af-4f7c-8942-a63842510720"> * Polaroid Camera Add-On This camera component streams to a camera network. The camera range is hardcoded to the near setting (5x5). <img width="136" alt="airlock camera" src="https://github.com/tgstation/tgstation/assets/80724828/5d9e9d55-49fc-45a7-99c8-aaf1ae08f6d1"> * Airlock Camera This camera component streams to a camera network. The camera range is hardcoded to the near setting (5x5). ### Features * The cameras can be EMP'd and will be disabled for 90 seconds if successful * When the cameras are active, they will actively drain the cell's power per second (near range uses 3kJ & far range uses 8kJ) * Advance camera console/AIs can use these cameras, however the camera light is disabled (they will be useless in dark areas) ### Screenshots In Action <details> This is the drone camera viewed on a security camera console<br> <img width="425" alt="near" src="https://github.com/tgstation/tgstation/assets/80724828/e5247828-0fee-4552-9e70-5e5ee897c117"><br> This is the same drone, now set to the far range setting<br> <img width="425" alt="far" src="https://github.com/tgstation/tgstation/assets/80724828/e58e3e85-aa90-4f1a-9dff-957c65764b77"><br> </details> ## Why It's Good For The Game This promotes emergent gameplay and improves the overall usefulness for drones as they can be 100% used remotely. ## Changelog 🆑 add: Added new circuit camera components qol: Circuit drones can now recharge at recharge stations /🆑 --------- Co-authored-by: Watermelon914 <37270891+Watermelon914@users.noreply.github.com> |
||
|
|
7a1fecdb16 |
Check if drone is inside an object, and call the object's relaymove() proc and return (#83504)
## About The Pull Request This PR adds an additional check for drones when they're inside a container, and properly calls the inherited proc `relaymove()` ## Why It's Good For The Game This fixes bugs related to objects that can store living mobs, and properly calls the `relaymove()` related functions needed when leaving/exiting said object. https://github.com/tgstation/tgstation/assets/80724828/b5adeb49-9205-4e70-aeef-ad0428ee5e54 https://github.com/tgstation/tgstation/assets/80724828/615e2a01-802f-44e8-8750-b39bd11aad70 ## Changelog 🆑 fix: Drones stored inside objects will call the stored object's relaymove() and return upon move /🆑 |
||
|
|
2e3a90293d |
Dehardcoded modsuit fixes (#83425)
## About The Pull Request Patches up some things that were lacking post #82905 - Some missing (un)seal messages - a missed direct use of the mod_parts list EDIT: Also fixes the modsuit painter, and makes sure modsuits can still be set to use custom dmi files via `MOD_ICON_OVERRIDE`/`MOD_WORN_ICON_OVERRIDE` Fixes #83442 ## Changelog 🆑 fix: some missing modsuit (un)sealing messages should no longer be missing fix: MOD circuit adapter core deployed parts output should work again fix: Modsuit painter works again /🆑 |
||
|
|
4731db9933 |
[NO GBP]Fixes hypercharged slime core cells and circuit gun cells starting with an insignificant amount of charge. (#82977)
Scales the hypercharged slime core and wiremod gun cell maximum charge and charge rate by the STANDARD_CELL_CHARGE and STANDARD_CELL_RATE defines. Fixes their scale. Closes #82907 ## Changelog 🆑 fix: Fixes hypercharged slime core cells and circuit guns having 1,000 times less energy than intended. /🆑 |
||
|
|
635b7fa66c |
Use cell defined constants for various stuff (#82594)
## About The Pull Request This re writes most cell power usage cases with 2 defines `STANDARD_CELL_CHARGE`(Joules) & `STANDARD_CELL_RATE`(Watts) so changing cell capacity values in the future won't cause discrepancies. ## Changelog 🆑 code: most cell power usages are scaled with defined constants to help adapt to future changes /🆑 |
||
|
|
8e3f635b98 |
Alt click refactor (#82656)
## About The Pull Request Rewrites how alt click works. Based heavily on #82625. What a cool concept, it flows nicely with #82533. Fixes #81242 (tm bugs fixed) Fixes #82668 <details><summary>More info for devs</summary> Handy regex used for alt click s&r: `AltClick\((.*).*\)(\n\t.*\.\.\(\))?` `click_alt($1)` (yes I am aware this only copies the first arg. there are no other args!) ### Obj reskins No reason for obj reskin to check on every single alt click for every object. It applies to only a few items. - Moved to obj/item - Made into signal - Added screentips ### Ventcrawling Every single atmospherics machine checked for ventcrawling capability on alt click despite only 3 objects needing that functionality. This has been moved down to those individual items. </details> ## Why It's Good For The Game For players: - Alt clicking should work more logically, not causing double actions like eject disk and open item window - Added context menus for reskinnable items - Removed adjacency restriction on loot panel For devs: - Makes alt click interactions easier to work with, no more click chain nonsense and redundant guard clauses. - OOP hell reduced - Pascal Case reduced - Glorious snake case ## Changelog 🆑 add: The lootpanel now works at range. add: Screentips for reskinnable items. fix: Alt click interactions have been refactored, which may lead to unintentional changes to gameplay. Report any issues, please. /🆑 |
||
|
|
c403a6eccc |
Wraps lowertext() to ensure proper stringification. (#82442)
## About The Pull Request Fixes #82440 This PR just creates a new macro, `LOWER_TEXT()` (yes the irony is not lost on me) to wrap around all calls of `lowertext()` and ensure that whatever we input into that proc will be stringified using the `"[]"` (or `tostring()` for the nerds) operator. very simple. I also added a linter to enforce this (and prevent all forms of regression) because I think that machines should do the menial work and we shouldn't expect maintainers to remember this, let me know if you disagree. if there is a time when it should be opted out for some reason, the linter does respect it if you wrap your input with the `UNLINT()` function. |
||
|
|
6dc40ca522 |
Standardizes object deconstruction throughout the codebase. (#82280)
## About The Pull Request When it comes to deconstructing an object we have `proc/deconstruct()` & `NO_DECONSTRUCT` Lets talk about the flag first. **Problems with `NO_DECONSTRUCTION`** I know what the comment says on what it should do |
||
|
|
02d83c1f4f |
Fixes recharge stations charge rates (#82191)
## About The Pull Request - Fixes #82190 Have to now use the assigned constants and not magic number `10000`. Also stuff will take the exact charge needed without any wastage. ## Changelog 🆑 fix: recharge stations draw the same amount of power as before but directly from grid(without using apc cell power) and won't waste any excess power /🆑 --------- Co-authored-by: san7890 <the@san7890.com> |
||
|
|
c1f11f26ce |
Converts arbitrary energy units to the joule. Fixes conservation of energy issues relating to charging cells. (#81579)
## About The Pull Request Removes all arbitrary energy and power units in the codebase. Everything is replaced with the joule and watt, with 1 = 1 joule, or 1 watt if you are going to multiply by time. This is a visible change, where all arbitrary energy units you see in the game will get proper prefixed units of energy. With power cells being converted to the joule, charging one joule of a power cell will require one joule of energy. The grid will now store energy, instead of power. When an energy usage is described as using the watt, a power to energy conversion based on the relevant subsystem's timing (usually multiplying by seconds_per_tick or applying power_to_energy()) is needed before adding or removing from the grid. Power usages that are described as the watt is really anything you would scale by time before applying the load. If it's described as a joule, no time conversion is needed. Players will still read the grid as power, having no visible change. Machines that dynamically use power with the use_power() proc will directly drain from the grid (and apc cell if there isn't enough) instead of just tallying it up on the dynamic power usages for the area. This should be more robust at conserving energy as the surplus is updated on the go, preventing charging cells from nothing. APCs no longer consume power for the dynamic power usage channels. APCs will consume power for static power usages. Because static power usages are added up without checking surplus, static power consumption will be applied before any machine processes. This will give a more truthful surplus for dynamic power consumers. APCs will display how much power it is using for charging the cell. APC cell charging applies power in its own channel, which gets added up to the total. This will prevent invisible power usage you see when looking at the power monitoring console. After testing in MetaStation, I found roundstart power consumption to be around 406kW after all APCs get fully charged. During the roundstart APC charge rush, the power consumption can get as high as over 2MW (up to 25kW per roundstart APC charging) as long as there's that much available. Because of the absurd potential power consumption of charging APCs near roundstart, I have changed how APCs decide to charge. APCs will now charge only after all other machines have processed in the machines processing subsystem. This will make sure APC charging won't disrupt machines taking from the grid, and should stop APCs getting their power drained due to others demanding too much power while charging. I have removed the delays for APC charging too, so they start charging immediately whenever there's excess power. It also stops them turning red when a small amount of cell gets drained (airlocks opening and shit during APC charge rush), as they immediately become fully charged (unless too much energy got drained somehow) before changing icon. Engineering SMES now start at 100% charge instead of 75%. I noticed cells were draining earlier than usual after these changes, so I am making them start maxed to try and combat that. These changes will fix all conservation of energy issues relating to charging powercells. ## Why It's Good For The Game Closes #73438 Closes #75789 Closes #80634 Closes #82031 Makes it much easier to interface with the power system in the codebase. It's more intuitive. Removes a bunch of conservation of energy issues, making energy and power much more meaningful. It will help the simulation remain immersive as players won't encounter energy duplication so easily. Arbitrary energy units getting replaced with the joule will also tell people more meaningful information when reading it. APC charging will feel more snappy. ## Changelog 🆑 fix: Fixes conservation of energy issues relating to charging powercells. qol: APCs will display how much power they are using to charge their cell. This is accounted for in the power monitoring console. qol: All arbitrary power cell energy units you see are replaced with prefixed joules. balance: As a consequence of the conservation of energy issues getting fixed, the power consumption for charging cells is now very significant. balance: APCs only use surplus power from the grid after every machine processes when charging, preventing APCs from causing others to discharge while charging. balance: Engineering SMES start at max charge to combat the increased energy loss due to conservation of energy fixes. /🆑 --------- Co-authored-by: SyncIt21 <110812394+SyncIt21@users.noreply.github.com> Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com> |
||
|
|
47dc38fee2 |
Let's you talk through action figures, plushies, and toy mechs with .l and .r. Also a big clean up of say because its support for non-mobs was lackluster. (#81848)
|
||
|
|
b3443099b0 |
Fixes missing args in a few procs registered to COMSIG_LIVING_ELECTROCUTE_ACT (#81807)
## About The Pull Request That's it really.  It's supposed to have a `shock_source` arg, but 2/3 of the procs that are registered to this signal don't include that in their args list. ## Why It's Good For The Game Out of order positional args = bad. ## Changelog Nothing player facing (probably) |
||
|
|
70651816c2 |
Fixes complex lights not handling moving well, renames lighting defines (#81423)
## About The Pull Request [Fixes static lights not moving]( |
||
|
|
4495ea2e4d |
Refactors how machines are deconstructed (#81291)
## About The Pull Request This refactors how machines are deconstructed in the following ways - You can no longer override `obj/machinery/deconstruct()`. If you want customized behaviour then override `on_deconstruction()` instead. This comes with the added benifit of no longer needing to check for the `NO_DECONSTRUCTION` flag because the machine base proc does that for us & if it finds that flag it won't proceed to call `on_deconstruction()` meaning no machine will have a chance to spawn anything which is the current behaviour. This is required to make #81290 work for all machines at least so that machine can send the `COMSIG_OBJ_DECONSTRUCT` signal without subtypes overriding & forgetting to call the parent proc - `dump_contents()` only gets called when the machine is deconstructed not destroyed thus not leaving behind any of its contents inside. Fixes https://github.com/tgstation/tgstation/pull/81290#issuecomment-1925752583 ## Changelog 🆑 fix: machines that should not drop contents when deleted no longer do. refactor: refactors how machines are deconstructed. report bugs on github. /🆑 --------- Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com> |
||
|
|
95f01c9620 |
Circuit action button refactor (#80379)
## About The Pull Request This PR makes several changes to how circuit action buttons work: - The MOD action and BCI action components have been merged into a single component. - MOD circuit actions can be pinned from the configuration menu. This works the same way as pinning individual modules, and can be done both by the wearer and a suit AI. - Action components have an output pin for the user of the action. This allows MOD module circuits to distinguish between the wearer and an AI. - Creates a supertype for `/datum/action/item_action/mod/pinned_module` named `/datum/action/item_action/mod/pinnable`, which implements common functionality for pinned modules and pinned circuit module actions. ## Why It's Good For The Game The prior functionality of circuit MOD actions was somewhat unintuitive, requiring the user to select an action from a radial menu *after* activating the module, whether from a pinned action or from the module radial. Providing similar pinning functionality to modules themselves makes MOD actions more readily usable. Merging the two different types of circuit components into one was made with the idea that adding new types of shells with equipment actions would inflate the number of subtypes of `/obj/item/circuit_component/equipment_action` without adding much meaningful functionality. ## Changelog 🆑 qol: MOD wearers and internal AIs can pin the individual actions in a MOD circuit module in a similar way to how they can pin modules. Circuit module actions can be pinned from the configuration menu of the circuit refactor: The MOD action and BCI action components have been merged into one component - the Equipment Action component. /🆑 |
||
|
|
54ab1e3936 |
Organ movement refactor *Un-nullspaces your organs* (#79687)
<!-- Write **BELOW** The Headers and **ABOVE** The comments else it may not be viewable. --> <!-- You can view Contributing.MD for a detailed description of the pull request process. --> closes #53931, #70916, #53931 ## About The Pull Request Organs were previously stored in nullspace. Now they are stored in their prospective bodyparts. Bodyparts are now stored in the mob. I've also had to refactor a lot of code concerning organ movement. Previously, organs were only moved into bodyparts once the bodyparts were removed. To accomodate this change, two major distinctions have been made: **Bodypart removal/insertion** Called only when an organ is taken out of a bodypart. Bodypart overlays, damage modifiers or other changes that should affect a bodypart itself goes here. **Mob insertion/removal** Called when an organ is removed from a mob. This can either be directly, by taking the organ out of a mob, or by removing the bodypart that contains the organ. This lets you add and remove organ effects safely without having to worry about the bodypart. Now that we controle the movement of bodyparts and organs, we can fuck around with them more. Summoning someones head or chest or heart will actually kill them now (and quite violently I must say (chest summoning gibs lol)). https://github.com/tgstation/tgstation/assets/7501474/5efc9dd3-cfd5-4ce4-b70f-d0d74894626e I´ve also added a unit test that violently tears apart and reconstructs a person in different ways to see if they get put toghether the right way This will definitely need a testmerge. I've done a lot of testing to make sure interactions work, but more niche stuff or my own incompetence can always slip through. ## Why It's Good For The Game <!-- Argue for the merits of your changes and how they benefit the game, especially if they are controversial and/or far reaching. If you can't actually explain WHY what you are doing will improve the game, then it probably isn't good for the game in the first place. --> A lot of organ work is quite restricted. You can't C4 someones heart, you cant summon their organs and a lot of exceptions have to be made to keep organs in nullspace. This lets organs (and bodyparts) play more nicely with the rest of the game. This also makes it a lot easier to move away from extorgans since a lot of their unique movement code has been removed and or generalized. I don't like making PRs of this size (I'm so sorry reviewers), but I was in a unique position to replace the entire system in a way I couldn't have done conveniently in multiple PRs ## Changelog <!-- If your PR modifies aspects of the game that can be concretely observed by players or admins you should add a changelog. If your change does NOT meet this description, remove this section. Be sure to properly mark your PRs to prevent unnecessary GBP loss. You can read up on GBP and it's effects on PRs in the tgstation guides for contributors. Please note that maintainers freely reserve the right to remove and add tags should they deem it appropriate. You can attempt to finagle the system all you want, but it's best to shoot for clear communication right off the bat. --> 🆑 refactor: Your organs are now inside your body. Please report any issues with bodypart and organ movement, including exotic organ, on github and scream at me fix: Cases of unexpected organ movement, such as teleporting bodyparts and organs with spells, now invokes a proper reaction (usually violent death) runtime: Fixes HARS runtiming on activation/deactivation fix: Fixes lag when species swapping /🆑 <!-- Both 🆑's are required for the changelog to work! You can put your name to the right of the first 🆑 if you want to overwrite your GitHub username as author ingame. --> <!-- You can use multiple of the same prefix (they're only used for the icon ingame) and delete the unneeded ones. Despite some of the tags, changelogs should generally represent how a player might be affected by the changes rather than a summary of the PR's contents. --> |
||
|
|
00be4978ae |
Adds a user type to integrated circuits, refactors the list pick component. (#79412)
## About The Pull Request Added a user type to integrated circuits that can't be stored as a user type but can be typecasted to entity. Useful for components that directly ask for an input from the user, like the list pick component. Refactored the list pick component to use this user port and to also send failure signals whenever a success signal is not sent. Removed the triggered port for the list pick component. Also fixes a runtime that occurs with the list pick component if the list passed in only contains null values. ## Why It's Good For The Game Can't force a prompt onto people who haven't interacted with your circuit. ## Changelog 🆑 add: Added a user type to integrated circuits /🆑 --------- Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com> |
||
|
|
d6f79f4427 |
Refactor gib code to use bitflags and have documentation (#78754)
## About The Pull Request This takes all the gib related procs: - `gib()` - `spawn_gibs()` - `spill_organs()` - `spread_bodyparts()` And adds heavy documentation that communicates what the procs are used for and how the different bitflags affect them. The difference is noticeable: `gib(TRUE, FALSE, FALSE, null)` vs `gib(DROP_ORGANS|DROP_BODYPARTS)` The code is now much more legible which is important considering it's used in a lot of places! Another robust change, is that we had several places in the code where there were double negatives like so: ``` /mob/living/carbon/spill_organs(no_brain, no_organs, no_bodyparts) if(!no_bodyparts) // DOUBLE NEGATIVES ARE BAD M'KAY?!? // do stuff here ``` This is a mindfuck to untangle. I inverted a lot of these parts so we don't lose our sanity. Last thing that was changed was a big `if()` loop in the `spill_organ()` proc. This was refactored to just be a simple `for` loop with `continue` statements where we needed to skip enabled bitflags. It's now shorter and cleaner than before. The only slight gameplay change this affects is that gibbing a mob now guarantees to drop all items unless the `DROP_ITEMS` bitflag is deliberately omitted. Some places like admin gib self, we don't want this to happen. ## Why It's Good For The Game Gib code is very old. (~15 years) People kept adding more arguments to the procs when it should have been a bitflag initially. By doing it this way, there is more flexibility and readability when it comes to adding new code in the future. ## Changelog 🆑 refactor: Refactor gib code to be more robust. qol: Gibbing a mob will result in all items being dropped instead of getting deleted. There are a few exceptions (like admin gib self) where this will not take place. /🆑 |
||
|
|
14aef72a4a |
No roundstart playable MULEs / Trampling requires hacking (#76837)
## About The Pull Request Prevailing feedback has been: - The player base cannot be trusted to control MULEbots. - It should be clearer what bots can and can't do. The former is easy to fix. The latter is sort of a matter for policy but I'm going to investigate giving bots a rudimentary laws system. Plus that sounds much more controversial than this so I am going to atomise this outside of that PR. MULEbots can still be set to allow sentience by cargo technicians, but don't start that way. ADDITIONALLY this PR just changes it so that MULEbots do not crush people unless: - They have been emagged. - Their safety wire has been cut. Either means works, so it's not too hard to access for nefarious purposes, but hard to do to yourself. Otherwise they just slow down for a few seconds instead. Also fixed an unrelated name bug while I was there. Closes #76926 ## Why It's Good For The Game Players would take them, not deliver any cargo, and repeatedly ask people to lie down in front of them. Plus Tram has 5 of the things which is frankly too many to be wandering around the bar. ## Changelog 🆑 balance: You can't possess a MULE as soon as the round starts, someone will have to give you permission. balance: MULEbots no longer crush prone characters unless they have been hacked (or emagged). fix: Bots can put numbers in their names, what with being robots. admin: Adds attack logging when certain wires are cut (for instance: MULEbot safeties) /🆑 |
||
|
|
dfd4801122 |
Adds p_They (and friends) for capitalized pronoun helpers (#76910)
## About The Pull Request  Basically replaces p_they(TRUE) with p_They ## Why It's Good For The Game Fewer ambiguous parameters (what does TRUE mean when passed to p_they?) More comprehensive helper functions. ## Changelog 🆑 Tattle spellcheck: Fixed the grammar on a few revenant messages /🆑 --------- Co-authored-by: tattle <article.disaster@gmail.com> |
||
|
|
fb10121022 |
Icons folder cleaning wave two (#76788)
## About The Pull Request Further continous organizing and cleaning the Icons folder. There are still some minior nitpicks left to do, but I reached my daily sanity expenses limit again, and the faster these get in the less issues for both me and others later. Also cleans some mess I caused by my blindness last PR. ## Why It's Good For The Game Saner spriters = better sprites |
||
|
|
0d4804cfca |
MOD Complexity rebalance (#76077)
## About The Pull Request Reduced the cost of a lot of MODules. Pathfinder 2 -> 1 Tether 3 -> 1 Temperature Regulator 2 -> 1 DNA lock 2 -> 1 Health analyzer 2 -> 1 Sonar 2 -> 1 Microwave beam 2 -> 1 Drill 2 -> 1 All visors (including NV and thermals) 2 -> 1 Circuit Adapter 2 -> 1 The Mining MODsuit has had its complexity increased to 15 and now starts with the eating apparatus module, with a total base complexity of 10/15 now. The Prototype MODsuit's active slowdown has been decreased from 1.5 (!) to 1. ## Why It's Good For The Game > Reduced the cost of a lot of MODules. There's lots of cute little MODules here, and they are all despite their 'small' cost far too expensive for them to ever be used. The small little cost adds up, when you consider that two 2-complexity modules cost FOUR, which is more than most good modules (that are 3), especially when storage modules take up 3 complexity already. Think about it like genetics, imagine if geladikinesis cost 40 instability. It'd be pointless and just make it not used. > Pathfinder 2 -> 1 Pathfinder is a little buggy, a bit janky, and still just a commodity, so this might let captains keep it for themselves more often when they're kitting out their MOD. > Tether 3 -> 1 Tether costing 3 complexity is ABSURD. That's as much as the actual ion jetpacks, and that's for something which you can replace completely with a fire extinguisher, not even including the tiny 4 tiles tethering range. > Temperature Regulator 2 -> 1 This is vital for spacewalking, I really don't know why it's this expensive. Hell it should be the norm, but whatevs. > DNA lock 2 -> 1 Nobody's ever going to use this if it can just be EMPed and broken... especially when it costs 2 complexity, which is the same cost as defibs, surgical processor, holster, criminal capture.. > Health analyzer 2 -> 1 This is just a health analyzer. A small item that you're paying for the privilege of being able to have it in your janksuit. It really shouldn't cost 2 complexity, nobody ever takes this. > Sonar 2 -> 1 I don't think there's much of a reason for sonar to be 2 complexity. You might think it's nuts, but sonar really isn't that useful as it's a windup with a screen-only range. Making it 1 might let it be seen ingame at some point. > Microwave beam 2 -> 1 Despite the cool name this just fries food. I don't think that should be expensive! > Drill 2 -> 1 The drill module is mostly redundant when by the time you get it, chances are you have a plasma cutter already which is usually better, if not as space-efficient. There's also the dumb issue with drilling into gibtonite which instantly blows it up. > All visors (including NV and thermals) 2 -> 1 Similarly to the health analyzer, chances are if you HAVE the module you don't actually *need* it as you're already.. that job. Additionally, and this is also part of the reason for the NV, thermal, and even the health analyzer modules, is that traitors/nukies now have to balance MOD economy alongside TC count, and I can't tell you just how frustrating it is to buy something and be told I don't have enough complexity to put it into the MODsuit. I already spent the damn TC! > Circuit Adapter 2 -> 1 This thing seems pretty useless. All it can really do is open and close your modsuit, which like, wow okay. No need for it to be expensive. > The Mining MODsuit has had its complexity increased to 15 and now starts with the eating apparatus module, with a total base complexity of 10/13 now. The complexity increase is because for some reason the MODsuit is already filled to the brim by default, which means that actually interacting with robotics in any way is thoroughly disincentivized as you'd need to take so many modules out to do so that it makes the purchase and interaction pointless. Now you CAN go and ask robotics for anything you need, though there isn't much a miner would want and value enough to trek across the station, for now. Also, it starts with the eating apparatus because it really looked like it should! The flavor text even talks about miners, it's strange for that to be there if miners won't use it. It'll also encourage it to actually be bought more by allowing you to eat through it. > The Prototype MODsuit's active slowdown has been decreased from 1.5 (!) to 1. 1.5 is a lot, A LOT, of slowdown. For such an incredibly rare mod, it completely kills the damn thing, even for the charlie station crew! You can't fight xenos with 1.5 slowdown! Having Kinesis isn't enough of a reason to cripple it so thoroughly and pointlessly. It's 0.4 now, which is a nice middleground between 'fast' suits like the medical and security ones, and the 'slow' ones like civilian, engineering, science. ## Changelog 🆑 balance: Reduced the complexity cost of a lot of MODules. balance: Pathfinder 2 -> 1 balance: Tether 3 -> 2 balance: Temperature Regulator 2 -> 1 balance: DNA lock 2 -> 1 balance: Health analyzer 2 -> 1 balance: Sonar 2 -> 1 balance: Microwave beam 2 -> 1 balance: Drill 2 -> 1 balance: All visors (including NV and thermals) 2 -> 1 balance: Circuit Adapter 2 -> 1 balance: The Mining MODsuit has had its complexity increased to 13 and now starts with the eating apparatus module, with a total base complexity of 10/13 now. balance: The Prototype MODsuit's active slowdown has been decreased from 1.5 (!) to 1. spellcheck: Fixed a type on the energy net module. /🆑 |
||
|
|
830d2e50b4 |
Fixes some stupid airlock sleeps (#75961)
## About The Pull Request [A common problem with explosions is an overabundance of sleeping]( |
||
|
|
ae5a4f955d |
Pulls apart the vestiges of components still hanging onto signals (#75914)
## About The Pull Request Signals were initially only usable with component listeners, which while no longer the case has lead to outdated documentation, names, and a similar location in code. This pr pulls the two apart. Partially because mso thinks we should, but also because they really aren't directly linked anymore, and having them in this midstate just confuses people. [Renames comp_lookup to listen_lookup, since that's what it does]( |
||
|
|
154c9ebe82 |
Stock Part Resprite (#75149)
## About The Pull Request Resprites stock parts to bring them up to date, changes manipulators to servo motors as I couldn't make manipulators work well at this scale.  (Power cells sold separately) ## Why It's Good For The Game The old stock parts are dated, in some cased quite ugly, and in the case of manipulators a ball of assorted pixels. Incidentally removed a couple of single letter var names. ## Changelog 🆑 image: Stock parts have been resprited. code: Manipulators have been renamed to servo motors, all related types have been repathed to match. /🆑 |
||
|
|
ac5236a251 |
Refactors sheet crafting to better support directional construction (#74572)
## About The Pull Request
|
||
|
|
4c48966ff8 |
Renames delta time to be a more obvious name (#74654)
This tracks the seconds per tick of a subsystem, however note that it is not completely accurate, as subsystems can be delayed, however it's useful to have this number as a multiplier or ratio, so that if in future someone changes the subsystem wait time code correctly adjusts how fast it applies effects regexes used git grep --files-with-matches --name-only 'DT_PROB' | xargs -l sed -i 's/DT_PROB/SPT_PROB/g' git grep --files-with-matches --name-only 'delta_time' | xargs -l sed -i 's/delta_time/seconds_per_tick/g' |
||
|
|
ecbcef778d |
Refactors Regenerate Organs, and a few organ helpers (#74219)
## About The Pull Request Refactors regenerate organs to be slightly more intelligent in handling organ changes and replacements. Noteably: - We don't remove organs that were modified by the owner; such as changing out your heart for a cybernetic - We early break out of the for loop if they aren't supposed to have an organ there and remove it - We check for the organ already being correct, and just healing it and continuing if it is Also changes the names of some of the organ helpers into snake_case ### Mapping March Ckey to receive rewards: N/A ## Why It's Good For The Game ## Changelog --------- Co-authored-by: Jacquerel <hnevard@gmail.com> |
||
|
|
0e1cedd354 |
Machines can now be pried open multiple times and maintain their initial densities (#74163)
## About The Pull Request These changes fix how machines are pried open with crowbars. Currently, most machines can be pried open, but many of them have no method for being closed again. This means they can be pried once, and then never again (as their internal logic has them stuck in an "open" state). Additionally, the densities of these machines is also inconsistent, as density is tied to the procs for opening/closing machines (open = non-dense, closed = dense). Thus, these new changes allow desired densities to be passed to `open_machine()` and `close_machine()`, as well as `default_pry_open()`, meaning that atypical machine densities can be maintained (e.g. machines that should remain dense when open, or non-dense when closed). I've also added a `close_after_pry` boolean parameter to the `default_pry_open()` proc, which determines whether to immediately close a machine after opening it. This is useful for machines that don't really have a use case for remaining open, often lacking a sprite to represent this state as well. * Note: Opening and immediately closing machines with this boolean will still drop their contents onto the floor, but will now immediately "close" in their logic, allowing for further prying attempts in the future. It's worth noting that this implements default density values for these procs, which match the existing behavior for machines, so as to (hopefully) not disrupt existing or expected machine behavior. Two caveats to these changes currently exist: 1. On machines that immediately close after prying, the prying action can now be spammed to the chat with repeated clicking. I'm uncertain if this needs some sort of spam protection or if it's fine as is. 2. I've only been able to manually test this code. I'd love to write unit tests for it, as it affects a lot of different machines, but don't know where to begin with DM Unit Testing (or which files would be good examples to reference in the code base). * Note: I did manually test each and every machine that calls `default_pry_open()` and they all seem to be working correctly. (Except for `obj/machinery/plumbing/sender`, but that doesn't seem to need prying, as it has no contents to drop, only reagents.) As always, let me know if any improvements/changes should be made. This closes #26833. ## Why It's Good For The Game These changes allow crowbar prying to correctly occur multiple times on any machine, which is intended behavior. It prevents player confusion that could occur when a machine couldn't be pried open a second time during a shift, even though it had previously been pried before, forcing players to question themselves. (Are they missing something? Did they perform the action a different way last time? Is the machine actually still powered on instead of off? Etc.) These changes also maintain the correct density for machines after prying, preventing scenarios where a machine might behave differently once it had been pried open. (An example of this was being able to walk through a smartfridge after prying it open.) Additionally, players are no longer required to know/use workarounds (such as machine disassembly) to retrieve a powered-off machine's contents. Overall, these changes improve consistency around machines, creating more scenarios where they behave as players would expect. ## Changelog 🆑 fix: machines can now be pried open more than once. fix: machines now have the correct density when pried open. /🆑 --------- Co-authored-by: san7890 <the@san7890.com> |
||
|
|
f9fe79a307 |
Organ Unit Tests & Bugfixes (#73026)
## About The Pull Request This PR adds a new unit test for all organs, a new unit test for lungs, and includes improvements for the existing breath and organ_set_bonus tests. Using the tests, I was able to root out bugs in the organs. This PR includes an advanced refactor of several developer-facing functions. This PR certainly represents a "quality pass" for organs which will make them easier to develop from now on. ### Synopsis of changes: 1. Fixed many fundamental bugs in organ code, especially in `Insert()`/`Remove()` and their overrides. 2. Added two new procs to `/obj/item/organ` named `on_insert` and `on_remove`, each being called after `Insert()`/`Remove()`. 3. Added `organ_effects` lazylist to `/obj/item/organ`. Converted `organ_traits` to lazylist. 2x less empty lists per organ. 4. Adding `SHOULD_CALL_PARENT(TRUE)` to `Insert()`/`Remove()` was very beneficial to stability and overall code health. 5. Created unit test `organ_sanity` for all usable organs in the game. Tests insertion and removal. 6. Created unit test `lungs_sanity` for `/obj/item/organ/internal/lungs`. 7. Improved `breath_sanity` unit tests with additional tests and conditions. 8. Improved `organ_set_bonus_sanity` unit tests with better documentation and maintainable code. --- ### Granular bug/fix list: - A lot of organs are overriding `Insert()` to apply unique side-effects, but aren't checking the return value of the parent proc which causes the activation of side-effects even if the insertion technically fails. I noticed the use-case of applying "unique side-effects" is repeated across a lot of organs in the game, and by overriding `Insert()` the potential for bugs is very high; I solved this problem with inversion-of-control by adding two new procs to `/obj/item/organ` named `on_insert` and `on_remove`, each being called after `Insert()` and `Remove()` succeed. - Many organs, such as abductor "glands", cursed heart, demon heart, alien hive-node, alien plasma-vessel, etc, were not returning their parent's `Insert()` proc return value at all, and as a result those organs `Insert()`s were always returning `null`. I have been mopping those bugs up in my last few PRs, and now the unit test reveals it all. Functions such as those in surgery expect a truthy value to be returned from `Insert()` to represent insertion success, and otherwise it force-moves the organ out of the mob. - Fixed abductor "glands" which had a hard-del bug due to their `Remove()` not calling the parent proc. - Fixed cybernetic arm implants which had a hard-del bug due to `Remove()` not resetting their `hand` variable to `null`. - Fixed lungs gas exchange implementation, which was allowing exhaled gases to feedback into the inhaled gases, which caused Humans to inhale much more gas than intended and not exhale expected gases. ### Overview of the `organ_sanity` unit test: - The new `organ_sanity` unit test gathers all "usable" organs in the game and tests to see if their `Insert()` and `Remove()` functions behave as we expect them to. - Some organs, such as the Nightmare Brain, cause the mob's species to change which subsequently swaps out all of their organs; the unit test accounts for these organs via the typecache `species_changing_organs`. - Some organs are not usable in-game and can't be unit tested, so the unit test accounts for them via the typecache `test_organ_blacklist`. ### Overview of the `lungs_sanity` unit test: - This unit test focuses on `/obj/item/organ/internal/lungs` including Plasmaman and Ashwalker lungs. The test focuses on testing the lungs' `check_breath()` proc. - The tests are composed of calling `check_breath` with different gas mixes to test breathing and suffocation. - Includes gas exchange test for inhaled/exhaled gases, such as O2 to CO2. ### Improvements to the `breath_sanity` unit tests: - Added additional tests for suffocation with empty internals, pure Nitrogen internals, and a gas-less turf. - Includes slightly more reliable tests for internals tanks. ## Why It's Good For The Game **Organs and Lungs were mostly untested. Too many refactors have been submitted without the addition of unit tests to prove the code works at all.** Time to stop. _Time to get some help_. Due to how bad the code health is in organs, any time we've tried to work with them some sort of bug caused them to blow up in our faces. I am trying to fix some of that by establishing some standard testing for organs. These tests have revealed and allowed me to fix lot of basic developer errors/oversights, as well as a few severe bugs.  ## Changelog 🆑 A.C.M.O. fix: Fixed lungs gas exchange implementation, so you always inhale and exhale the correct gases. fix: Fixed a large quantity of hard-deletes which were being caused by organs and cybernetic organs. fix: Fixed many organs which were applying side-effects regardless of whether or not the insertion failed. code: Added unit tests for Organs. code: Added unit tests for Lungs. code: Improved unit tests for breathing. code: Improved unit tests for DNA Infuser organs. /🆑 |