Add cooldowns to licking and dogborgs

They didn't have one, now it's the default attack click cooldown time.

Resolves #1266
This commit is contained in:
Arokha Sieyes
2017-03-30 12:52:53 -04:00
parent 6e9bb05555
commit ea52a15c90
2 changed files with 7 additions and 3 deletions
@@ -51,7 +51,6 @@
w_class = ITEMSIZE_NORMAL
update_icon()
//Boop //New and improved, now a simple reagent sniffer.
/obj/item/device/dogborg/boop_module
name = "boop module"
@@ -77,6 +76,7 @@
var/pressure = environment.return_pressure()
var/total_moles = environment.total_moles
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
user.visible_message("<span class='notice'>[user] sniffs the air.</span>", "<span class='notice'>You sniff the air...</span>")
user << "<span class='notice'><B>Smells like:</B></span>"
@@ -97,6 +97,7 @@
if(!istype(O))
return
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
user.visible_message("<span class='notice'>[user] sniffs at \the [O.name].</span>", "<span class='notice'>You sniff \the [O.name]...</span>")
if(!isnull(O.reagents))
@@ -216,8 +217,10 @@
/obj/item/device/dogborg/tongue/afterattack(atom/target, mob/user, proximity)
if(!proximity)
return
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
if(user.client && (target in user.client.screen))
user << "<span class='warning'>You need to take that [target.name] off before cleaning it!</span>"
user << "<span class='warning'>You need to take \the [target.name] off before cleaning it!</span>"
else if(istype(target,/obj/effect/decal/cleanable))
user.visible_message("[user] begins to lick off \the [target.name].", "<span class='notice'>You begin to lick off \the [target.name]...</span>")
if(do_after (user, 50))
+2 -1
View File
@@ -256,9 +256,10 @@
if(!istype(tasted))
return
if(src.sleeping || src.resting || src.weakened || src.stat >= DEAD)
if(!src.canClick() || incapacitated(INCAPACITATION_ALL))
return
src.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
var/taste_message = ""
if(tasted.vore_taste && (tasted.vore_taste != ""))
taste_message += "[tasted.vore_taste]"