Fixes some runtimes with bluespace artillery, handcuffs on simple animals, lobby music start, stunbaton attack, kitchen bowl update_icon, particle accelerator admin log message, and plasmaman spec_life().

This commit is contained in:
phil235
2015-05-23 22:34:04 +02:00
parent ff3ea26a3f
commit f643769ef4
7 changed files with 19 additions and 13 deletions
@@ -23,6 +23,8 @@
var/trashtype = null //for disposable cuffs
/obj/item/weapon/restraints/handcuffs/attack(mob/living/carbon/C, mob/living/carbon/human/user)
if(!istype(C))
return
if(user.disabilities & CLUMSY && prob(50))
user << "<span class='warning'>Uh... how do those things work?!</span>"
apply_cuffs(user,user)
+2 -1
View File
@@ -128,9 +128,10 @@
"<span class='warning'>[user] has prodded you with [src]. Luckily it was off</span>")
return
else
..()
if(status)
baton_stun(L, user)
..()
/obj/item/weapon/melee/baton/proc/baton_stun(mob/living/L, mob/user)
+1 -1
View File
@@ -80,7 +80,7 @@
/client/proc/playtitlemusic()
if(!ticker || !ticker.login_music) return
if(prefs.toggles & SOUND_LOBBY)
if(prefs && (prefs.toggles & SOUND_LOBBY))
src << sound(ticker.login_music, repeat = 0, wait = 0, volume = 85, channel = 1) // MAD JAMS
/proc/get_rand_frequency()
+4 -3
View File
@@ -21,6 +21,10 @@
if(prob(80)) T.break_tile_to_plating()
else T.break_tile()
target << "<span class='userdanger'>You're hit by bluespace artillery!</span>"
log_admin("[target.name] has been hit by Bluespace Artillery fired by [usr]")
message_admins("[target.name] has been hit by Bluespace Artillery fired by [usr]")
if(target.health <= 1)
target.gib()
else
@@ -29,6 +33,3 @@
target.Weaken(20)
target.stuttering = 20
target << "<span class='userdanger'>You're hit by bluespace artillery!</span>"
log_admin("[target.name] has been hit by Bluespace Artillery fired by [usr]")
message_admins("[target.name] has been hit by Bluespace Artillery fired by [usr]")
@@ -328,7 +328,7 @@
/obj/item/weapon/reagent_containers/glass/bowl/update_icon()
overlays.Cut()
if(reagents.total_volume)
if(reagents && reagents.total_volume)
var/image/filling = image('icons/obj/food/soupsalad.dmi', "fullbowl")
filling.color = mix_color_from_reagents(reagents.reagent_list)
overlays += filling
@@ -377,11 +377,13 @@ var/global/image/plasmaman_on_fire = image("icon"='icons/mob/OnFire.dmi', "icon_
if(!istype(H.wear_suit, /obj/item/clothing/suit/space/eva/plasmaman) || !istype(H.head, /obj/item/clothing/head/helmet/space/hardsuit/plasmaman))
if(environment)
if((environment.oxygen /environment.total_moles()) >= 0.01)
if(!H.on_fire)
H.visible_message("<span class='danger'>[H]'s body reacts with the atmosphere and bursts into flames!</span>","<span class='userdanger'>Your body reacts with the atmosphere and bursts into flame!</span>")
H.adjust_fire_stacks(0.5)
H.IgniteMob()
var/total_moles = environment.total_moles()
if(total_moles)
if((environment.oxygen /total_moles) >= 0.01)
if(!H.on_fire)
H.visible_message("<span class='danger'>[H]'s body reacts with the atmosphere and bursts into flames!</span>","<span class='userdanger'>Your body reacts with the atmosphere and bursts into flame!</span>")
H.adjust_fire_stacks(0.5)
H.IgniteMob()
else
if(H.fire_stacks)
var/obj/item/clothing/suit/space/eva/plasmaman/P = H.wear_suit
@@ -211,8 +211,8 @@
/obj/machinery/particle_accelerator/control_box/proc/toggle_power()
src.active = !src.active
investigate_log("turned [active?"<font color='red'>ON</font>":"<font color='green'>OFF</font>"] by [usr ? usr.key : "outside forces"]","singulo")
message_admins("PA Control Computer turned [active ?"ON":"OFF"] by [key_name(usr, usr.client)](<A HREF='?_src_=holder;adminmoreinfo=\ref[usr]'>?</A>) in ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
log_game("PA Control Computer turned [active ?"ON":"OFF"] by [usr.ckey]([usr]) in ([x],[y],[z])")
message_admins("PA Control Computer turned [active ?"ON":"OFF"] by [usr ? key_name(usr, usr.client) : "outside forces"](<A HREF='?_src_=holder;adminmoreinfo=\ref[usr]'>?</A>) in ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
log_game("PA Control Computer turned [active ?"ON":"OFF"] by [usr ? "[usr.ckey]([usr])" : "outside forces"] in ([x],[y],[z])")
if(src.active)
src.use_power = 2
for(var/obj/structure/particle_accelerator/part in connected_parts)