mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-24 05:23:22 +01:00
Refactored do_after to use a flag-based system for options (#17127)
* Refactored do_after to use a flag-based system for options * More flags * Ditto * Use the HAS_FLAG macro * do_after pass * Fix burning paper code * Resolve issues from Fluffy's code reviews * .
This commit is contained in:
@@ -35,7 +35,7 @@
|
||||
return //no hiding mobs in there
|
||||
user.visible_message("[user] begins digging around inside of \the [src].", "You begin digging around in \the [src], trying to hide \the [W].")
|
||||
playsound(loc, 'sound/effects/plantshake.ogg', 50, 1)
|
||||
if(do_after(user, 20, act_target = src))
|
||||
if(do_after(user, 20, src))
|
||||
if(!stored_item)
|
||||
if(W.w_class <= ITEMSIZE_NORMAL)
|
||||
user.drop_from_inventory(W,src)
|
||||
@@ -53,7 +53,7 @@
|
||||
/obj/structure/flora/pottedplant/attack_hand(mob/user)
|
||||
user.visible_message("[user] begins digging around inside of \the [src].", "You begin digging around in \the [src], searching it.")
|
||||
playsound(loc, 'sound/effects/plantshake.ogg', 50, 1)
|
||||
if(do_after(user, 40, act_target = src))
|
||||
if(do_after(user, 40, src))
|
||||
if(!stored_item)
|
||||
to_chat(user,"<span class='notice'>There is nothing hidden in [src].</span>")
|
||||
else
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
if(SA.caliber == weapon.get_caliber())
|
||||
if(SA.can_be_loaded())
|
||||
visible_message(SPAN_NOTICE("[H] begins loading \the [SA] into \the [src]..."))
|
||||
if(do_after(H, weapon.load_time))
|
||||
if(do_after(H, weapon.load_time, src, DO_UNIQUE))
|
||||
if(weapon.load_ammunition(SA, H))
|
||||
visible_message(SPAN_NOTICE("[H] loads \the [SA] into \the [src]!"))
|
||||
playsound(src, 'sound/weapons/ammo_load.ogg')
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
var/datum/species/S = H.species
|
||||
if(S.mob_size >= mob_carry_size || S.resist_mod >= 10 || user.status_flags & GODMODE)
|
||||
visible_message(SPAN_NOTICE("[user] tightens their grip on [src] and starts heaving..."))
|
||||
if(do_after(user, 1 SECONDS))
|
||||
if(do_after(user, 1 SECONDS, src, DO_UNIQUE))
|
||||
visible_message(SPAN_NOTICE("[user] heaves \the [src] up!"))
|
||||
wield(user)
|
||||
return TRUE
|
||||
@@ -77,7 +77,7 @@
|
||||
var/obj/item/rig/R = H.back
|
||||
if(R.suit_is_deployed())
|
||||
visible_message(SPAN_NOTICE("[user] tightens their grip on [src] and starts heaving with some difficulty..."))
|
||||
if(do_after(user, 5 SECONDS))
|
||||
if(do_after(user, 5 SECONDS, src, DO_UNIQUE))
|
||||
visible_message(SPAN_NOTICE("[user] heaves \the [src] up!"))
|
||||
wield(user)
|
||||
return TRUE
|
||||
|
||||
Reference in New Issue
Block a user