mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-20 20:45:28 +01:00
[MIRROR] Adds moveloop bucketing, uses queues for the singulo rather then sleeps [MDB IGNORE] (#11257)
* Adds moveloop bucketing, uses queues for the singulo rather then sleeps * Update singularity.dm Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com> Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
This commit is contained in:
@@ -38,6 +38,8 @@
|
||||
var/move_self = TRUE
|
||||
///If the singularity has eaten a supermatter shard and can go to stage six
|
||||
var/consumed_supermatter = FALSE
|
||||
/// How long it's been since the singulo last acted, in seconds
|
||||
var/time_since_act = 0
|
||||
|
||||
flags_1 = SUPERMATTER_IGNORES_1
|
||||
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF | FREEZE_PROOF
|
||||
@@ -53,7 +55,7 @@
|
||||
energy = starting_energy
|
||||
//SKYRAT EDIT END
|
||||
|
||||
START_PROCESSING(SSobj, src)
|
||||
START_PROCESSING(SSsinguloprocess, src)
|
||||
SSpoints_of_interest.make_point_of_interest(src)
|
||||
|
||||
var/datum/component/singularity/new_component = AddComponent(
|
||||
@@ -83,7 +85,7 @@
|
||||
|
||||
|
||||
/obj/singularity/Destroy()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
STOP_PROCESSING(SSsinguloprocess, src)
|
||||
return ..()
|
||||
|
||||
/obj/singularity/attack_tk(mob/user)
|
||||
@@ -153,6 +155,10 @@
|
||||
energy -= round(((energy + 1) / 4), 1)
|
||||
|
||||
/obj/singularity/process(delta_time)
|
||||
time_since_act += delta_time
|
||||
if(time_since_act < 2)
|
||||
return
|
||||
time_since_act = 0
|
||||
if(current_size >= STAGE_TWO)
|
||||
if(prob(event_chance))
|
||||
event()
|
||||
|
||||
Reference in New Issue
Block a user