mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
[MIRROR] fixes constructs (#10176)
Co-authored-by: Cameron Lennox <killer65311@gmail.com>
This commit is contained in:
committed by
GitHub
parent
ad9e7bd513
commit
914b76a320
@@ -46,8 +46,7 @@
|
|||||||
/spell/aoe_turf/conjure/floor/conjure_animation(var/atom/movable/overlay/animation, var/turf/target)
|
/spell/aoe_turf/conjure/floor/conjure_animation(var/atom/movable/overlay/animation, var/turf/target)
|
||||||
animation.icon_state = "cultfloor"
|
animation.icon_state = "cultfloor"
|
||||||
flick("cultfloor",animation)
|
flick("cultfloor",animation)
|
||||||
spawn(10)
|
addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(qdel), animation), 1 SECOND)
|
||||||
qdel(animation)
|
|
||||||
|
|
||||||
/spell/aoe_turf/conjure/wall
|
/spell/aoe_turf/conjure/wall
|
||||||
name = "Lesser Construction"
|
name = "Lesser Construction"
|
||||||
@@ -65,8 +64,7 @@
|
|||||||
/spell/aoe_turf/conjure/wall/conjure_animation(var/atom/movable/overlay/animation, var/turf/target)
|
/spell/aoe_turf/conjure/wall/conjure_animation(var/atom/movable/overlay/animation, var/turf/target)
|
||||||
animation.icon_state = "cultwall"
|
animation.icon_state = "cultwall"
|
||||||
flick("cultwall",animation)
|
flick("cultwall",animation)
|
||||||
spawn(10)
|
addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(qdel), animation), 1 SECOND)
|
||||||
qdel(animation)
|
|
||||||
|
|
||||||
/spell/aoe_turf/conjure/wall/reinforced
|
/spell/aoe_turf/conjure/wall/reinforced
|
||||||
name = "Greater Construction"
|
name = "Greater Construction"
|
||||||
@@ -194,7 +192,6 @@
|
|||||||
return */
|
return */
|
||||||
for(var/turf/T in targets)
|
for(var/turf/T in targets)
|
||||||
for(var/obj/machinery/door/door in T.contents)
|
for(var/obj/machinery/door/door in T.contents)
|
||||||
spawn(1)
|
|
||||||
if(istype(door,/obj/machinery/door/airlock))
|
if(istype(door,/obj/machinery/door/airlock))
|
||||||
var/obj/machinery/door/airlock/AL = door
|
var/obj/machinery/door/airlock/AL = door
|
||||||
AL.locked = 0 //The spirits of the damned care not for your locks.
|
AL.locked = 0 //The spirits of the damned care not for your locks.
|
||||||
@@ -523,19 +520,23 @@
|
|||||||
return P
|
return P
|
||||||
|
|
||||||
/obj/item/spell/construct/projectile/proc/set_up(atom/hit_atom, mob/living/user)
|
/obj/item/spell/construct/projectile/proc/set_up(atom/hit_atom, mob/living/user)
|
||||||
if(spell_projectile)
|
if(!spell_projectile || !pay_energy(energy_cost_per_shot) || !owner)
|
||||||
if(pay_energy(energy_cost_per_shot))
|
|
||||||
if(pre_shot_delay)
|
|
||||||
var/image/target_image = image(icon = 'icons/obj/spells.dmi', loc = get_turf(hit_atom), icon_state = "target")
|
|
||||||
user << target_image
|
|
||||||
user.Stun(pre_shot_delay / 10)
|
|
||||||
sleep(pre_shot_delay)
|
|
||||||
qdel(target_image)
|
|
||||||
if(owner)
|
|
||||||
return TRUE
|
|
||||||
return FALSE // We got dropped before the firing occured.
|
|
||||||
return TRUE // No delay, no need to check.
|
|
||||||
return FALSE
|
return FALSE
|
||||||
|
if(!pre_shot_delay)
|
||||||
|
return TRUE
|
||||||
|
var/succeeded = FALSE
|
||||||
|
|
||||||
|
var/turf/T = get_turf(hit_atom)
|
||||||
|
var/image/target_image = image(icon = 'icons/obj/spells.dmi', icon_state = "target")
|
||||||
|
|
||||||
|
T.add_overlay(target_image)
|
||||||
|
|
||||||
|
if(do_after(user, pre_shot_delay))
|
||||||
|
succeeded = TRUE
|
||||||
|
|
||||||
|
T.cut_overlay(target_image)
|
||||||
|
qdel(target_image)
|
||||||
|
return succeeded
|
||||||
|
|
||||||
/obj/item/spell/construct/spawner
|
/obj/item/spell/construct/spawner
|
||||||
name = "spawner template"
|
name = "spawner template"
|
||||||
|
|||||||
@@ -100,8 +100,8 @@
|
|||||||
/mob/living/simple_mob/construct/cultify()
|
/mob/living/simple_mob/construct/cultify()
|
||||||
return
|
return
|
||||||
|
|
||||||
/mob/living/simple_mob/construct/New()
|
/mob/living/simple_mob/construct/Initialize(mapload)
|
||||||
..()
|
. = ..()
|
||||||
name = text("[initial(name)] ([rand(1, 1000)])")
|
name = text("[initial(name)] ([rand(1, 1000)])")
|
||||||
real_name = name
|
real_name = name
|
||||||
for(var/spell in construct_spells)
|
for(var/spell in construct_spells)
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
..()
|
..()
|
||||||
if(spell_masters)
|
if(spell_masters)
|
||||||
for(var/obj/screen/movable/spell_master/spell_master in spell_masters)
|
for(var/obj/screen/movable/spell_master/spell_master in spell_masters)
|
||||||
spell_master.toggle_open(1)
|
spell_master.toggle_open()
|
||||||
client.screen -= spell_master
|
client.screen -= spell_master
|
||||||
|
|
||||||
// TODO: Investigate if this matters
|
// TODO: Investigate if this matters
|
||||||
|
|||||||
Reference in New Issue
Block a user