mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 03:57:13 +01:00
Merge pull request #43 from Markolie/master
HUD fixes, Vox naming change, Beepsky ID fix, IPC fixes
This commit is contained in:
@@ -20,11 +20,8 @@
|
||||
if (computer)
|
||||
computer.table = src
|
||||
break
|
||||
// spawn(100) //Wont the MC just call this process() before and at the 10 second mark anyway?
|
||||
// process()
|
||||
|
||||
/obj/machinery/optable/ex_act(severity)
|
||||
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
//SN src = null
|
||||
@@ -76,41 +73,17 @@
|
||||
|
||||
|
||||
/obj/machinery/optable/MouseDrop_T(atom/movable/O as mob|obj, mob/user as mob)
|
||||
|
||||
if(O.loc == user) //no you can't pull things out of your ass
|
||||
return
|
||||
if(user.restrained() || user.stat || user.weakened || user.stunned || user.paralysis || user.resting) //are you cuffed, dying, lying, stunned or other
|
||||
return
|
||||
if(O.anchored || get_dist(user, src) > 1 || get_dist(user, O) > 1 || user.contents.Find(src)) // is the mob anchored, too far away from you, or are you too far away from the source
|
||||
return
|
||||
if(!ismob(O)) //humans only
|
||||
return
|
||||
if(istype(O, /mob/living/simple_animal) || istype(O, /mob/living/silicon)) //animals and robutts dont fit
|
||||
return
|
||||
if(!ishuman(user) && !isrobot(user)) //No ghosts or mice putting people into the sleeper
|
||||
return
|
||||
if(user.loc==null) // just in case someone manages to get a closet into the blue light dimension, as unlikely as that seems
|
||||
return
|
||||
if(!istype(user.loc, /turf) || !istype(O.loc, /turf)) // are you in a container/closet/pod/etc?
|
||||
if(usr.stat || !ishuman(usr) || usr.restrained() || !check_table(usr))
|
||||
return
|
||||
|
||||
var/mob/living/L = O
|
||||
if(!istype(L) || L.buckled)
|
||||
return
|
||||
for(var/mob/living/carbon/slime/M in range(1,L))
|
||||
if(M.Victim == L)
|
||||
usr << "[L.name] cannot be operated on while they have \a [M] attached to their head!"
|
||||
return
|
||||
if(src.victim)
|
||||
usr << "\blue <B>The table is already occupied!</B>"
|
||||
return
|
||||
|
||||
take_victim(L, user)
|
||||
take_victim(L,usr)
|
||||
return
|
||||
|
||||
/obj/machinery/optable/proc/check_victim()
|
||||
if(locate(/mob/living/carbon/human, src.loc))
|
||||
var/mob/living/carbon/human/M = locate(/mob/living/carbon/human, src.loc)
|
||||
if(M.resting)
|
||||
if(M.lying)
|
||||
src.victim = M
|
||||
icon_state = M.pulse ? "table2-active" : "table2-idle"
|
||||
return 1
|
||||
@@ -146,11 +119,7 @@
|
||||
set category = "Object"
|
||||
set src in oview(1)
|
||||
|
||||
if(usr.stat || !ishuman(usr) || usr.buckled || usr.restrained())
|
||||
return
|
||||
|
||||
if(src.victim)
|
||||
usr << "\blue <B>The table is already occupied!</B>"
|
||||
if(usr.stat || !ishuman(usr) || usr.restrained() || !check_table(usr))
|
||||
return
|
||||
|
||||
take_victim(usr,usr)
|
||||
@@ -162,5 +131,14 @@
|
||||
del(W)
|
||||
return
|
||||
|
||||
/obj/machinery/optable/slime
|
||||
icon_state = "table-slime"
|
||||
|
||||
/obj/machinery/optable/proc/check_table(mob/living/carbon/patient as mob)
|
||||
if(src.victim)
|
||||
usr << "\blue <B>The table is already occupied!</B>"
|
||||
return 0
|
||||
|
||||
if(patient.buckled)
|
||||
usr << "\blue <B>Unbuckle first!</B>"
|
||||
return 0
|
||||
|
||||
return 1
|
||||
|
||||
@@ -602,6 +602,5 @@
|
||||
if((robot.z == src.z) && !robot.blinded)
|
||||
if((skin == "bezerk") && (!("syndicate" in robot.faction)))
|
||||
continue
|
||||
for(var/obj/I in robot.contents)
|
||||
if(istype(I, /obj/item/borg/sight/hud/med))
|
||||
robot << "<span class='info'>\icon[I] Medical emergency! [crit_patient ? "<b>[crit_patient]</b>" : "A patient"] is in critical condition at [location]!"
|
||||
if(robot.sensor_mode == 2)
|
||||
robot << "<span class='info'>Medical emergency! [crit_patient ? "<b>[crit_patient]</b>" : "A patient"] is in critical condition at [location]!"
|
||||
@@ -264,7 +264,7 @@ Auto Patrol: []"},
|
||||
playsound(loc, 'sound/weapons/handcuffs.ogg', 30, 1, -2)
|
||||
target.visible_message("<span class='danger'>[src] is trying to put handcuffs on [target]!</span>",\
|
||||
"<span class='userdanger'>[src] is trying to put handcuffs on [target]!</span>")
|
||||
spawn(80)
|
||||
spawn(60)
|
||||
if( !Adjacent(target) || !isturf(target.loc) ) //if he's in a closet or not adjacent, we cancel cuffing.
|
||||
return
|
||||
if(!target.handcuffed)
|
||||
@@ -483,7 +483,5 @@ Auto Patrol: []"},
|
||||
if((human.z == src.z) && istype(human.glasses, /obj/item/clothing/glasses/hud/security) || istype(human.glasses, /obj/item/clothing/glasses/sunglasses/sechud) && !human.blinded)
|
||||
human << "<span class='info'>\icon[human.glasses] [src.name] is [arrest_type ? "detaining" : "arresting"] level [threatlevel] threat <b>[target]</b> in <b>[location]</b></span>"
|
||||
for(var/mob/living/silicon/robot in world)
|
||||
if((robot.z == src.z) && !robot.blinded)
|
||||
for(var/obj/I in robot.contents)
|
||||
if(istype(I, /obj/item/borg/sight/hud/sec))
|
||||
robot << "<span class='info'>\icon[I] [src.name] is [arrest_type ? "detaining" : "arresting"] level [threatlevel] threat <b>[target]</b> in <b>[location]</b></span>"
|
||||
if((robot.z == src.z) && !robot.blinded && robot.sensor_mode == 1)
|
||||
robot << "<span class='info'>[src.name] is [arrest_type ? "detaining" : "arresting"] level [threatlevel] threat <b>[target]</b> in <b>[location]</b></span>"
|
||||
@@ -398,7 +398,7 @@
|
||||
|
||||
//user << browse(t, "window=turretid;size=500x250")
|
||||
//onclose(user, "turretid")
|
||||
var/datum/browser/popup = new(user, "turretid", "Turret Control Panel ([area.name])")
|
||||
var/datum/browser/popup = new(user, "turretid", "Turret Control Panel ([area.name])", 500, 250)
|
||||
popup.set_content(t)
|
||||
popup.set_title_image(user.browse_rsc_icon(src.icon, src.icon_state))
|
||||
popup.open()
|
||||
|
||||
@@ -463,7 +463,6 @@
|
||||
item_state = "crowbar_red"
|
||||
|
||||
/obj/item/weapon/weldingtool/attack(mob/M as mob, mob/user as mob)
|
||||
|
||||
if(hasorgans(M))
|
||||
|
||||
var/datum/organ/external/S = M:organs_by_name[user.zone_sel.selecting]
|
||||
@@ -480,14 +479,27 @@
|
||||
return
|
||||
|
||||
if(S.brute_dam)
|
||||
S.heal_damage(15,0,0,1)
|
||||
user.visible_message("\red \The [user] patches some dents on \the [M]'s [S.display_name] with \the [src].")
|
||||
if(istype(M,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.updatehealth()
|
||||
return
|
||||
var/obj/item/weapon/weldingtool/WT = src
|
||||
if (WT.remove_fuel(0,user))
|
||||
playsound(src.loc, 'sound/items/Welder2.ogg', 50, 1)
|
||||
S.heal_damage(15,0,0,1)
|
||||
user.visible_message("\red \The [user] patches some dents on \the [M]'s [S.display_name] with \the [src].")
|
||||
if(istype(M,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.updatehealth()
|
||||
if(istype(M,/mob/living/carbon/human/machine) && M.stat == 0) // If an IPC is brought back to life by welding it, which is possible, update the mob list
|
||||
if(M in dead_mob_list)
|
||||
dead_mob_list -= M
|
||||
respawnable_list -= M
|
||||
living_mob_list += M
|
||||
mob_list += M
|
||||
return
|
||||
else
|
||||
user << "\red You need more welding fuel to complete this task."
|
||||
return
|
||||
else
|
||||
user << "Nothing to fix!"
|
||||
return
|
||||
|
||||
else
|
||||
return ..()
|
||||
|
||||
Reference in New Issue
Block a user