From f737f7889c63aedd21efee35b27690f4e20e241a Mon Sep 17 00:00:00 2001 From: Francis Devine Date: Thu, 18 Sep 2014 10:44:02 +1200 Subject: [PATCH] Defines for the define god --- code/__DEFINES/misc.dm | 2 ++ code/game/dna.dm | 2 +- code/game/machinery/suit_storage_unit.dm | 2 +- code/game/objects/effects/spiders.dm | 2 +- code/game/objects/structures/crates_lockers/closets.dm | 2 +- code/modules/mob/living/living.dm | 8 ++++---- 6 files changed, 10 insertions(+), 8 deletions(-) diff --git a/code/__DEFINES/misc.dm b/code/__DEFINES/misc.dm index 253b2d3a13c..0d328b256bf 100644 --- a/code/__DEFINES/misc.dm +++ b/code/__DEFINES/misc.dm @@ -35,6 +35,8 @@ #define CLICK_CD_MELEE 8 #define CLICK_CD_RANGE 4 #define CLICK_CD_HANDCUFFED 10 +#define CLICK_CD_BREAKOUT 100 +#define CLICK_CD_RESIST 20 //click cooldowns, in tenths of a second diff --git a/code/game/dna.dm b/code/game/dna.dm index cbd8ee69f33..f0309592ae2 100644 --- a/code/game/dna.dm +++ b/code/game/dna.dm @@ -383,7 +383,7 @@ if(open || !locked) //Open and unlocked, no need to escape open = 1 return - user.changeNext_move(100) + user.changeNext_move(CLICK_CD_BREAKOUT) user.last_special = world.time + 100 user << "You lean on the back of [src] and start pushing the door open. (this will take about [breakout_time] minutes.)" user.visible_message("You hear a metallic creaking from [src]!") diff --git a/code/game/machinery/suit_storage_unit.dm b/code/game/machinery/suit_storage_unit.dm index 5e98e3eafcf..6285bdcc771 100644 --- a/code/game/machinery/suit_storage_unit.dm +++ b/code/game/machinery/suit_storage_unit.dm @@ -427,7 +427,7 @@ /obj/machinery/suit_storage_unit/container_resist() var/mob/living/user = usr if(islocked) - user.changeNext_move(100) + user.changeNext_move(CLICK_CD_BREAKOUT) user.last_special = world.time + 100 var/breakout_time = 2 user << "You start kicking against the doors to escape! (This will take about [breakout_time] minutes.)" diff --git a/code/game/objects/effects/spiders.dm b/code/game/objects/effects/spiders.dm index 4b55a1e75f4..22bcccc7ca3 100644 --- a/code/game/objects/effects/spiders.dm +++ b/code/game/objects/effects/spiders.dm @@ -212,7 +212,7 @@ /obj/effect/spider/cocoon/container_resist() var/mob/living/user = usr var/breakout_time = 2 - user.changeNext_move(100) + user.changeNext_move(CLICK_CD_BREAKOUT) user.last_special = world.time + 100 user << "You struggle against the tight bonds! (This will take about [breakout_time] minutes.)" visible_message("You see something struggling and writhing in the [src]!") diff --git a/code/game/objects/structures/crates_lockers/closets.dm b/code/game/objects/structures/crates_lockers/closets.dm index db1480e7ebd..cc61b3d3319 100644 --- a/code/game/objects/structures/crates_lockers/closets.dm +++ b/code/game/objects/structures/crates_lockers/closets.dm @@ -312,7 +312,7 @@ return //Door's open, not locked or welded, no point in resisting. //okay, so the closet is either welded or locked... resist!!! - user.changeNext_move(100) + user.changeNext_move(CLICK_CD_BREAKOUT) user.last_special = world.time + 100 user << "You lean on the back of [src] and start pushing the door open. (this will take about [breakout_time] minutes.)" for(var/mob/O in viewers(src)) diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 854232a2162..c93c05847a0 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -476,7 +476,7 @@ if(!isliving(usr) || usr.next_move > world.time) return - usr.changeNext_move(20) + usr.changeNext_move(CLICK_CD_RESIST) var/mob/living/L = usr @@ -509,7 +509,7 @@ if(iscarbon(L)) var/mob/living/carbon/C = L if(C.handcuffed) - C.changeNext_move(100) + C.changeNext_move(CLICK_CD_BREAKOUT) C.last_special = world.time + 100 C.visible_message("[usr] attempts to unbuckle themself!", \ "You attempt to unbuckle yourself. (This will take around one minute and you need to stay still.)") @@ -548,7 +548,7 @@ return if(CM.canmove && (CM.last_special <= world.time)) if(CM.handcuffed || CM.legcuffed) - CM.changeNext_move(100) + CM.changeNext_move(CLICK_CD_BREAKOUT) CM.last_special = world.time + 100 if(CM.handcuffed) cuff_resist(CM.handcuffed, CM) @@ -629,4 +629,4 @@ if(what && Adjacent(who)) src.unEquip(what) who.equip_to_slot_if_possible(what, where, 0, 1) - add_logs(src, who, "equipped", object=what) \ No newline at end of file + add_logs(src, who, "equipped", object=what)