Merge pull request #12834 from silicons/clickcd_experimental
Experimental hybrid clickdelay system (No seriously I'm trying my best to not call it Minecraft attack delays)
This commit is contained in:
@@ -4,7 +4,9 @@
|
||||
var/beamtype = /obj/item/projectile/beam/disabler //change for adminbus
|
||||
|
||||
/obj/item/clothing/glasses/hud/security/sunglasses/disablers/ranged_attack(mob/living/carbon/human/user,atom/A, params)
|
||||
user.changeNext_move(CLICK_CD_RANGE)
|
||||
if(!user.CheckActionCooldown(CLICK_CD_RANGE))
|
||||
return
|
||||
user.last_action = world.time
|
||||
var/obj/item/projectile/beam/disabler/LE = new beamtype( loc )
|
||||
playsound(usr.loc, 'sound/weapons/taser2.ogg', 75, 1)
|
||||
LE.firer = src
|
||||
@@ -12,4 +14,4 @@
|
||||
LE.preparePixelProjectile(A, src, params)
|
||||
LE.fire()
|
||||
return TRUE
|
||||
//shamelessly copied
|
||||
//shamelessly copied
|
||||
|
||||
@@ -105,11 +105,11 @@
|
||||
return
|
||||
|
||||
var/mob/living/M = loc
|
||||
M.changeNext_move(CLICK_CD_RAPID)
|
||||
M.SetNextAction(CLICK_CD_RAPID)
|
||||
if(warcry)
|
||||
M.say("[warcry]", ignore_spam = TRUE, forced = TRUE)
|
||||
|
||||
return FALSE
|
||||
return NO_AUTO_CLICKDELAY_HANDLING | ATTACK_IGNORE_ACTION
|
||||
|
||||
/obj/item/clothing/gloves/fingerless/pugilist/rapid/AltClick(mob/user)
|
||||
var/input = stripped_input(user,"What do you want your battlecry to be? Max length of 6 characters.", ,"", 7)
|
||||
@@ -135,9 +135,9 @@
|
||||
if(target.stat != CONSCIOUS) //Can't hug people who are dying/dead
|
||||
return FALSE
|
||||
else
|
||||
M.changeNext_move(CLICK_CD_RAPID)
|
||||
M.SetNextAction(CLICK_CD_RAPID)
|
||||
|
||||
return FALSE
|
||||
return NO_AUTO_CLICKDELAY_HANDLING | ATTACK_IGNORE_ACTION
|
||||
|
||||
/obj/item/clothing/gloves/botanic_leather
|
||||
name = "botanist's leather gloves"
|
||||
|
||||
@@ -290,7 +290,7 @@
|
||||
if(!target.IsUnconscious())
|
||||
to_chat(target, "<span class='warning'>Your zealous conspirationism rapidly dissipates as the donned hat warps up into a ruined mess. All those theories starting to sound like nothing but a ridicolous fanfare.</span>")
|
||||
|
||||
/obj/item/clothing/head/foilhat/attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
|
||||
/obj/item/clothing/head/foilhat/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
|
||||
if(!warped && iscarbon(user))
|
||||
var/mob/living/carbon/C = user
|
||||
if(src == C.head)
|
||||
|
||||
@@ -219,7 +219,7 @@
|
||||
lock = TRUE
|
||||
return
|
||||
|
||||
/obj/item/clothing/neck/petcollar/locked/attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
|
||||
/obj/item/clothing/neck/petcollar/locked/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
|
||||
if(loc == user && user.get_item_by_slot(SLOT_NECK) && lock != FALSE)
|
||||
to_chat(user, "<span class='warning'>The collar is locked! You'll need unlock the collar before you can take it off!</span>")
|
||||
return
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
if(to_turf)
|
||||
user.forceMove(to_turf)
|
||||
user.SetStun(0)
|
||||
user.next_move = 1
|
||||
user.SetNextAction(0, considered_action = FALSE, immediate = FALSE)
|
||||
user.alpha = 255
|
||||
user.update_atom_colour()
|
||||
user.animate_movement = FORWARD_STEPS
|
||||
@@ -124,8 +124,8 @@
|
||||
for(var/obj/item/I in user.held_items)
|
||||
ADD_TRAIT(I, TRAIT_NODROP, CHRONOSUIT_TRAIT)
|
||||
user.animate_movement = NO_STEPS
|
||||
user.changeNext_move(8 + phase_in_ds)
|
||||
user.mob_transforming = 1
|
||||
user.DelayNextAction(8 + phase_in_ds, considered_action = FALSE, immediate = FALSE)
|
||||
user.mob_transforming = TRUE
|
||||
user.anchored = TRUE
|
||||
user.Stun(INFINITY)
|
||||
|
||||
|
||||
@@ -107,11 +107,7 @@
|
||||
/obj/item/clothing/suit/space/hardsuit/Initialize()
|
||||
if(jetpack && ispath(jetpack))
|
||||
jetpack = new jetpack(src)
|
||||
. = ..()
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/attack_self(mob/user)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
..()
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/attackby(obj/item/I, mob/user, params)
|
||||
if(istype(I, /obj/item/tank/jetpack/suit))
|
||||
|
||||
Reference in New Issue
Block a user