Fixes missing cooldowns, missing cult blade sound.

Conflicts:
	code/game/objects/items/weapons/material/kitchen.dm
This commit is contained in:
mwerezak
2015-09-09 15:13:30 -04:00
committed by HarpyEagle
parent deb215d262
commit 4951790b50
21 changed files with 53 additions and 49 deletions
+6
View File
@@ -39,6 +39,9 @@
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to flash [M.name] ([M.ckey])</font>")
msg_admin_attack("[user.name] ([user.ckey]) Used the [src.name] to flash [M.name] ([M.ckey]) (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[user.x];Y=[user.y];Z=[user.z]'>JMP</a>)")
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
user.do_attack_animation(M)
if(!clown_check(user)) return
if(broken)
user << "<span class='warning'>\The [src] is broken.</span>"
@@ -112,6 +115,9 @@
/obj/item/device/flash/attack_self(mob/living/carbon/user as mob, flag = 0, emp = 0)
if(!user || !clown_check(user)) return
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
if(broken)
user.show_message("<span class='warning'>The [src.name] is broken</span>", 2)
return
@@ -79,6 +79,8 @@
user << "<span class='notice'>\The [M]'s pupils narrow slightly, but are still very dilated.</span>"
else
user << "<span class='notice'>\The [M]'s pupils narrow.</span>"
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) //can be used offensively
flick("flash", M.flash)
else
return ..()
@@ -53,6 +53,7 @@
/obj/item/weapon/soap/attack(mob/living/target, mob/living/user, var/target_zone)
if(target && user && ishuman(target) && ishuman(user) && !user.incapacitated() && user.zone_sel &&user.zone_sel.selecting == "mouth" )
user.visible_message("<span class='danger'>\The [user] washes \the [target]'s mouth out with soap!</span>")
user.setClickCooldown(DEFAULT_QUICK_COOLDOWN) //prevent spam
return
..()
@@ -114,6 +114,9 @@
if(!do_after(user,50))
return
user.setClickCooldown(DEFAULT_QUICK_COOLDOWN)
user.do_attack_animation(M)
M.visible_message("<span class='danger'>\The [M] has been injected with \the [src] by \the [user].</span>")
var/mob/living/carbon/human/H = M
@@ -46,6 +46,7 @@
if (ismob(target) || istype(target, /turf/unsimulated) || istype(target, /turf/simulated/shuttle) || istype(target, /obj/item/weapon/storage/) || istype(target, /obj/item/clothing/accessory/storage/) || istype(target, /obj/item/clothing/under))
return
user << "Planting explosives..."
user.do_attack_animation(target)
if(do_after(user, 50) && in_range(user, target))
user.drop_item()
+4 -1
View File
@@ -74,6 +74,9 @@
msg_admin_attack("[key_name(user)] attempted to handcuff [key_name(H)]")
feedback_add_details("handcuffs","H")
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
user.do_attack_animation(H)
user.visible_message("<span class='danger'>\The [user] has put [cuff_type] on \the [H]!</span>")
// Apply cuffs.
@@ -166,4 +169,4 @@ var/last_chew = 0
item_state = null
icon = 'icons/obj/bureaucracy.dmi'
breakouttime = 200
cuff_type = "duct tape"
cuff_type = "duct tape"
@@ -30,18 +30,18 @@
if (!istype(M, /mob/living/carbon))
return
if (user && src.imp)
for (var/mob/O in viewers(M, null))
O.show_message("<span class='warning'>[user] is attemping to implant [M].</span>", 1)
M.visible_message("<span class='warning'>[user] is attemping to implant [M].</span>")
user.setClickCooldown(DEFAULT_QUICK_COOLDOWN)
user.do_attack_animation(M)
var/turf/T1 = get_turf(M)
if (T1 && ((M == user) || do_after(user, 50)))
if(user && M && (get_turf(M) == T1) && src && src.imp)
for (var/mob/O in viewers(M, null))
O.show_message("<span class='warning'>[M] has been implanted by [user].</span>", 1)
M.visible_message("<span class='warning'>[M] has been implanted by [user].</span>")
admin_attack_log(user, M, "Implanted using \the [src.name] ([src.imp.name])", "Implanted with \the [src.name] ([src.imp.name])", "used an implanter, [src.name] ([src.imp.name]), on")
user.show_message("<span class='warning'>You implanted the implant into [M].</span>")
if(src.imp.implanted(M))
src.imp.loc = M
src.imp.imp_in = M
@@ -101,13 +101,6 @@
return
return ..()
/obj/item/weapon/material/kitchen/utensil/knife/attack(target as mob, mob/living/user as mob)
if ((CLUMSY in user.mutations) && prob(50))
user << "<span class='warning'>You somehow managed to cut yourself with \the [src].</span>"
user.take_organ_damage(20)
return
return ..()
/obj/item/weapon/material/kitchen/utensil/knife/plastic
default_material = "plastic"
@@ -26,33 +26,7 @@
else
user.take_organ_damage(2*force)
return
/*this is already called in ..()
src.add_fingerprint(user)
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been attacked with [src.name] by [user.name] ([user.ckey])</font>")
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to attack [M.name] ([M.ckey])</font>")
log_attack("<font color='red'>[user.name] ([user.ckey]) attacked [M.name] ([M.ckey]) with [src.name] (INTENT: [uppertext(user.a_intent)])</font>")
*/
if (user.a_intent == I_HURT)
if(!..()) return
//playsound(src.loc, "swing_hit", 50, 1, -1)
if (M.stuttering < 8 && (!(HULK in M.mutations)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.stuttering = 8
M.Stun(8)
M.Weaken(8)
for(var/mob/O in viewers(M))
if (O.client) O.show_message("<span class='danger'>\The [M] has been beaten with \the [src] by [user]!</span>", 1, "<span class='warning'>You hear someone fall</span>", 2)
else
playsound(src.loc, 'sound/weapons/Genhit.ogg', 50, 1, -1)
M.Stun(5)
M.Weaken(5)
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been attacked with [src.name] by [user.name] ([user.ckey])</font>")
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to attack [M.name] ([M.ckey])</font>")
msg_admin_attack("[key_name(user)] attacked [key_name(user)] with [src.name] (INTENT: [uppertext(user.a_intent)])")
src.add_fingerprint(user)
for(var/mob/O in viewers(M))
if (O.client) O.show_message("<span class='danger'>\The [M] has been stunned with \the [src] by [user]!</span>", 1, "<span class='warning'>You hear someone fall</span>", 2)
return ..()
//Telescopic baton
/obj/item/weapon/melee/telebaton
+1 -1
View File
@@ -115,7 +115,7 @@
item_state = "cutters_yellow"
/obj/item/weapon/wirecutters/attack(mob/living/carbon/C as mob, mob/user as mob)
if((C.handcuffed) && (istype(C.handcuffed, /obj/item/weapon/handcuffs/cable)))
if(user.a_intent == I_HELP && (C.handcuffed) && (istype(C.handcuffed, /obj/item/weapon/handcuffs/cable)))
usr.visible_message("\The [usr] cuts \the [C]'s restraints with \the [src]!",\
"You cut \the [C]'s restraints with \the [src]!",\
"You hear cable being cut.")
@@ -22,6 +22,9 @@
msg_admin_attack("[user.name] ([user.ckey]) attacked [M.name] ([M.ckey]) with [src.name] (INTENT: [uppertext(user.a_intent)]) (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[user.x];Y=[user.y];Z=[user.z]'>JMP</a>)")
user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN)
user.do_attack_animation(M)
if (!(istype(user, /mob/living/carbon/human) || ticker) && ticker.mode.name != "monkey")
user << "<span class='danger'>You don't have the dexterity to do this!</span>"
return