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:
Cody Brittain
2023-09-27 12:17:14 +00:00
committed by GitHub
parent 085e7c8107
commit 0a3dac31e0
125 changed files with 531 additions and 314 deletions
@@ -28,7 +28,7 @@
/obj/structure/bed/stool/chair/remote/attackby(obj/item/W, mob/user)
if(portable_type && W.iswrench())
user.visible_message(SPAN_NOTICE("\The [user] starts dismantling \the [src]..."), SPAN_NOTICE("You start dismantling \the [src]..."))
if(do_after(user, 20 SECONDS, TRUE, src))
if(do_after(user, 20 SECONDS, src, DO_REPAIR_CONSTRUCT))
user.visible_message(SPAN_NOTICE("\The [user] dismantles \the [src]."), SPAN_NOTICE("You dismantle \the [src]."))
var/obj/kit = new portable_type(get_turf(src))
user.put_in_hands(kit)