mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-24 08:31:54 +00:00
* wip * wip2 * makes code actually compile on 511 + fixes * versioning * s * adds python conversion script, schema change and removes 'force ' from item_used_for_combat * fix to compile * forgot to actually commit this
41 lines
1.2 KiB
Plaintext
41 lines
1.2 KiB
Plaintext
/////SINGULARITY SPAWNER
|
|
/obj/machinery/the_singularitygen
|
|
name = "Gravitational Singularity Generator"
|
|
desc = "An odd device which produces a Gravitational Singularity when set up."
|
|
icon = 'icons/obj/singularity.dmi'
|
|
icon_state = "TheSingGen"
|
|
anchored = FALSE
|
|
density = TRUE
|
|
use_power = NO_POWER_USE
|
|
resistance_flags = FIRE_PROOF
|
|
|
|
// You can buckle someone to the singularity generator, then start the engine. Fun!
|
|
can_buckle = TRUE
|
|
buckle_lying = FALSE
|
|
buckle_requires_restraints = TRUE
|
|
|
|
var/energy = 0
|
|
var/creation_type = /obj/singularity
|
|
|
|
/obj/machinery/the_singularitygen/attack_hand(mob/user)
|
|
if(user.a_intent == INTENT_GRAB && user_buckle_mob(user.pulling, user, check_loc = 0))
|
|
return
|
|
..()
|
|
|
|
/obj/machinery/the_singularitygen/attackby(obj/item/W, mob/user, params)
|
|
if(istype(W, /obj/item/wrench))
|
|
default_unfasten_wrench(user, W, 0)
|
|
else
|
|
return ..()
|
|
|
|
/obj/machinery/the_singularitygen/process()
|
|
if(energy > 0)
|
|
if(energy >= 200)
|
|
var/turf/T = get_turf(src)
|
|
SSblackbox.record_feedback("tally", "engine_started", 1, type)
|
|
var/obj/singularity/S = new creation_type(T, 50)
|
|
transfer_fingerprints_to(S)
|
|
qdel(src)
|
|
else
|
|
energy -= 1
|