mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-20 19:44:09 +01:00
@@ -40,8 +40,7 @@
|
||||
if(!isturf(I.loc)) //If it isn't on the floor. Do some checks to see if it's in our hands or a box. Otherwise give up.
|
||||
if(istype(I.loc,/obj/item/weapon/storage)) //in a container.
|
||||
var/obj/item/weapon/storage/U = I.loc
|
||||
user.client.screen -= I
|
||||
U.contents.Remove(I)
|
||||
U.remove_from_storage(I, src)
|
||||
else if(user.l_hand == I) //in a hand
|
||||
user.drop_l_hand()
|
||||
else if(user.r_hand == I) //in a hand
|
||||
@@ -59,6 +58,7 @@
|
||||
I.pixel_x = 0 //then remove it so it'll stay within the evidence bag
|
||||
I.pixel_y = 0
|
||||
var/image/img = image("icon"=I, "layer"=FLOAT_LAYER) //take a snapshot. (necessary to stop the underlays appearing under our inventory-HUD slots ~Carn
|
||||
img.plane = FLOAT_PLANE
|
||||
I.pixel_x = xx //and then return it
|
||||
I.pixel_y = yy
|
||||
overlays += img
|
||||
@@ -69,7 +69,7 @@
|
||||
w_class = I.w_class
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/evidencebag/attack_self(mob/user as mob)
|
||||
/obj/item/weapon/evidencebag/attack_self(mob/user)
|
||||
if(contents.len)
|
||||
var/obj/item/I = contents[1]
|
||||
user.visible_message("<span class='notice'>[user] takes [I] out of [src].</span>", "<span class='notice'>You take [I] out of [src].</span>",\
|
||||
@@ -83,17 +83,16 @@
|
||||
else
|
||||
to_chat(user, "[src] is empty.")
|
||||
icon_state = "evidenceobj"
|
||||
return
|
||||
|
||||
/obj/item/weapon/storage/box/evidence
|
||||
name = "evidence bag box"
|
||||
desc = "A box claiming to contain evidence bags."
|
||||
New()
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/item/weapon/storage/box/evidence/New()
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
new /obj/item/weapon/evidencebag(src)
|
||||
..()
|
||||
@@ -1,6 +1,6 @@
|
||||
/obj/item/device/mmi/posibrain
|
||||
name = "positronic brain"
|
||||
desc = "A cube of shining metal, four inches to a side and covered in shallow grooves. The speaker switch is set to 'on'."
|
||||
desc = "A cube of shining metal, four inches to a side and covered in shallow grooves."
|
||||
icon = 'icons/obj/assemblies.dmi'
|
||||
icon_state = "posibrain"
|
||||
w_class = 3
|
||||
@@ -15,11 +15,14 @@
|
||||
var/silenced = 0 //if set to 1, they can't talk.
|
||||
var/next_ping_at = 0
|
||||
|
||||
/obj/item/device/mmi/posibrain/examine(mob/user)
|
||||
if(..(user, 1))
|
||||
to_chat(user, "Its speaker is turned [silenced ? "off" : "on"].")
|
||||
|
||||
/obj/item/device/mmi/posibrain/attack_self(mob/user as mob)
|
||||
/obj/item/device/mmi/posibrain/attack_self(mob/user)
|
||||
if(brainmob && !brainmob.key && searching == 0)
|
||||
//Start the process of searching for a new user.
|
||||
to_chat(user, "\blue You carefully locate the manual activation switch and start the positronic brain's boot process.")
|
||||
to_chat(user, "<span class='notice'>You carefully locate the manual activation switch and start the positronic brain's boot process.</span>")
|
||||
icon_state = "posibrain-searching"
|
||||
ghost_volunteers.Cut()
|
||||
src.searching = 1
|
||||
@@ -31,18 +34,10 @@
|
||||
transfer_personality(O)
|
||||
reset_search()
|
||||
else
|
||||
if(silenced)
|
||||
silenced = 0
|
||||
to_chat(user, "<span class='notice'>You toggle the speaker to 'on', on the [src].</span>")
|
||||
desc = "A cube of shining metal, four inches to a side and covered in shallow grooves. The speaker switch is set to 'on'."
|
||||
if(brainmob && brainmob.key)
|
||||
to_chat(brainmob, "<span class='warning'>Your internal speaker has been toggled to 'on'.</span>")
|
||||
else
|
||||
silenced = 1
|
||||
to_chat(user, "<span class='notice'>You toggle the speaker to 'off', on the [src].</span>")
|
||||
desc = "A cube of shining metal, four inches to a side and covered in shallow grooves. The speaker switch is set to 'off'."
|
||||
if(brainmob && brainmob.key)
|
||||
to_chat(brainmob, "<span class='warning'>Your internal speaker has been toggled to 'off'.</span>")
|
||||
silenced = !silenced
|
||||
to_chat(user, "<span class='notice'>You toggle the speaker [silenced ? "off" : "on"].</span>")
|
||||
if(brainmob && brainmob.key)
|
||||
to_chat(brainmob, "<span class='warning'>Your internal speaker has been toggled [silenced ? "off" : "on"].</span>")
|
||||
|
||||
/obj/item/device/mmi/posibrain/proc/request_player()
|
||||
for(var/mob/dead/observer/O in player_list)
|
||||
|
||||
@@ -1,23 +1,33 @@
|
||||
//TODO: Convert this over for languages.
|
||||
/mob/living/carbon/brain/say(var/message, var/datum/language/speaking = null)
|
||||
if(silent)
|
||||
if(!can_speak(warning = TRUE))
|
||||
return
|
||||
|
||||
if(prob(emp_damage * 4))
|
||||
if(prob(10)) //10% chance to drop the message entirely
|
||||
return
|
||||
else
|
||||
message = Gibberish(message, (emp_damage*6))//scrambles the message, gets worse when emp_damage is higher
|
||||
|
||||
..(message)
|
||||
|
||||
/mob/living/carbon/brain/whisper(message as text)
|
||||
if(!can_speak(warning = TRUE))
|
||||
return
|
||||
|
||||
if(!(container && istype(container, /obj/item/device/mmi)))
|
||||
return //No MMI, can't speak, bucko./N
|
||||
else
|
||||
if(container && istype(container, /obj/item/device/mmi/posibrain))
|
||||
var/obj/item/device/mmi/posibrain/P = container
|
||||
if(P && P.silenced)
|
||||
to_chat(usr, "<span class='warning'>You cannot speak, as your internal speaker has been toggled to 'off'.</span>")
|
||||
return
|
||||
if(prob(emp_damage*4))
|
||||
if(prob(10))//10% chane to drop the message entirely
|
||||
return
|
||||
else
|
||||
message = Gibberish(message, (emp_damage*6))//scrambles the message, gets worse when emp_damage is higher
|
||||
..()
|
||||
|
||||
/mob/living/carbon/brain/can_speak(var/warning = FALSE)
|
||||
. = ..()
|
||||
|
||||
..(message)
|
||||
if(!istype(container, /obj/item/device/mmi))
|
||||
. = FALSE
|
||||
else if(istype(container, /obj/item/device/mmi/posibrain))
|
||||
var/obj/item/device/mmi/posibrain/P = container
|
||||
if(P && P.silenced)
|
||||
if(warning)
|
||||
to_chat(usr, "<span class='warning'>You cannot speak, as your internal speaker is turned off.</span>")
|
||||
. = FALSE
|
||||
|
||||
/mob/living/carbon/brain/handle_message_mode(var/message_mode, var/message, var/verb, var/speaking, var/used_radios, var/alt_name)
|
||||
switch(message_mode)
|
||||
|
||||
@@ -1246,7 +1246,6 @@
|
||||
return 0
|
||||
return 1
|
||||
|
||||
|
||||
/mob/living/carbon/human/proc/get_visible_gender()
|
||||
if(wear_suit && wear_suit.flags_inv & HIDEJUMPSUIT && ((head && head.flags_inv & HIDEMASK) || wear_mask))
|
||||
return NEUTER
|
||||
|
||||
@@ -83,12 +83,14 @@
|
||||
var/current_pda_messaging = null
|
||||
|
||||
/mob/living/silicon/pai/New(var/obj/item/device/paicard)
|
||||
src.loc = paicard
|
||||
loc = paicard
|
||||
card = paicard
|
||||
if(card)
|
||||
faction = card.faction.Copy()
|
||||
sradio = new(src)
|
||||
if(card)
|
||||
if(!card.radio)
|
||||
card.radio = new /obj/item/device/radio(src.card)
|
||||
card.radio = new /obj/item/device/radio(card)
|
||||
radio = card.radio
|
||||
|
||||
//Default languages without universal translator software
|
||||
@@ -122,7 +124,7 @@
|
||||
|
||||
// this function shows the information about being silenced as a pAI in the Status panel
|
||||
/mob/living/silicon/pai/proc/show_silenced()
|
||||
if(src.silence_time)
|
||||
if(silence_time)
|
||||
var/timeleft = round((silence_time - world.timeofday)/10 ,1)
|
||||
stat(null, "Communications system reboot in -[(timeleft / 60) % 60]:[add_zero(num2text(timeleft % 60), 2)]")
|
||||
|
||||
@@ -130,7 +132,7 @@
|
||||
/mob/living/silicon/pai/Stat()
|
||||
..()
|
||||
statpanel("Status")
|
||||
if(src.client.statpanel == "Status")
|
||||
if(client.statpanel == "Status")
|
||||
show_silenced()
|
||||
|
||||
if(proc_holder_list.len)//Generic list for proc_holder objects.
|
||||
@@ -138,20 +140,20 @@
|
||||
statpanel("[P.panel]","",P)
|
||||
|
||||
/mob/living/silicon/pai/check_eye(var/mob/user as mob)
|
||||
if(!src.current)
|
||||
if(!current)
|
||||
return null
|
||||
user.reset_perspective(src.current)
|
||||
user.reset_perspective(current)
|
||||
return 1
|
||||
|
||||
/mob/living/silicon/pai/blob_act()
|
||||
if(src.stat != 2)
|
||||
src.adjustBruteLoss(60)
|
||||
src.updatehealth()
|
||||
if(stat != 2)
|
||||
adjustBruteLoss(60)
|
||||
updatehealth()
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/mob/living/silicon/pai/restrained()
|
||||
if(istype(src.loc,/obj/item/device/paicard))
|
||||
if(istype(loc,/obj/item/device/paicard))
|
||||
return 0
|
||||
..()
|
||||
|
||||
@@ -165,18 +167,18 @@
|
||||
// 33% chance to change prime directive (based on severity)
|
||||
// 33% chance of no additional effect
|
||||
|
||||
src.silence_time = world.timeofday + 120 * 10 // Silence for 2 minutes
|
||||
silence_time = world.timeofday + 120 * 10 // Silence for 2 minutes
|
||||
to_chat(src, "<font color=green><b>Communication circuit overload. Shutting down and reloading communication circuits - speech and messaging functionality will be unavailable until the reboot is complete.</b></font>")
|
||||
if(prob(20))
|
||||
var/turf/T = get_turf_or_move(src.loc)
|
||||
var/turf/T = get_turf_or_move(loc)
|
||||
for(var/mob/M in viewers(T))
|
||||
M.show_message("\red A shower of sparks spray from [src]'s inner workings.", 3, "\red You hear and smell the ozone hiss of electrical sparks being expelled violently.", 2)
|
||||
return src.death(0)
|
||||
return death(0)
|
||||
|
||||
switch(pick(1,2,3))
|
||||
if(1)
|
||||
src.master = null
|
||||
src.master_dna = null
|
||||
master = null
|
||||
master_dna = null
|
||||
to_chat(src, "<font color=green>You feel unbound.</font>")
|
||||
if(2)
|
||||
var/command
|
||||
@@ -184,7 +186,7 @@
|
||||
command = pick("Serve", "Love", "Fool", "Entice", "Observe", "Judge", "Respect", "Educate", "Amuse", "Entertain", "Glorify", "Memorialize", "Analyze")
|
||||
else
|
||||
command = pick("Serve", "Kill", "Love", "Hate", "Disobey", "Devour", "Fool", "Enrage", "Entice", "Observe", "Judge", "Respect", "Disrespect", "Consume", "Educate", "Destroy", "Disgrace", "Amuse", "Entertain", "Ignite", "Glorify", "Memorialize", "Analyze")
|
||||
src.pai_law0 = "[command] your master."
|
||||
pai_law0 = "[command] your master."
|
||||
to_chat(src, "<font color=green>Pr1m3 d1r3c71v3 uPd473D.</font>")
|
||||
if(3)
|
||||
to_chat(src, "<font color=green>You feel an electric surge run through your circuitry and become acutely aware at how lucky you are that you can still feel at all.</font>")
|
||||
@@ -194,15 +196,15 @@
|
||||
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
if(src.stat != 2)
|
||||
if(stat != 2)
|
||||
adjustBruteLoss(100)
|
||||
adjustFireLoss(100)
|
||||
if(2.0)
|
||||
if(src.stat != 2)
|
||||
if(stat != 2)
|
||||
adjustBruteLoss(60)
|
||||
adjustFireLoss(60)
|
||||
if(3.0)
|
||||
if(src.stat != 2)
|
||||
if(stat != 2)
|
||||
adjustBruteLoss(30)
|
||||
|
||||
return
|
||||
@@ -219,8 +221,8 @@
|
||||
playsound(loc, M.attack_sound, 50, 1, 1)
|
||||
for(var/mob/O in viewers(src, null))
|
||||
O.show_message("<span class='danger'>[M]</span> [M.attacktext] [src]!", 1)
|
||||
M.create_attack_log("<font color='red'>attacked [src.name] ([src.ckey])</font>")
|
||||
src.create_attack_log("<font color='orange'>was attacked by [M.name] ([M.ckey])</font>")
|
||||
M.create_attack_log("<font color='red'>attacked [name] ([ckey])</font>")
|
||||
create_attack_log("<font color='orange'>was attacked by [M.name] ([M.ckey])</font>")
|
||||
var/damage = rand(M.melee_damage_lower, M.melee_damage_upper)
|
||||
adjustBruteLoss(damage)
|
||||
updatehealth()
|
||||
@@ -230,7 +232,7 @@
|
||||
to_chat(M, "You cannot attack people before the game has started.")
|
||||
return
|
||||
|
||||
if(istype(src.loc, /turf) && istype(src.loc.loc, /area/start))
|
||||
if(istype(loc, /turf) && istype(loc.loc, /area/start))
|
||||
to_chat(M, "You cannot attack someone in the spawn area.")
|
||||
return
|
||||
|
||||
@@ -245,16 +247,16 @@
|
||||
M.do_attack_animation(src)
|
||||
var/damage = rand(10, 20)
|
||||
if(prob(90))
|
||||
playsound(src.loc, 'sound/weapons/slash.ogg', 25, 1, -1)
|
||||
playsound(loc, 'sound/weapons/slash.ogg', 25, 1, -1)
|
||||
for(var/mob/O in viewers(src, null))
|
||||
if((O.client && !( O.blinded )))
|
||||
O.show_message(text("<span class='danger'>[] has slashed at []!</span>", M, src), 1)
|
||||
if(prob(8))
|
||||
flash_eyes(affect_silicon = 1)
|
||||
src.adjustBruteLoss(damage)
|
||||
src.updatehealth()
|
||||
adjustBruteLoss(damage)
|
||||
updatehealth()
|
||||
else
|
||||
playsound(src.loc, 'sound/weapons/slashmiss.ogg', 25, 1, -1)
|
||||
playsound(loc, 'sound/weapons/slashmiss.ogg', 25, 1, -1)
|
||||
for(var/mob/O in viewers(src, null))
|
||||
if((O.client && !( O.blinded )))
|
||||
O.show_message(text("<span class='danger'>[] took a swipe at []!</span>", M, src), 1)
|
||||
@@ -263,16 +265,16 @@
|
||||
/mob/living/silicon/pai/proc/switchCamera(var/obj/machinery/camera/C)
|
||||
usr:cameraFollow = null
|
||||
if(!C)
|
||||
src.unset_machine()
|
||||
src.reset_perspective(null)
|
||||
unset_machine()
|
||||
reset_perspective(null)
|
||||
return 0
|
||||
if(stat == 2 || !C.status || !(src.network in C.network)) return 0
|
||||
if(stat == 2 || !C.status || !(network in C.network)) return 0
|
||||
|
||||
// ok, we're alive, camera is good and in our network...
|
||||
|
||||
src.set_machine(src)
|
||||
set_machine(src)
|
||||
src:current = C
|
||||
src.reset_perspective(C)
|
||||
reset_perspective(C)
|
||||
return 1
|
||||
|
||||
/mob/living/silicon/pai/verb/reset_record_view()
|
||||
@@ -291,8 +293,8 @@
|
||||
/mob/living/silicon/pai/cancel_camera()
|
||||
set category = "pAI Commands"
|
||||
set name = "Cancel Camera View"
|
||||
src.reset_perspective(null)
|
||||
src.unset_machine()
|
||||
reset_perspective(null)
|
||||
unset_machine()
|
||||
src:cameraFollow = null
|
||||
|
||||
//Addition by Mord_Sith to define AI's network change ability
|
||||
@@ -300,8 +302,8 @@
|
||||
/mob/living/silicon/pai/proc/pai_network_change()
|
||||
set category = "pAI Commands"
|
||||
set name = "Change Camera Network"
|
||||
src.reset_perspective(null)
|
||||
src.unset_machine()
|
||||
reset_perspective(null)
|
||||
unset_machine()
|
||||
src:cameraFollow = null
|
||||
var/cameralist[0]
|
||||
|
||||
@@ -316,8 +318,8 @@
|
||||
if(C.network != "CREED" && C.network != "thunder" && C.network != "RD" && C.network != "toxins" && C.network != "Prison") COMPILE ERROR! This will have to be updated as camera.network is no longer a string, but a list instead
|
||||
cameralist[C.network] = C.network
|
||||
|
||||
src.network = input(usr, "Which network would you like to view?") as null|anything in cameralist
|
||||
to_chat(src, "\blue Switched to [src.network] camera network.")
|
||||
network = input(usr, "Which network would you like to view?") as null|anything in cameralist
|
||||
to_chat(src, "\blue Switched to [network] camera network.")
|
||||
//End of code by Mord_Sith
|
||||
*/
|
||||
|
||||
@@ -327,7 +329,7 @@
|
||||
/mob/verb/makePAI(var/turf/t in view())
|
||||
var/obj/item/device/paicard/card = new(t)
|
||||
var/mob/living/silicon/pai/pai = new(card)
|
||||
pai.key = src.key
|
||||
pai.key = key
|
||||
card.setPersonality(pai)
|
||||
|
||||
*/
|
||||
@@ -394,7 +396,7 @@
|
||||
|
||||
var/choice
|
||||
var/finalized = "No"
|
||||
while(finalized == "No" && src.client)
|
||||
while(finalized == "No" && client)
|
||||
|
||||
choice = input(usr,"What would you like to use for your mobile chassis icon? This decision can only be made once.") as null|anything in possible_chassis
|
||||
if(!choice) return
|
||||
@@ -425,9 +427,9 @@
|
||||
set category = "IC"
|
||||
|
||||
// Pass lying down or getting up to our pet human, if we're in a rig.
|
||||
if(stat == CONSCIOUS && istype(src.loc,/obj/item/device/paicard))
|
||||
if(stat == CONSCIOUS && istype(loc,/obj/item/device/paicard))
|
||||
resting = 0
|
||||
var/obj/item/weapon/rig/rig = src.get_rig()
|
||||
var/obj/item/weapon/rig/rig = get_rig()
|
||||
if(istype(rig))
|
||||
rig.force_rest(src)
|
||||
else
|
||||
@@ -449,15 +451,15 @@
|
||||
updatehealth()
|
||||
N.use(1)
|
||||
user.visible_message("<span class='notice'>[user.name] applied some [W] at [src]'s damaged areas.</span>",\
|
||||
"<span class='notice'>You apply some [W] at [src.name]'s damaged areas.</span>")
|
||||
"<span class='notice'>You apply some [W] at [name]'s damaged areas.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>All [src.name]'s systems are nominal.</span>")
|
||||
to_chat(user, "<span class='notice'>All [name]'s systems are nominal.</span>")
|
||||
|
||||
return
|
||||
else if(W.force)
|
||||
visible_message("<span class='danger'>[user.name] attacks [src] with [W]!</span>")
|
||||
src.adjustBruteLoss(W.force)
|
||||
src.updatehealth()
|
||||
adjustBruteLoss(W.force)
|
||||
updatehealth()
|
||||
else
|
||||
visible_message("<span class='warning'>[user.name] bonks [src] harmlessly with [W].</span>")
|
||||
spawn(1)
|
||||
@@ -529,9 +531,9 @@
|
||||
|
||||
var/msg = "<span class='info'>"
|
||||
|
||||
switch(src.stat)
|
||||
switch(stat)
|
||||
if(CONSCIOUS)
|
||||
if(!src.client) msg += "\nIt appears to be in stand-by mode." //afk
|
||||
if(!client) msg += "\nIt appears to be in stand-by mode." //afk
|
||||
if(UNCONSCIOUS) msg += "\n<span class='warning'>It doesn't seem to be responding.</span>"
|
||||
if(DEAD) msg += "\n<span class='deadsay'>It looks completely unsalvageable.</span>"
|
||||
|
||||
|
||||
@@ -130,12 +130,12 @@ var/list/alldepartments = list()
|
||||
if(href_list["dept"])
|
||||
if(authenticated)
|
||||
var/lastdestination = destination
|
||||
var/list/combineddepartments = alldepartments
|
||||
var/list/combineddepartments = alldepartments.Copy()
|
||||
if(long_range_enabled)
|
||||
combineddepartments += admin_departments
|
||||
combineddepartments += admin_departments.Copy()
|
||||
|
||||
if(emagged)
|
||||
combineddepartments += hidden_admin_departments
|
||||
combineddepartments += hidden_admin_departments.Copy()
|
||||
|
||||
destination = input(usr, "To which department?", "Choose a department", "") as null|anything in combineddepartments
|
||||
if(!destination)
|
||||
|
||||
Reference in New Issue
Block a user