mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Merge remote-tracking branch 'upstream/master' into dev-freeze
Conflicts: code/game/objects/structures/girders.dm code/modules/mob/living/carbon/human/human_damage.dm
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
|
||||
/datum/controller/process/machinery/doWork()
|
||||
internal_sort()
|
||||
internal_process_pipenets()
|
||||
internal_process_machinery()
|
||||
internal_process_power()
|
||||
internal_process_power_drain()
|
||||
@@ -57,6 +58,14 @@
|
||||
processing_power_items.Remove(I)
|
||||
scheck()
|
||||
|
||||
/datum/controller/process/machinery/proc/internal_process_pipenets()
|
||||
for(var/datum/pipe_network/pipeNetwork in pipe_networks)
|
||||
if(istype(pipeNetwork) && !pipeNetwork.disposed)
|
||||
pipeNetwork.process()
|
||||
scheck()
|
||||
continue
|
||||
|
||||
pipe_networks.Remove(pipeNetwork)
|
||||
|
||||
/datum/controller/process/machinery/getStatName()
|
||||
return ..()+"([machines.len])"
|
||||
return ..()+"(MCH:[machines.len] PWR:[powernets.len] PIP:[pipe_networks.len])"
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
/datum/controller/process/pipenet/setup()
|
||||
name = "pipenet"
|
||||
schedule_interval = 20 // every 2 seconds
|
||||
|
||||
/datum/controller/process/pipenet/doWork()
|
||||
for(var/datum/pipe_network/pipeNetwork in pipe_networks)
|
||||
if(istype(pipeNetwork) && !pipeNetwork.disposed)
|
||||
pipeNetwork.process()
|
||||
scheck()
|
||||
continue
|
||||
|
||||
pipe_networks.Remove(pipeNetwork)
|
||||
|
||||
/datum/controller/process/pipenet/getStatName()
|
||||
return ..()+"([pipe_networks.len])"
|
||||
@@ -111,7 +111,6 @@
|
||||
return 0
|
||||
|
||||
//Grab candidates randomly until we have enough.
|
||||
candidates = shuffle(candidates)
|
||||
while(candidates.len && pending_antagonists.len < cur_max)
|
||||
var/datum/mind/player = pick(candidates)
|
||||
candidates -= player
|
||||
@@ -121,11 +120,18 @@
|
||||
|
||||
/datum/antagonist/proc/draft_antagonist(var/datum/mind/player)
|
||||
//Check if the player can join in this antag role, or if the player has already been given an antag role.
|
||||
if(!can_become_antag(player) || player.special_role)
|
||||
if(!can_become_antag(player))
|
||||
log_debug("[player.key] was selected for [role_text] by lottery, but is not allowed to be that role.")
|
||||
return 0
|
||||
if(player.special_role)
|
||||
log_debug("[player.key] was selected for [role_text] by lottery, but they already have a special role.")
|
||||
return 0
|
||||
if(!(flags & ANTAG_OVERRIDE_JOB) && (!player.current || istype(player.current, /mob/new_player)))
|
||||
log_debug("[player.key] was selected for [role_text] by lottery, but they have not joined the game.")
|
||||
return 0
|
||||
|
||||
pending_antagonists |= player
|
||||
log_debug("[player.key] has been selected for [role_text] by lottery.")
|
||||
|
||||
//Ensure that antags with ANTAG_OVERRIDE_JOB do not occupy job slots.
|
||||
if(flags & ANTAG_OVERRIDE_JOB)
|
||||
|
||||
@@ -104,9 +104,9 @@ var/datum/antagonist/cultist/cult
|
||||
player.current.visible_message("<FONT size = 3>[player.current] looks like they just reverted to their old faith!</FONT>")
|
||||
|
||||
/datum/antagonist/cultist/add_antagonist(var/datum/mind/player)
|
||||
if(!..())
|
||||
return
|
||||
player << "You catch a glimpse of the Realm of Nar-Sie, the Geometer of Blood. You now see how flimsy the world is, you see that it should be open to the knowledge of That Which Waits. Assist your new compatriots in their dark dealings. Their goals are yours, and yours are theirs. You serve the Dark One above all else. Bring It back."
|
||||
. = ..()
|
||||
if(.)
|
||||
player << "You catch a glimpse of the Realm of Nar-Sie, the Geometer of Blood. You now see how flimsy the world is, you see that it should be open to the knowledge of That Which Waits. Assist your new compatriots in their dark dealings. Their goals are yours, and yours are theirs. You serve the Dark One above all else. Bring It back."
|
||||
|
||||
/datum/antagonist/cultist/can_become_antag(var/datum/mind/player)
|
||||
if(!..())
|
||||
|
||||
@@ -86,7 +86,7 @@
|
||||
department = "Security"
|
||||
department_flag = ENGSEC
|
||||
faction = "Station"
|
||||
total_positions = 2
|
||||
total_positions = 1
|
||||
spawn_positions = 2
|
||||
supervisors = "the head of security"
|
||||
selection_color = "#ffeeee"
|
||||
@@ -129,8 +129,8 @@
|
||||
department = "Security"
|
||||
department_flag = ENGSEC
|
||||
faction = "Station"
|
||||
total_positions = 3
|
||||
spawn_positions = 3
|
||||
total_positions = 4
|
||||
spawn_positions = 4
|
||||
supervisors = "the head of security"
|
||||
selection_color = "#ffeeee"
|
||||
access = list(access_security, access_eva, access_sec_doors, access_brig, access_court, access_maint_tunnels, access_morgue, access_external_airlocks)
|
||||
|
||||
@@ -20,10 +20,10 @@
|
||||
|
||||
/obj/machinery/cablelayer/attack_hand(mob/user as mob)
|
||||
if(!cable&&!on)
|
||||
user << "\The [src] don't work with no cable."
|
||||
user << "<span class='warning'>\The [src] doesn't have any cable loaded.</span>"
|
||||
return
|
||||
on=!on
|
||||
user.visible_message("\The [src] [!on?"dea":"a"]ctivated.", "[user] [!on?"dea":"a"]ctivated \the [src].")
|
||||
user.visible_message("\The [user] [!on?"dea":"a"]ctivates \the [src].", "You switch [src] [on? "on" : "off"]")
|
||||
return
|
||||
|
||||
/obj/machinery/cablelayer/attackby(var/obj/item/O as obj, var/mob/user as mob)
|
||||
@@ -31,26 +31,27 @@
|
||||
|
||||
var/result = load_cable(O)
|
||||
if(!result)
|
||||
user << "Reel is full."
|
||||
user << "<span class='warning'>\The [src]'s cable reel is full.</span>"
|
||||
else
|
||||
user << "[result] meters of cable successfully loaded."
|
||||
user << "You load [result] lengths of cable into [src]."
|
||||
return
|
||||
|
||||
if(istype(O, /obj/item/weapon/screwdriver))
|
||||
if(istype(O, /obj/item/weapon/wirecutters))
|
||||
if(cable && cable.amount)
|
||||
var/m = round(input(usr,"Please specify the length of cable to cut","Cut cable",min(cable.amount,30)) as num, 1)
|
||||
m = min(m, cable.amount)
|
||||
m = min(m, 30)
|
||||
if(m)
|
||||
playsound(loc, 'sound/items/Wirecutter.ogg', 50, 1)
|
||||
use_cable(m)
|
||||
var/obj/item/stack/cable_coil/CC = new (get_turf(src))
|
||||
CC.amount = m
|
||||
else
|
||||
usr << "There's no more cable on the reel."
|
||||
usr << "<span class='warning'>There's no more cable on the reel.</span>"
|
||||
|
||||
/obj/machinery/cablelayer/examine(mob/user)
|
||||
..()
|
||||
user << "\The [src] has [cable.amount] meter\s."
|
||||
user << "\The [src]'s cable reel has [cable.amount] length\s left."
|
||||
|
||||
/obj/machinery/cablelayer/proc/load_cable(var/obj/item/stack/cable_coil/CC)
|
||||
if(istype(CC) && CC.amount)
|
||||
@@ -70,12 +71,11 @@
|
||||
|
||||
/obj/machinery/cablelayer/proc/use_cable(amount)
|
||||
if(!cable || cable.amount<1)
|
||||
visible_message("Cable depleted, [src] deactivated.")
|
||||
visible_message("A red light flashes on \the [src].")
|
||||
return
|
||||
/* if(cable.amount < amount)
|
||||
visible_message("No enough cable to finish the task.")
|
||||
return*/
|
||||
cable.use(amount)
|
||||
if(deleted(cable))
|
||||
cable = null
|
||||
return 1
|
||||
|
||||
/obj/machinery/cablelayer/proc/reset()
|
||||
|
||||
@@ -254,6 +254,7 @@
|
||||
health = between(health, health + repairing.amount*DOOR_REPAIR_AMOUNT, maxhealth)
|
||||
update_icon()
|
||||
qdel(repairing)
|
||||
repairing = null
|
||||
return
|
||||
|
||||
if(repairing && istype(I, /obj/item/weapon/crowbar))
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
icon_state = "[initial(icon_state)]-on"
|
||||
set_light(brightness_on)
|
||||
else
|
||||
icon_state = initial(icon_state)
|
||||
icon_state = "[initial(icon_state)]"
|
||||
set_light(0)
|
||||
|
||||
/obj/item/device/flashlight/proc/update_brightness(var/mob/user = null)
|
||||
|
||||
@@ -33,12 +33,12 @@ obj/item/device/hailer/attack_self(mob/living/carbon/user as mob)
|
||||
|
||||
if(isnull(insults))
|
||||
playsound(get_turf(src), 'sound/voice/halt.ogg', 100, 1, vary = 0)
|
||||
user.show_message("<span class='warning'>[user]'s [name] rasps, \"[use_message]\"</span>",1)
|
||||
user.audible_message("<span class='warning'>[user]'s [name] rasps, \"[use_message]\"</span>", "<span class='warning'>\The [user] holds up \the [name].</span>")
|
||||
else
|
||||
if(insults > 0)
|
||||
playsound(get_turf(src), 'sound/voice/binsult.ogg', 100, 1, vary = 0)
|
||||
// Yes, it used to show the transcription of the sound clip. That was a) inaccurate b) immature as shit.
|
||||
user.show_message("<span class='warning'>[user]'s [name] gurgles something indecipherable and deeply offensive.</span>")
|
||||
user.audible_message("<span class='warning'>[user]'s [name] gurgles something indecipherable and deeply offensive.</span>", "<span class='warning'>\The [user] holds up \the [name].</span>")
|
||||
insults--
|
||||
else
|
||||
user << "<span class='danger'>*BZZZZZZZZT*</span>"
|
||||
|
||||
@@ -184,11 +184,9 @@
|
||||
if(!uses_charge)
|
||||
amount -= used
|
||||
if (amount <= 0)
|
||||
spawn(0) //delete the empty stack once the current context yields
|
||||
if (amount <= 0) //check again in case someone transferred stuff to us
|
||||
if(usr)
|
||||
usr.remove_from_mob(src)
|
||||
qdel(src)
|
||||
if(usr)
|
||||
usr.remove_from_mob(src)
|
||||
qdel(src) //should be safe to qdel immediately since if someone is still using this stack it will persist for a little while longer
|
||||
return 1
|
||||
else
|
||||
if(get_amount() < used)
|
||||
|
||||
@@ -215,6 +215,7 @@
|
||||
if(istype(W, /obj/item/weapon/grab))
|
||||
var/obj/item/weapon/grab/G = W
|
||||
src.MouseDrop_T(G.affecting, user) //act like they were dragged onto the closet
|
||||
return 0
|
||||
if(istype(W,/obj/item/tk_grab))
|
||||
return 0
|
||||
if(istype(W, /obj/item/weapon/weldingtool))
|
||||
@@ -262,11 +263,9 @@
|
||||
return
|
||||
if(user.restrained() || user.stat || user.weakened || user.stunned || user.paralysis)
|
||||
return
|
||||
if((!( istype(O, /atom/movable) ) || O.anchored || get_dist(user, src) > 1 || get_dist(user, O) > 1 || user.contents.Find(src)))
|
||||
if((!( istype(O, /atom/movable) ) || O.anchored || !Adjacent(user) || !Adjacent(O) || !user.Adjacent(O) || user.contents.Find(src)))
|
||||
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)) // are you in a container/closet/pod/etc?
|
||||
if(!isturf(user.loc)) // are you in a container/closet/pod/etc?
|
||||
return
|
||||
if(!src.opened)
|
||||
return
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
var/health = 200
|
||||
var/cover = 50 //how much cover the girder provides against projectiles.
|
||||
var/material/reinf_material
|
||||
var/reinforcing = 0
|
||||
|
||||
/obj/structure/girder/displaced
|
||||
icon_state = "displaced"
|
||||
@@ -48,6 +49,7 @@
|
||||
health = min(health,initial(health))
|
||||
state = 0
|
||||
icon_state = initial(icon_state)
|
||||
reinforcing = 0
|
||||
if(reinf_material)
|
||||
reinforce_girder()
|
||||
|
||||
@@ -78,13 +80,18 @@
|
||||
user << "<span class='notice'>You drill through the girder!</span>"
|
||||
dismantle()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/screwdriver) && state == 2)
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1)
|
||||
user << "<span class='notice'>Now unsecuring support struts...</span>"
|
||||
if(do_after(user,40))
|
||||
if(!src) return
|
||||
user << "<span class='notice'>You unsecured the support struts!</span>"
|
||||
state = 1
|
||||
else if(istype(W, /obj/item/weapon/screwdriver))
|
||||
if(state == 2)
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1)
|
||||
user << "<span class='notice'>Now unsecuring support struts...</span>"
|
||||
if(do_after(user,40))
|
||||
if(!src) return
|
||||
user << "<span class='notice'>You unsecured the support struts!</span>"
|
||||
state = 1
|
||||
else if(anchored && !reinf_material)
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1)
|
||||
reinforcing = !reinforcing
|
||||
user << "<span class='notice'>\The [src] can now be [reinforcing? "reinforced" : "constructed"]!</span>"
|
||||
|
||||
else if(istype(W, /obj/item/weapon/wirecutters) && state == 1)
|
||||
playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1)
|
||||
@@ -108,95 +115,82 @@
|
||||
cover = 25
|
||||
|
||||
else if(istype(W, /obj/item/stack/material))
|
||||
|
||||
var/obj/item/stack/S = W
|
||||
if(S.get_amount() < 2)
|
||||
return ..()
|
||||
|
||||
var/material/M = S.get_material()
|
||||
if(!istype(M))
|
||||
return ..()
|
||||
|
||||
var/wall_fake
|
||||
add_hiddenprint(usr)
|
||||
|
||||
if(M.integrity < 50)
|
||||
user << "<span class='notice'>This material is too soft for use in wall construction.</span>"
|
||||
return
|
||||
|
||||
user << "<span class='notice'>You begin adding the plating...</span>"
|
||||
|
||||
if(!do_after(user,40) || !S.use(2))
|
||||
return
|
||||
|
||||
if(anchored)
|
||||
user << "<span class='notice'>You added the plating!</span>"
|
||||
if(reinforcing && !reinf_material)
|
||||
if(!reinforce_with_material(W, user))
|
||||
return ..()
|
||||
else
|
||||
user << "<span class='notice'>You create a false wall! Push on it to open or close the passage.</span>"
|
||||
wall_fake = 1
|
||||
if(!construct_wall(W, user))
|
||||
return ..()
|
||||
|
||||
var/turf/Tsrc = get_turf(src)
|
||||
Tsrc.ChangeTurf(/turf/simulated/wall)
|
||||
var/turf/simulated/wall/T = get_turf(src)
|
||||
T.set_material(M, reinf_material)
|
||||
if(wall_fake)
|
||||
T.can_open = 1
|
||||
T.add_hiddenprint(usr)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
else if(istype(W, /obj/item/pipe))
|
||||
var/obj/item/pipe/P = W
|
||||
if (P.pipe_type in list(0, 1, 5)) //simple pipes, simple bends, and simple manifolds.
|
||||
user.drop_item()
|
||||
P.loc = src.loc
|
||||
user << "<span class='notice'>You fit the pipe into the [src]!</span>"
|
||||
else
|
||||
..()
|
||||
return ..()
|
||||
|
||||
/obj/structure/girder/proc/construct_wall(obj/item/stack/material/S, mob/user)
|
||||
if(S.get_amount() < 2)
|
||||
user << "<span class='notice'>There isn't enough material here to construct a wall.</span>"
|
||||
return 0
|
||||
|
||||
var/material/M = name_to_material[S.default_type]
|
||||
if(!istype(M))
|
||||
return 0
|
||||
|
||||
var/wall_fake
|
||||
add_hiddenprint(usr)
|
||||
|
||||
if(M.integrity < 50)
|
||||
user << "<span class='notice'>This material is too soft for use in wall construction.</span>"
|
||||
return 0
|
||||
|
||||
user << "<span class='notice'>You begin adding the plating...</span>"
|
||||
|
||||
if(!do_after(user,40) || !S.use(2))
|
||||
return 1 //once we've gotten this far don't call parent attackby()
|
||||
|
||||
if(anchored)
|
||||
user << "<span class='notice'>You added the plating!</span>"
|
||||
else
|
||||
user << "<span class='notice'>You create a false wall! Push on it to open or close the passage.</span>"
|
||||
wall_fake = 1
|
||||
|
||||
var/turf/Tsrc = get_turf(src)
|
||||
Tsrc.ChangeTurf(/turf/simulated/wall)
|
||||
var/turf/simulated/wall/T = get_turf(src)
|
||||
T.set_material(M, reinf_material)
|
||||
if(wall_fake)
|
||||
T.can_open = 1
|
||||
T.add_hiddenprint(usr)
|
||||
qdel(src)
|
||||
return 1
|
||||
|
||||
/obj/structure/girder/proc/reinforce_with_material(obj/item/stack/material/S, mob/user) //if the verb is removed this can be renamed.
|
||||
if(reinf_material)
|
||||
user << "<span class='notice'>\The [src] is already reinforced.</span>"
|
||||
return 0
|
||||
|
||||
if(S.get_amount() < 2)
|
||||
user << "<span class='notice'>There isn't enough material here to reinforce the girder.</span>"
|
||||
return 0
|
||||
|
||||
var/material/M = name_to_material[S.default_type]
|
||||
if(!istype(M) || M.integrity < 50)
|
||||
user << "You cannot reinforce \the [src] with that; it is too soft."
|
||||
return 0
|
||||
|
||||
user << "<span class='notice'>Now reinforcing...</span>"
|
||||
if (!do_after(user,40) || !S.use(2))
|
||||
return 1 //don't call parent attackby() past this point
|
||||
user << "<span class='notice'>You added reinforcement!</span>"
|
||||
|
||||
reinf_material = M
|
||||
reinforce_girder()
|
||||
return 1
|
||||
|
||||
/obj/structure/girder/proc/reinforce_girder()
|
||||
cover = reinf_material.hardness
|
||||
health = 500
|
||||
state = 2
|
||||
icon_state = "reinforced"
|
||||
|
||||
/obj/structure/girder/verb/reinforce_with_material()
|
||||
set name = "Reinforce girder"
|
||||
set desc = "Reinforce a girder with metal."
|
||||
set src in view(1)
|
||||
|
||||
var/mob/living/user = usr
|
||||
if(!istype(user) || !(user.l_hand || user.r_hand))
|
||||
return
|
||||
|
||||
if(reinf_material)
|
||||
user << "\The [src] is already reinforced."
|
||||
return
|
||||
|
||||
var/obj/item/stack/material/S = user.l_hand
|
||||
if(!istype(S))
|
||||
S = user.r_hand
|
||||
if(!istype(S))
|
||||
user << "You cannot plate \the [src] with that."
|
||||
return
|
||||
|
||||
if(S.get_amount() < 2)
|
||||
user << "There is not enough material here to reinforce the girder."
|
||||
return
|
||||
|
||||
var/material/M = S.get_material()
|
||||
if(!istype(M) || M.integrity < 50)
|
||||
user << "You cannot reinforce \the [src] with that; it is too soft."
|
||||
return
|
||||
|
||||
user << "<span class='notice'>Now reinforcing...</span>"
|
||||
if (!do_after(user,40) || !S.use(2))
|
||||
return
|
||||
user << "<span class='notice'>You added reinforcement!</span>"
|
||||
|
||||
reinf_material = M
|
||||
reinforce_girder()
|
||||
|
||||
reinforcing = 0
|
||||
|
||||
/obj/structure/girder/proc/dismantle()
|
||||
new /obj/item/stack/material/steel(get_turf(src))
|
||||
|
||||
@@ -53,8 +53,9 @@ client/verb/JoinResponseTeam()
|
||||
if(jobban_isbanned(usr, "Syndicate") || jobban_isbanned(usr, "Emergency Response Team") || jobban_isbanned(usr, "Security Officer"))
|
||||
usr << "<font color=red><b>You are jobbanned from the emergency reponse team!"
|
||||
return
|
||||
if(ert.current_antagonists.len > 5)
|
||||
if(ert.current_antagonists.len >= ert.max_antags)
|
||||
usr << "The emergency response team is already full!"
|
||||
return
|
||||
ert.create_default(usr)
|
||||
else
|
||||
usr << "You need to be an observer or new player to use this."
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
//Set species_restricted list
|
||||
switch(target_species)
|
||||
if("Human", "Skrell") //humanoid bodytypes
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph")
|
||||
else
|
||||
species_restricted = list(target_species)
|
||||
|
||||
@@ -72,9 +72,9 @@
|
||||
//Set species_restricted list
|
||||
switch(target_species)
|
||||
if("Skrell")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph")
|
||||
if("Human")
|
||||
species_restricted = list("exclude","Skrell","Unathi","Tajara","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Skrell","Unathi","Tajara","Diona","Vox", "Xenomorph")
|
||||
|
||||
else
|
||||
species_restricted = list(target_species)
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
usr << "Your module is not installed in a hardsuit."
|
||||
return
|
||||
|
||||
module.holder.ui_interact(usr)
|
||||
module.holder.ui_interact(usr, nano_state = contained_state)
|
||||
|
||||
/obj/item/rig_module/ai_container
|
||||
|
||||
@@ -46,9 +46,23 @@
|
||||
var/obj/item/ai_card // Reference to the MMI, posibrain, intellicard or pAI card previously holding the AI.
|
||||
var/obj/item/ai_verbs/verb_holder
|
||||
|
||||
/mob
|
||||
var/get_rig_stats = 0
|
||||
|
||||
/obj/item/rig_module/ai_container/process()
|
||||
if(integrated_ai && loc)
|
||||
integrated_ai.SetupStat(loc.get_rig())
|
||||
if(integrated_ai)
|
||||
var/obj/item/weapon/rig/rig = get_rig()
|
||||
if(rig && rig.ai_override_enabled)
|
||||
integrated_ai.get_rig_stats = 1
|
||||
else
|
||||
integrated_ai.get_rig_stats = 0
|
||||
|
||||
/mob/living/Stat()
|
||||
. = ..()
|
||||
if(. && get_rig_stats)
|
||||
var/obj/item/weapon/rig/rig = get_rig()
|
||||
if(rig)
|
||||
SetupStat(rig)
|
||||
|
||||
/obj/item/rig_module/ai_container/proc/update_verb_holder()
|
||||
if(!verb_holder)
|
||||
@@ -158,7 +172,10 @@
|
||||
if(integrated_ai)
|
||||
integrated_ai.ghostize()
|
||||
qdel(integrated_ai)
|
||||
if(ai_card) qdel(ai_card)
|
||||
integrated_ai = null
|
||||
if(ai_card)
|
||||
qdel(ai_card)
|
||||
ai_card = null
|
||||
else if(user)
|
||||
user.put_in_hands(ai_card)
|
||||
else
|
||||
@@ -168,7 +185,6 @@
|
||||
update_verb_holder()
|
||||
|
||||
/obj/item/rig_module/ai_container/proc/integrate_ai(var/obj/item/ai,var/mob/user)
|
||||
|
||||
if(!ai) return
|
||||
|
||||
// The ONLY THING all the different AI systems have in common is that they all store the mob inside an item.
|
||||
|
||||
@@ -227,21 +227,21 @@
|
||||
return 0
|
||||
|
||||
/mob/living/carbon/human/Stat()
|
||||
..()
|
||||
. = ..()
|
||||
|
||||
if(istype(back,/obj/item/weapon/rig))
|
||||
if(. && istype(back,/obj/item/weapon/rig))
|
||||
var/obj/item/weapon/rig/R = back
|
||||
SetupStat(R)
|
||||
|
||||
/mob/proc/SetupStat(var/obj/item/weapon/rig/R)
|
||||
if(src == usr && R && !R.canremove && R.installed_modules.len && statpanel("Hardsuit Modules"))
|
||||
if(R && !R.canremove && R.installed_modules.len && statpanel("Hardsuit Modules"))
|
||||
var/cell_status = R.cell ? "[R.cell.charge]/[R.cell.maxcharge]" : "ERROR"
|
||||
statpanel("Hardsuit Modules", "Suit charge", cell_status)
|
||||
stat("Suit charge", cell_status)
|
||||
for(var/obj/item/rig_module/module in R.installed_modules)
|
||||
{
|
||||
for(var/stat_rig_module/SRM in module.stat_modules)
|
||||
if(SRM.CanUse())
|
||||
statpanel("Hardsuit Modules",SRM.module.interface_name,SRM)
|
||||
stat(SRM.module.interface_name,SRM)
|
||||
}
|
||||
|
||||
/stat_rig_module
|
||||
|
||||
@@ -383,8 +383,7 @@
|
||||
cell.use(cost*10)
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/rig/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
|
||||
/obj/item/weapon/rig/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1, var/nano_state = inventory_state)
|
||||
if(!user)
|
||||
return
|
||||
|
||||
@@ -454,7 +453,7 @@
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, ((src.loc != user) ? ai_interface_path : interface_path), interface_title, 480, 550, data["ai"] ? contained_state : inventory_state)
|
||||
ui = new(user, src, ui_key, ((src.loc != user) ? ai_interface_path : interface_path), interface_title, 480, 550, state = nano_state)
|
||||
ui.set_initial_data(data)
|
||||
ui.open()
|
||||
ui.set_auto_update(1)
|
||||
@@ -766,6 +765,7 @@
|
||||
return 0
|
||||
wearer.Move(null,dir)*/
|
||||
|
||||
// This returns the rig if you are contained inside one, but not if you are wearing it
|
||||
/atom/proc/get_rig()
|
||||
if(loc)
|
||||
return loc.get_rig()
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
cold_protection = HEAD
|
||||
min_cold_protection_temperature = SPACE_HELMET_MIN_COLD_PROTECTION_TEMPERATURE
|
||||
siemens_coefficient = 0.9
|
||||
species_restricted = list("exclude","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Diona", "Xenomorph")
|
||||
|
||||
var/obj/machinery/camera/camera
|
||||
var/list/camera_networks
|
||||
@@ -63,7 +63,7 @@
|
||||
cold_protection = UPPER_TORSO | LOWER_TORSO | LEGS | FEET | ARMS | HANDS
|
||||
min_cold_protection_temperature = SPACE_SUIT_MIN_COLD_PROTECTION_TEMPERATURE
|
||||
siemens_coefficient = 0.9
|
||||
species_restricted = list("exclude","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Diona", "Xenomorph")
|
||||
|
||||
var/list/supporting_limbs //If not-null, automatically splints breaks. Checked when removing the suit.
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
item_state = "syndie_helm"
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 35, bio = 100, rad = 60)
|
||||
siemens_coefficient = 0.6
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Vox", "Xenomorph")
|
||||
camera_networks = list("NUKE")
|
||||
light_overlay = "helmet_light_green" //todo: species-specific light overlays
|
||||
|
||||
@@ -20,4 +20,4 @@
|
||||
armor = list(melee = 60, bullet = 50, laser = 30, energy = 15, bomb = 35, bio = 100, rad = 60)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/melee/energy/sword,/obj/item/weapon/handcuffs)
|
||||
siemens_coefficient = 0.6
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Vox", "Xenomorph")
|
||||
@@ -9,7 +9,7 @@
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
|
||||
//Species-specific stuff.
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Diona","Vox", "Xenomorph")
|
||||
sprite_sheets_refit = list(
|
||||
"Unathi" = 'icons/mob/species/unathi/helmet.dmi',
|
||||
"Tajara" = 'icons/mob/species/tajaran/helmet.dmi',
|
||||
@@ -34,7 +34,7 @@
|
||||
heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph")
|
||||
sprite_sheets_refit = list(
|
||||
"Unathi" = 'icons/mob/species/unathi/suit.dmi',
|
||||
"Tajara" = 'icons/mob/species/tajaran/suit.dmi',
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
cultnet.updateVisibility(src)
|
||||
|
||||
/datum/antagonist/add_antagonist(var/datum/mind/player)
|
||||
..()
|
||||
. = ..()
|
||||
if(src == cult)
|
||||
cultnet.updateVisibility(player.current, 0)
|
||||
|
||||
|
||||
@@ -293,7 +293,11 @@
|
||||
else
|
||||
wound_flavor_text["[temp.name]"] = "<span class='warning'>[t_He] has a robot [temp.name]. It has[temp.get_wounds_desc()]!</span>\n"
|
||||
else if(temp.wounds.len > 0 || temp.open)
|
||||
wound_flavor_text["[temp.name]"] = "<span class='warning'>[t_He] has [temp.get_wounds_desc()] on [t_his] [temp.name].</span><br>"
|
||||
if(temp.is_stump() && temp.parent_organ && organs_by_name[temp.parent_organ])
|
||||
var/obj/item/organ/external/parent = organs_by_name[temp.parent_organ]
|
||||
wound_flavor_text["[temp.name]"] = "<span class='warning'>[t_He] has [temp.get_wounds_desc()] on [t_his] [parent.name].</span><br>"
|
||||
else
|
||||
wound_flavor_text["[temp.name]"] = "<span class='warning'>[t_He] has [temp.get_wounds_desc()] on [t_his] [temp.name].</span><br>"
|
||||
if(temp.status & ORGAN_BLEEDING)
|
||||
is_bleeding["[temp.name]"] = "<span class='danger'>[capitalize(t_his)] [temp.name] is bleeding!</span><br>"
|
||||
else
|
||||
|
||||
@@ -32,7 +32,6 @@
|
||||
var/obj/item/organ/brain/sponge = internal_organs_by_name["brain"]
|
||||
if(sponge)
|
||||
sponge.take_damage(amount)
|
||||
sponge.damage = min(max(sponge.damage, 0),(maxHealth*2))
|
||||
brainloss = sponge.damage
|
||||
else
|
||||
brainloss = 200
|
||||
|
||||
@@ -370,7 +370,7 @@ var/list/ai_verbs_default = list(
|
||||
if(emergency_message_cooldown)
|
||||
usr << "<span class='warning'>Arrays recycling. Please stand by.</span>"
|
||||
return
|
||||
var/input = input(usr, "Please choose a message to transmit to Centcomm via quantum entanglement. Please be aware that this process is very expensive, and abuse will lead to... termination. Transmission does not guarantee a response. There is a 30 second delay before you may send another message, be clear, full and concise.", "To abort, send an empty message.", "")
|
||||
var/input = sanitize(input(usr, "Please choose a message to transmit to Centcomm via quantum entanglement. Please be aware that this process is very expensive, and abuse will lead to... termination. Transmission does not guarantee a response. There is a 30 second delay before you may send another message, be clear, full and concise.", "To abort, send an empty message.", ""))
|
||||
if(!input)
|
||||
return
|
||||
Centcomm_announce(input, usr)
|
||||
|
||||
@@ -87,6 +87,9 @@
|
||||
|
||||
/obj/item/weapon/gripper/no_use //Used when you want to hold and put items in other things, but not able to 'use' the item
|
||||
|
||||
/obj/item/weapon/gripper/no_use/attack_self(mob/user as mob)
|
||||
return
|
||||
|
||||
/obj/item/weapon/gripper/no_use/loader //This is used to disallow building with metal.
|
||||
name = "sheet loader"
|
||||
desc = "A specialized loading device, designed to pick up and insert sheets of materials inside machines."
|
||||
@@ -101,9 +104,6 @@
|
||||
return wrapped.attack_self(user)
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/gripper/no_use/attack_self(mob/user as mob)
|
||||
return
|
||||
|
||||
/obj/item/weapon/gripper/verb/drop_item()
|
||||
|
||||
set name = "Drop Item"
|
||||
@@ -130,6 +130,8 @@
|
||||
force_holder = wrapped.force
|
||||
wrapped.force = 0.0
|
||||
wrapped.attack(M,user)
|
||||
if(deleted(wrapped))
|
||||
wrapped = null
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
@@ -227,14 +227,15 @@ var/list/organ_cache = list()
|
||||
W.damage += damage
|
||||
W.time_inflicted = world.time
|
||||
|
||||
//Note: external organs have their own version of this proc
|
||||
/obj/item/organ/proc/take_damage(amount, var/silent=0)
|
||||
if(src.status & ORGAN_ROBOT)
|
||||
src.damage += (amount * 0.8)
|
||||
src.damage = between(0, src.damage + (amount * 0.8), max_damage)
|
||||
else
|
||||
src.damage += amount
|
||||
src.damage = between(0, src.damage + amount, max_damage)
|
||||
|
||||
//only show this if the organ is not robotic
|
||||
if(owner && parent_organ)
|
||||
if(owner && parent_organ && amount > 0)
|
||||
var/obj/item/organ/external/parent = owner.get_organ(parent_organ)
|
||||
if(parent && !silent)
|
||||
owner.custom_pain("Something inside your [parent.name] hurts a lot.", 1)
|
||||
|
||||
@@ -729,17 +729,13 @@
|
||||
|
||||
if (usr.stat != 0)
|
||||
return
|
||||
if (holdingitems && holdingitems.len == 0)
|
||||
if (!holdingitems || holdingitems.len == 0)
|
||||
return
|
||||
|
||||
for(var/obj/item/O in holdingitems)
|
||||
O.loc = src.loc
|
||||
holdingitems -= O
|
||||
holdingitems = list()
|
||||
|
||||
/obj/machinery/reagentgrinder/proc/remove_object(var/obj/item/O)
|
||||
holdingitems -= O
|
||||
qdel(O)
|
||||
holdingitems.Cut()
|
||||
|
||||
/obj/machinery/reagentgrinder/proc/grind()
|
||||
|
||||
@@ -762,10 +758,6 @@
|
||||
// Process.
|
||||
for (var/obj/item/O in holdingitems)
|
||||
|
||||
if(!O || !istype(O))
|
||||
holdingitems -= null
|
||||
continue
|
||||
|
||||
var/remaining_volume = beaker.reagents.maximum_volume - beaker.reagents.total_volume
|
||||
if(remaining_volume <= 0)
|
||||
break
|
||||
@@ -776,13 +768,16 @@
|
||||
var/amount_to_take = max(0,min(stack.amount,round(remaining_volume/REAGENTS_PER_SHEET)))
|
||||
if(amount_to_take)
|
||||
stack.use(amount_to_take)
|
||||
if(deleted(stack))
|
||||
holdingitems -= stack
|
||||
beaker.reagents.add_reagent(sheet_reagents[stack.type], (amount_to_take*REAGENTS_PER_SHEET))
|
||||
continue
|
||||
|
||||
if(O.reagents)
|
||||
O.reagents.trans_to(beaker, min(O.reagents.total_volume, remaining_volume))
|
||||
if(O.reagents.total_volume == 0)
|
||||
remove_object(O)
|
||||
holdingitems -= O
|
||||
qdel(O)
|
||||
if (beaker.reagents.total_volume >= beaker.reagents.maximum_volume)
|
||||
break
|
||||
|
||||
|
||||
Reference in New Issue
Block a user