Port /tg/ move manager, drift and jetpack components. (#27698)

* Port /tg/ move manager, drift and jetpack components.

* don't add go through newtonian movement if not moved to a turf

* various cleans for blood drifts and mob speed

* fix slow meteors

* why on fuck's earth aren't speedbikes vehicles

* style lint

* also wtf

* okay i'm an idiot

* fix meaty ore speed and blood decal double stepping

* fix not unbuckling pulled object occupants

* don't bother dealing with immovable rods just yet

* exclude bubblegum and vetus from move manager for now

* fix issues related to null weightless blood icons

* reset blood icon state properly

* fuck it, we'll deal with mobs when basic mobs happen

* break infinite loop in decal splat
This commit is contained in:
warriorstar-orion
2025-01-22 22:49:58 +00:00
committed by GitHub
parent 3954981ff2
commit 157276d6cb
105 changed files with 2366 additions and 538 deletions
@@ -1,3 +1,59 @@
/datum/effect_system/trail_follow
var/turf/oldposition
var/active = FALSE
var/allow_overlap = FALSE
var/auto_process = TRUE
var/qdel_in_time = 10
var/fadetype = "ion_fade"
var/fade = TRUE
var/nograv_required = FALSE
/datum/effect_system/trail_follow/set_up(atom/atom)
attach(atom)
oldposition = get_turf(atom)
/datum/effect_system/trail_follow/Destroy()
oldposition = null
stop()
return ..()
/datum/effect_system/trail_follow/proc/stop()
oldposition = null
STOP_PROCESSING(SSfastprocess, src)
active = FALSE
return TRUE
/datum/effect_system/trail_follow/start()
oldposition = get_turf(holder)
if(!check_conditions())
return FALSE
if(auto_process)
START_PROCESSING(SSfastprocess, src)
active = TRUE
return TRUE
/datum/effect_system/trail_follow/process()
generate_effect()
/datum/effect_system/trail_follow/generate_effect()
if(!check_conditions())
return stop()
if(oldposition && !(oldposition == get_turf(holder)))
if(!has_gravity(oldposition) || !nograv_required)
var/obj/effect/E = new effect_type(oldposition)
set_dir(E)
if(fade)
flick(fadetype, E)
E.icon_state = ""
if(qdel_in_time)
QDEL_IN(E, qdel_in_time)
oldposition = get_turf(holder)
/datum/effect_system/trail_follow/proc/check_conditions()
if(!get_turf(holder))
return FALSE
return TRUE
/// Ion trails for jetpacks, ion thrusters and other space-flying things
/obj/effect/particle_effect/ion_trails
name = "ion trails"
@@ -8,6 +64,17 @@
dir = targetdir
QDEL_IN(src, 0.6 SECONDS)
/datum/effect_system/trail_follow/ion
effect_type = /obj/effect/particle_effect/ion_trails
nograv_required = TRUE
qdel_in_time = 20
/datum/effect_system/trail_follow/proc/set_dir(obj/effect/particle_effect/ion_trails/I)
I.setDir(holder.dir)
/datum/effect_system/trail_follow/ion/grav_allowed
nograv_required = FALSE
//Reagent-based explosion effect
/datum/effect_system/reagents_explosion
var/amount // TNT equivalent