mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 12:41:09 +01:00
Plasma flower MOD core from the lavaland patch of eden ruin (#75959)
This PR gives a small update to the patch of eden lavaland ruin, and adds a new item that can be used as an upgrade to the plasma mod core. The idea around this item is that it's a flower that has absorbed all the plasma and bad-vibes in the small area around the ruin, leaving an area full of plants, and a flower full of energy. This flower can be taken from the oasis and turned into a functional MOD core using some wires. As a MOD core, it is the same as the plasma mod core, but has a higher energy capacity, being equivalent to a super power cell. It also gives you a cool pollen effect, and spawns butterflies around you while your suit is active. These butterflies disappear when they get too far away, or if the suit deactivates. They also don't leave corpses, so they shouldn't cause too much clutter.
This commit is contained in:
@@ -51,6 +51,35 @@
|
||||
new /obj/item/mod/core/standard(drop_location())
|
||||
qdel(src)
|
||||
|
||||
/obj/item/mod/construction/lavalandcore
|
||||
name = "plasma flower"
|
||||
icon_state = "plasma-flower"
|
||||
desc = "A strange flower from the desolate wastes of lavaland. It pulses with a bright purple glow. \
|
||||
Its shape is remarkably similar to that of a MOD core."
|
||||
light_system = MOVABLE_LIGHT
|
||||
light_color = "#cc00cc"
|
||||
light_range = 2
|
||||
|
||||
/obj/item/mod/construction/lavalandcore/examine(mob/user)
|
||||
. = ..()
|
||||
. += span_notice("You could probably attach some <b>wires</b> to it...")
|
||||
|
||||
/obj/item/mod/construction/lavalandcore/attackby(obj/item/weapon, mob/user, params)
|
||||
if(!istype(weapon, /obj/item/stack/cable_coil))
|
||||
return
|
||||
|
||||
if(!weapon.tool_start_check(user, amount=2))
|
||||
return
|
||||
|
||||
to_chat(user, span_notice("You start pushing the wires into the core..."))
|
||||
if(!weapon.use_tool(src, user, 5 SECONDS, amount = 2, volume = 30))
|
||||
return
|
||||
|
||||
to_chat(user, span_notice("You add the wires to the core."))
|
||||
new /obj/item/mod/core/plasma/lavaland(drop_location())
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/item/mod/construction/plating
|
||||
name = "MOD external plating"
|
||||
desc = "External plating used to finish a MOD control unit."
|
||||
|
||||
@@ -355,3 +355,75 @@
|
||||
add_charge(uses_needed * charge_given)
|
||||
balloon_alert(user, "core refueled")
|
||||
return TRUE
|
||||
|
||||
/obj/item/mod/core/plasma/lavaland
|
||||
name = "MOD plasma flower core"
|
||||
icon_state = "mod-core-plasma-flower"
|
||||
desc = "A strange flower from the desolate wastes of lavaland. It pulses with a strange purple glow. \
|
||||
The wires coming out of it could be hooked into a MODsuit."
|
||||
light_system = MOVABLE_LIGHT
|
||||
light_color = "#cc00cc"
|
||||
light_range = 2
|
||||
|
||||
// Slightly better than the normal plasma core.
|
||||
// Not super sure if this should just be the same, but will see.
|
||||
maxcharge = 15000
|
||||
charge = 15000
|
||||
|
||||
/// The mob to be spawned by the core
|
||||
var/mob/living/spawned_mob_type = /mob/living/basic/butterfly/lavaland/temporary
|
||||
/// Max number of mobs it can spawn
|
||||
var/max_spawns = 3
|
||||
|
||||
/// Mob spawner for the core
|
||||
var/datum/component/spawner/mob_spawner
|
||||
|
||||
|
||||
/obj/item/mod/core/plasma/lavaland/Destroy()
|
||||
if(mod?.wearer)
|
||||
mod.wearer.particles = null
|
||||
return ..()
|
||||
|
||||
/obj/item/mod/core/plasma/lavaland/proc/new_mob(spawner, mob/living/basic/butterfly/lavaland/temporary/spawned)
|
||||
SIGNAL_HANDLER
|
||||
if(spawned)
|
||||
spawned.source = src
|
||||
|
||||
/obj/item/mod/core/plasma/lavaland/proc/on_toggle()
|
||||
SIGNAL_HANDLER
|
||||
if(mod.active)
|
||||
START_PROCESSING(SSprocessing, src)
|
||||
mod.wearer.particles = new /particles/pollen()
|
||||
mob_spawner = mod.wearer.AddComponent(/datum/component/spawner, spawn_types=list(spawned_mob_type), spawn_time=5 SECONDS, max_spawned=3)
|
||||
RegisterSignal(mob_spawner, COMSIG_SPAWNER_SPAWNED, PROC_REF(new_mob))
|
||||
RegisterSignal(mod.wearer, COMSIG_MOVABLE_PRE_MOVE, PROC_REF(flowas))
|
||||
|
||||
else
|
||||
STOP_PROCESSING(SSprocessing, src)
|
||||
mod.wearer.particles = null
|
||||
UnregisterSignal(mob_spawner, COMSIG_SPAWNER_SPAWNED)
|
||||
UnregisterSignal(mod.wearer, COMSIG_MOVABLE_PRE_MOVE)
|
||||
for(var/datum/mob in mob_spawner.spawned_things)
|
||||
qdel(mob)
|
||||
qdel(mob_spawner)
|
||||
|
||||
/obj/item/mod/core/plasma/lavaland/install(obj/item/mod/control/mod_unit)
|
||||
. = ..()
|
||||
RegisterSignal(mod_unit, COMSIG_MOD_TOGGLED, PROC_REF(on_toggle))
|
||||
|
||||
/obj/item/mod/core/plasma/lavaland/uninstall(obj/item/mod/control/mod_unit)
|
||||
. = ..()
|
||||
UnregisterSignal(mod_unit, COMSIG_MOD_TOGGLED)
|
||||
|
||||
/obj/item/mod/core/plasma/lavaland/proc/flowas(mob/living/wearer)
|
||||
SIGNAL_HANDLER
|
||||
var/static/list/possible_flower_types = list(
|
||||
/obj/structure/flora/bush/lavendergrass/style_random,
|
||||
/obj/structure/flora/bush/flowers_yw/style_random,
|
||||
/obj/structure/flora/bush/flowers_br/style_random,
|
||||
/obj/structure/flora/bush/flowers_pp/style_random,
|
||||
)
|
||||
var/chosen_type = pick(possible_flower_types)
|
||||
var/flower_boots = new chosen_type(get_turf(wearer))
|
||||
animate(flower_boots, alpha = 0, 1 SECONDS)
|
||||
QDEL_IN(flower_boots, 1 SECONDS)
|
||||
|
||||
Reference in New Issue
Block a user