mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-13 09:05:11 +01:00
dbadf01a35
## About The Pull Request This PR sort-of brings back old IEDs, albeit much more freeform compared to their previous iteration. Using #94861's ``spark_act`` interactions they can now be made by filling up a soda can with a variety of chemicals (welding fuel being the easiest to obtain), dunking in a piece of wire, taping it up (optional, required if using welding fuel or plasma) and lighting it on fire with a lighter or welding tool (anything that's hot enough works, really) They have a random delay of 2-4 seconds, and can be disarmed by snipping the fuse with wirecutters in time before they detonate (or don't, depending on the mixture) There's also a new, more "professional" improvised chemical explosive in the form of beakerbombs. These can be assembled by putting a lid on a beaker (alt-click, prevents the beaker from spilling its contents when thrown) and attaching an assembly with an igniter or a condenser to it. <img width="150" height="90" alt="dreamseeker_2OKpZeN7ay" src="https://github.com/user-attachments/assets/599e75ea-9653-4db9-a915-b2ca6307635f" /> When triggered, igniters will heat the reagents up by a bit while condensers will cool them down. However, you can also attach and wire up a power cell, which will cause it to dump all of its power into the beaker when the igniter fires off, triggering ``spark_act`` interactions potentially causing a larger explosion. <img width="534" height="447" alt="dreamseeker_k9Uzf18Eoa" src="https://github.com/user-attachments/assets/4cfed5b4-3875-4522-9bfa-5f6a3c8e0864" /> Decently sized boom from The Contraption. Plasma and welding fuel's potency inside of beakerbombs/soda cans is significantly reduced compared to other riggable objects (strengthdiv is 3 times higher) as they're very easy to obtain and would make for very powerful explosives, considering their very strong strengthdiv as most rigging interactions use very little fuel/plasma to cause a large explosion, which was carried over to the new system. (Don't worry, this still leaves them at sensible values with welding fuel being about as strong as old IEDs on average) Closes #94990 via having plasma's electrical power modifier have a decline past a certain point based on its volume ## Why It's Good For The Game #81529 didn't justify IED removal whatsoever and I think with new mechanics these can be used as easier (but weaker) to make improvised bombs, being much less clunky to make and use than pipebombs. Beakerbombs are essentially a somewhat weaker (even with metamat beakers, you're still 20u short of a normal large beaker grenade at 200u) form of grenades, but have access to new interactions involving charged up explosions, which could make for some variety among chemists' weaponry. ## Changelog 🆑 add: Added back IEDs made by attaching some wire and tape to a soda can filled with fuel, plasma, or any other explosive of your choice. They need to be lit on fire with a lighter or a welding tool. add: You can now attach a lid to beakers with alt-click, preventing them from being spilled when thrown. add: Added beakerbombs, made by attaching an assembly (with optional power cell and wiring) to a lidded beaker. balance: Rigged explosions now create flames. balance: Plasma explosions now limit their explosion potency past a certain point based on their volume /🆑
35 lines
1.5 KiB
Plaintext
35 lines
1.5 KiB
Plaintext
// If an item has the dunkable element, it's able to be dunked into reagent containers like beakers and glasses.
|
|
// Dunking the item into a container will transfer reagents from the container to the item.
|
|
/datum/element/dunkable
|
|
element_flags = ELEMENT_BESPOKE
|
|
argument_hash_start_idx = 2
|
|
var/dunk_amount // the amount of reagents that will be transferred from the container to the item on each click
|
|
|
|
/datum/element/dunkable/Attach(datum/target, amount_per_dunk)
|
|
. = ..()
|
|
if(!isitem(target))
|
|
return ELEMENT_INCOMPATIBLE
|
|
dunk_amount = amount_per_dunk
|
|
RegisterSignal(target, COMSIG_ITEM_INTERACTING_WITH_ATOM, PROC_REF(get_dunked))
|
|
|
|
/datum/element/dunkable/Detach(datum/target)
|
|
. = ..()
|
|
UnregisterSignal(target, COMSIG_ITEM_INTERACTING_WITH_ATOM)
|
|
|
|
/datum/element/dunkable/proc/get_dunked(obj/item/source, mob/user, atom/target, params)
|
|
SIGNAL_HANDLER
|
|
|
|
if(!target.is_dunkable()) // container should be a valid target for dunking
|
|
return NONE
|
|
if(!target.is_drainable())
|
|
to_chat(user, span_warning("[target] is unable to be dunked in!"))
|
|
return ITEM_INTERACT_BLOCKING
|
|
if(target.reagents.trans_to(source, dunk_amount, transferred_by = user)) //if reagents were transferred, show the message
|
|
to_chat(user, span_notice("You dunk \the [target] into \the [target]."))
|
|
return ITEM_INTERACT_SUCCESS
|
|
if(!target.reagents.total_volume)
|
|
to_chat(user, span_warning("[target] is empty!"))
|
|
else
|
|
to_chat(user, span_warning("[source] is full!"))
|
|
return ITEM_INTERACT_BLOCKING
|