Merge branch 'BEF-staging' of github.com:Baystation12/Baystation12 into BEF-staging

Conflicts:
	config/config.txt
This commit is contained in:
Mloc-Argent
2013-07-05 19:55:01 +01:00
32 changed files with 693 additions and 557 deletions
+4 -1
View File
@@ -141,7 +141,10 @@
//Sets the temperature the built-in heater/cooler tries to maintain.
if(env == "temperature")
current.target_temperature = (selected[2] + selected[3])/2
if(current.target_temperature < selected[2])
current.target_temperature = selected[2]
if(current.target_temperature > selected[3])
current.target_temperature = selected[3]
spawn(1)
updateUsrDialog()
+14 -4
View File
@@ -75,21 +75,31 @@ connection
var/list/connections = air_master.turfs_with_connections[ref_A]
connections.Remove(src)
//Ensure we delete the right values by sanity checkign right before deletion.
Sanitize()
//Remove connection from current zones.
//Remove connection from zones.
if(A)
if(A.zone && A.zone.connections)
A.zone.connections.Remove(src)
if(!A.zone.connections.len)
A.zone.connections = null
if(istype(zone_A) && (!A || A.zone != zone_A))
if(zone_A.connections)
zone_A.connections.Remove(src)
if(!zone_A.connections.len)
zone_A.connections = null
if(B)
if(B.zone && B.zone.connections)
B.zone.connections.Remove(src)
if(!B.zone.connections.len)
B.zone.connections = null
if(istype(zone_B) && (!B || B.zone != zone_B))
if(zone_B.connections)
zone_B.connections.Remove(src)
if(!zone_B.connections.len)
zone_B.connections = null
//Disconnect zones while handling unusual conditions.
// e.g. loss of a zone on a turf
if(A && A.zone && B && B.zone)
+51 -50
View File
@@ -11,6 +11,8 @@ Attach to transfer valve and open. BOOM.
*/
//Some legacy definitions so fires can be started.
atom/proc/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
return null
@@ -19,12 +21,21 @@ atom/proc/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed
turf/proc/hotspot_expose(exposed_temperature, exposed_volume, soh = 0)
turf/simulated/hotspot_expose(exposed_temperature, exposed_volume, soh)
if(fire_protection > world.time-300) return
var/datum/gas_mixture/air_contents = return_air()
if(!air_contents || exposed_temperature < PLASMA_MINIMUM_BURN_TEMPERATURE)
var/datum/gas_mixture/air_contents = return_air(1)
if(!air_contents)
return 0
/*if(active_hotspot)
if(soh)
if(air_contents.toxins > 0.5 && air_contents.oxygen > 0.5)
if(active_hotspot.temperature < exposed_temperature)
active_hotspot.temperature = exposed_temperature
if(active_hotspot.volume < exposed_volume)
active_hotspot.volume = exposed_volume
return 1*/
var/igniting = 0
if(locate(/obj/fire) in src)
return 1
@@ -36,8 +47,9 @@ turf/simulated/hotspot_expose(exposed_temperature, exposed_volume, soh)
return 0
if(! (locate(/obj/fire) in src))
new /obj/fire(src,1000)
var/obj/fire/F = new(src,1000)
F.temperature = exposed_temperature
F.volume = CELL_VOLUME
//active_hotspot.just_spawned = (current_cycle < air_master.current_cycle)
//remove just_spawned protection if no longer processing this cell
@@ -59,7 +71,10 @@ obj
layer = TURF_LAYER
var
volume = CELL_VOLUME
temperature = FIRE_MINIMUM_TEMPERATURE_TO_EXIST
firelevel = 10000 //Calculated by gas_mixture.calculate_firelevel()
archived_firelevel = 0
process()
. = 1
@@ -77,7 +92,7 @@ obj
//Also get liquid fuels on the ground.
obj/effect/decal/cleanable/liquid_fuel/liquid = locate() in S
var/datum/gas_mixture/flow = air_contents.remove_ratio(vsc.fire_consuption_rate)
var/datum/gas_mixture/flow = air_contents.remove_ratio(0.25)
//The reason we're taking a part of the air instead of all of it is so that it doesn't jump to
//the fire's max temperature instantaneously.
@@ -111,13 +126,10 @@ obj
//Change icon depending on the fuel, and thus temperature.
if(firelevel > 6)
icon_state = "3"
SetLuminosity(7)
else if(firelevel > 2.5)
icon_state = "2"
SetLuminosity(5)
else
icon_state = "1"
SetLuminosity(3)
//Ensure flow temperature is higher than minimum fire temperatures.
flow.temperature = max(PLASMA_MINIMUM_BURN_TEMPERATURE+0.1,flow.temperature)
@@ -125,7 +137,7 @@ obj
//Burn the gas mixture.
flow.zburn(liquid)
if(fuel && fuel.moles <= 0.00001)
air_contents.trace_gases.Remove(fuel)
del fuel
else
@@ -143,7 +155,7 @@ obj
for(var/mob/living/carbon/human/M in loc)
M.FireBurn(firelevel) //Burn the humans!
M.FireBurn(temperature, min(max(0.1,firelevel / 20),10)) //Burn the humans!
New(newLoc,fl)
@@ -153,14 +165,13 @@ obj
del src
dir = pick(cardinal)
SetLuminosity(3)
//sd_SetLuminosity(3,2,0)
firelevel = fl
air_master.active_hotspots.Add(src)
Del()
if (istype(loc, /turf/simulated))
SetLuminosity(0)
//sd_SetLuminosity(0)
loc = null
air_master.active_hotspots.Remove(src)
@@ -168,34 +179,36 @@ obj
..()
turf/simulated/var/fire_protection = 0 //Protects newly extinguished tiles from being overrun again.
turf/proc/apply_fire_protection()
turf/simulated/apply_fire_protection()
fire_protection = world.time
datum/gas_mixture/proc/zburn(obj/effect/decal/cleanable/liquid_fuel/liquid)
//This proc is similar to fire(), but uses a simple logarithm to calculate temp, and is thus more stable with ZAS.
if(temperature > PLASMA_MINIMUM_BURN_TEMPERATURE)
var
total_fuel = toxins
fuel_sources = 0 //We'll divide by this later so that fuel is consumed evenly.
datum/gas/volatile_fuel/fuel = locate() in trace_gases
if(fuel)
//Volatile Fuel
total_fuel += fuel.moles
fuel_sources++
if(liquid)
//Liquid Fuel
if(liquid.amount <= 0)
del liquid
else
total_fuel += liquid.amount*15
total_fuel += liquid.amount
fuel_sources++
if(! (fuel || toxins || liquid) )
return 0 //If there's no fuel, there's no burn. Can't divide by zero anyway.
//Toxins
if(toxins > 0.3) fuel_sources++
if(!fuel_sources) return 0 //If there's no fuel, there's no burn. Can't divide by zero anyway.
if(oxygen > 0.3)
@@ -205,54 +218,46 @@ datum/gas_mixture/proc/zburn(obj/effect/decal/cleanable/liquid_fuel/liquid)
//Reaches a maximum practical temperature of around 4500.
//Increase temperature.
temperature = max( vsc.fire_temperature_multiplier*log(0.04*firelevel + 1.24) , temperature )
var/total_reactants = min(oxygen, 2*total_fuel) + total_fuel
temperature = max( 1700*log(0.4*firelevel + 1.23) , temperature )
//Consume some gas.
var/consumed_gas = max( min( total_reactants, vsc.fire_gas_combustion_ratio*firelevel ), 0.2)
var/consumed_gas = min(oxygen,0.05*firelevel,total_fuel) / fuel_sources
oxygen -= min(oxygen, (total_reactants-total_fuel)*consumed_gas/total_reactants )
oxygen = max(0,oxygen-consumed_gas)
toxins -= min(toxins, toxins*consumed_gas/total_reactants )
toxins = max(0,toxins-consumed_gas)
carbon_dioxide += max(consumed_gas, 0)
carbon_dioxide += consumed_gas*2
if(fuel)
fuel.moles -= fuel.moles*consumed_gas/total_reactants
fuel.moles -= consumed_gas
if(fuel.moles <= 0) del fuel
if(liquid)
liquid.amount -= liquid.amount*consumed_gas/(total_reactants)
liquid.amount -= consumed_gas
if(liquid.amount <= 0) del liquid
update_values()
return consumed_gas
return consumed_gas*fuel_sources
return 0
datum/gas_mixture/proc/calculate_firelevel(obj/effect/decal/cleanable/liquid_fuel/liquid)
//Calculates the firelevel based on one equation instead of having to do this multiple times in different areas.
var
datum/gas/volatile_fuel/fuel = locate() in trace_gases
liquid_concentration = 0
var/total_fuel = toxins - 0.5
oxy_concentration = oxygen / volume
tox_concentration = toxins / volume
fuel_concentration = 0
if(liquid)
total_fuel += (liquid.amount*15)
if(fuel) fuel_concentration = (fuel.moles) / volume
if(liquid) liquid_concentration = (liquid.amount*15) / volume
return (oxy_concentration + tox_concentration + liquid_concentration + fuel_concentration)*100
if(fuel)
total_fuel += fuel.moles
var/total_combustables = (total_fuel + oxygen)
if(total_fuel <= 0 || oxygen <= 0)
return 0
return max( 0, vsc.fire_firelevel_multiplier*(total_combustables/(total_combustables + nitrogen))*log(2*total_combustables/oxygen)*log(total_combustables/total_fuel))
/mob/living/carbon/human/proc/FireBurn(var/firelevel)
/mob/living/carbon/human/proc/FireBurn(last_temperature, mx as num)
//Burns mobs due to fire. Respects heat transfer coefficients on various body parts.
//Due to TG reworking how fireprotection works, this is kinda less meaningful.
var
head_exposure = 1
@@ -261,11 +266,8 @@ datum/gas_mixture/proc/calculate_firelevel(obj/effect/decal/cleanable/liquid_fue
legs_exposure = 1
arms_exposure = 1
var/mx = min(max(0.1,firelevel / 20),10)
var/last_temperature = vsc.fire_temperature_multiplier*log(0.04*firelevel + 1.24)
//Get heat transfer coefficients for clothing.
//skytodo: kill anyone who breaks things then orders me to fix them
for(var/obj/item/clothing/C in src)
if(l_hand == C || r_hand == C)
continue
@@ -292,5 +294,4 @@ datum/gas_mixture/proc/calculate_firelevel(obj/effect/decal/cleanable/liquid_fue
apply_damage(0.4*mx*arms_exposure, BURN, "l_arm", 0, 0, "Fire")
apply_damage(0.4*mx*arms_exposure, BURN, "r_arm", 0, 0, "Fire")
//flash_pain()
#undef ZAS_FIRE_CONSUMPTION_RATE
//flash_pain()
+1 -1
View File
@@ -385,7 +385,7 @@ proc/ShareSpace(datum/gas_mixture/A, list/unsimulated_tiles, dbg_output)
// slowly than small rooms, preserving our good old "hollywood-style"
// oh-shit effect when large rooms get breached, but still having small
// rooms remain pressurized for long enough to make escape possible.
share_size = max(1, max(size - 5, 1) + unsimulated_tiles.len)
share_size = max(1, max(size + 3, 1) + unsimulated_tiles.len)
correction_ratio = share_size / unsimulated_tiles.len
for(var/turf/T in unsimulated_tiles)
+1 -11
View File
@@ -80,17 +80,7 @@
var/name = t.fields["name"]
var/rank = t.fields["rank"]
var/real_rank = t.fields["real_rank"]
var/active = 0
for(var/mob/M in player_list) if(M.name == name)
// For dead ones, have a chance to get their status wrong
if(M.stat == 2)
active = M.x % 2 // Should be good enough, avoids their status flipping constantly
break
else if(M.client && M.client.inactivity <= 10 * 60 * 10)
active = 1
break
isactive[name] = active ? "Active" : "SSD"
isactive[name] = t.fields["p_stat"]
//world << "[name]: [rank]"
+126 -43
View File
@@ -48,7 +48,10 @@
#define RCON_YES 3
//1000 joules equates to about 1 degree every 2 seconds for a single tile of air.
#define MAX_ENERGY_CHANGE 2000
#define MAX_ENERGY_CHANGE 1000
#define MAX_TEMPERATURE 90
#define MIN_TEMPERATURE -40
//all air alarms in area are connected via magic
/area
@@ -85,6 +88,7 @@
var/area_uid
var/area/alarm_area
var/danger_level = 0
var/buildstage = 2 //2 is built, 1 is building, 0 is frame.
var/target_temperature = T0C+20
var/regulating_temperature = 0
@@ -104,8 +108,26 @@
TLV["temperature"] = list(20, 40, 140, 160) // K
target_temperature = 90
New()
New(var/loc, var/dir, var/building = 0)
..()
if(building)
if(loc)
src.loc = loc
if(dir)
src.dir = dir
buildstage = 0
wiresexposed = 1
pixel_x = (dir & 3)? 0 : (dir == 4 ? -24 : 24)
pixel_y = (dir & 3)? (dir ==1 ? -24 : 24) : 0
update_icon()
return
first_run()
proc/first_run()
alarm_area = get_area(src)
if (alarm_area.master)
alarm_area = alarm_area.master
@@ -128,7 +150,7 @@
process()
if((stat & (NOPOWER|BROKEN)) || shorted)
if((stat & (NOPOWER|BROKEN)) || shorted || buildstage != 2)
return
var/turf/simulated/location = loc
@@ -137,18 +159,21 @@
var/datum/gas_mixture/environment = location.return_air()
//Handle temperature adjustment here.
if(environment.temperature < target_temperature - 10 || environment.temperature > target_temperature + 10 || regulating_temperature)
if(environment.temperature < target_temperature - 2 || environment.temperature > target_temperature + 2 || regulating_temperature)
//If it goes too far, we should adjust ourselves back before stopping.
if(get_danger_level(target_temperature, TLV["temperature"]))
return
if(!regulating_temperature)
regulating_temperature = 1
visible_message("\The [src] clicks as it starts [environment.temperature > target_temperature ? "cooling" : "heating"] the room.",\
"You hear a click and a faint electronic hum.")
if(target_temperature > T0C + 90)
target_temperature = T0C + 90
if(target_temperature > T0C + MAX_TEMPERATURE)
target_temperature = T0C + MAX_TEMPERATURE
if(target_temperature < T0C - 40)
target_temperature = T0C - 40
if(target_temperature < T0C + MIN_TEMPERATURE)
target_temperature = T0C + MIN_TEMPERATURE
var/datum/gas_mixture/gas = location.remove_air(0.25*environment.total_moles)
var/heat_capacity = gas.heat_capacity()
@@ -480,6 +505,14 @@
var/wireFlag = AAlarmIndexToFlag[wireIndex]
return ((AAlarmwires & wireFlag) == 0)
proc/allWiresCut()
var/i = 1
while(i<=5)
if(AAlarmwires & AAlarmIndexToFlag[i])
return 0
i++
return 1
proc/cut(var/wireColor)
var/wireFlag = AAlarmWireColorToFlag[wireColor]
var/wireIndex = AAlarmWireColorToIndex[wireColor]
@@ -603,6 +636,9 @@
interact(mob/user)
user.set_machine(src)
if(buildstage!=2)
return
if ( (get_dist(src, user) > 1 ))
if (!istype(user, /mob/living/silicon))
user.machine = null
@@ -709,7 +745,7 @@ Toxins: <span class='dl[plasma_dangerlevel]'>[plasma_percent]</span>%<br>
else if (other_dangerlevel==1)
output += "Notice: <span class='dl1'>Low Concentration of Unknown Particles Detected</span><br>"
output += "Temperature: <span class='dl[temperature_dangerlevel]'>[environment.temperature]</span>K<br>"
output += "Temperature: <span class='dl[temperature_dangerlevel]'>[environment.temperature]</span>K ([round(environment.temperature - T0C, 0.1)]C)<br>"
//Overall status
output += "Local Status: "
@@ -727,7 +763,7 @@ Toxins: <span class='dl[plasma_dangerlevel]'>[plasma_percent]</span>%<br>
return output
proc/rcon_text()
var/dat = "<b>Remote Control:</b><br>"
var/dat = "<table width=\"100%\"><td align=\"center\"><b>Remote Control:</b><br>"
if(rcon_setting == RCON_NO)
dat += "<b>Off</b>"
else
@@ -741,7 +777,11 @@ Toxins: <span class='dl[plasma_dangerlevel]'>[plasma_percent]</span>%<br>
if(rcon_setting == RCON_YES)
dat += "<b>On</b>"
else
dat += "<a href='?src=\ref[src];rcon=[RCON_YES]'>On</a>"
dat += "<a href='?src=\ref[src];rcon=[RCON_YES]'>On</a></td>"
//Hackish, I know. I didn't feel like bothering to rework all of this.
dat += "<td align=\"center\"><b>Thermostat:</b><br><a href='?src=\ref[src];temperature=1'>[target_temperature - T0C]C</a></td></table>"
return dat
proc/return_controls()
@@ -985,10 +1025,6 @@ table tr:first-child th:first-child { border: none;}
if(selected[3] > selected[4])
selected[3] = selected[4]
//Sets the temperature the built-in heater/cooler tries to maintain.
if(env == "temperature")
target_temperature = (selected[2] + selected[3])/2
apply_mode()
if(href_list["screen"])
@@ -1015,6 +1051,16 @@ table tr:first-child th:first-child { border: none;}
mode = text2num(href_list["mode"])
apply_mode()
if(href_list["temperature"])
var/list/selected = TLV["temperature"]
var/max_temperature = min(selected[3] - T0C, MAX_TEMPERATURE)
var/min_temperature = max(selected[2] - T0C, MIN_TEMPERATURE)
var/input_temperature = input("What temperature would you like the system to mantain? (Capped between [min_temperature]C and [max_temperature]C)", "Thermostat Controls") as num|null
if(!input_temperature || input_temperature > max_temperature || input_temperature < min_temperature)
usr << "Temperature must be between [min_temperature]C and [max_temperature]C"
else
target_temperature = input_temperature + T0C
if (href_list["AAlarmwires"])
var/t1 = text2num(href_list["AAlarmwires"])
if (!( istype(usr.equipped(), /obj/item/weapon/wirecutters) ))
@@ -1048,28 +1094,74 @@ table tr:first-child th:first-child { border: none;}
update_icon()
return
*/
if(istype(W, /obj/item/weapon/screwdriver)) // Opening that Air Alarm up.
//user << "You pop the Air Alarm's maintence panel open."
wiresexposed = !wiresexposed
user << "The wires have been [wiresexposed ? "exposed" : "unexposed"]"
update_icon()
return
src.add_fingerprint(user)
if (wiresexposed && ((istype(W, /obj/item/device/multitool) || istype(W, /obj/item/weapon/wirecutters))))
return attack_hand(user)
switch(buildstage)
if(2)
if(istype(W, /obj/item/weapon/screwdriver)) // Opening that Air Alarm up.
//user << "You pop the Air Alarm's maintence panel open."
wiresexposed = !wiresexposed
user << "The wires have been [wiresexposed ? "exposed" : "unexposed"]"
update_icon()
return
if (wiresexposed && ((istype(W, /obj/item/device/multitool) || istype(W, /obj/item/weapon/wirecutters))))
return attack_hand(user)
if (istype(W, /obj/item/weapon/card/id) || istype(W, /obj/item/device/pda))// trying to unlock the interface with an ID card
if(stat & (NOPOWER|BROKEN))
user << "It does nothing"
return
else
if(allowed(usr) && !isWireCut(AALARM_WIRE_IDSCAN))
locked = !locked
user << "\blue You [ locked ? "lock" : "unlock"] the Air Alarm interface."
updateUsrDialog()
else
user << "\red Access denied."
return
if(1)
if(istype(W, /obj/item/weapon/cable_coil))
var/obj/item/weapon/cable_coil/coil = W
if(coil.amount < 5)
user << "You need more cable for this!"
return
user << "You wire \the [src]!"
coil.amount -= 5
if(!coil.amount)
del(coil)
buildstage = 2
update_icon()
first_run()
else if(istype(W, /obj/item/weapon/crowbar))
user << "You pry out the circuit!"
playsound(src.loc, 'sound/items/Crowbar.ogg', 50, 1)
spawn(20)
var/obj/item/weapon/airalarm_electronics/circuit = new /obj/item/weapon/airalarm_electronics()
circuit.loc = user.loc
buildstage = 0
update_icon()
return
if(0)
if(istype(W, /obj/item/weapon/airalarm_electronics))
user << "You insert the circuit!"
del(W)
buildstage = 1
update_icon()
/* Commented out due to RUNTIMES, RUNTIMES EVERYWHERE.
else if(istype(W, /obj/item/weapon/wrench))
user << "You remove the fire alarm assembly from the wall!"
var/obj/item/firealarm_frame/frame = new /obj/item/firealarm_frame()
frame.loc = user.loc
playsound(src.loc, 'sound/items/Ratchet.ogg', 50, 1)
del(src) */
return
else if (istype(W, /obj/item/weapon/card/id) || istype(W, /obj/item/device/pda))// trying to unlock the interface with an ID card
if(stat & (NOPOWER|BROKEN))
user << "It does nothing"
else
if(allowed(usr) && !isWireCut(AALARM_WIRE_IDSCAN))
locked = !locked
user << "\blue You [ locked ? "lock" : "unlock"] the Air Alarm interface."
updateUsrDialog()
else
user << "\red Access denied."
return
return ..()
/obj/machinery/alarm/power_change()
@@ -1218,15 +1310,6 @@ FIRE ALARM
user.visible_message("\red [user] has reconnected [src]'s detecting unit!", "You have reconnected [src]'s detecting unit.")
else
user.visible_message("\red [user] has disconnected [src]'s detecting unit!", "You have disconnected [src]'s detecting unit.")
else if (istype(W, /obj/item/weapon/wirecutters))
buildstage = 1
playsound(src.loc, 'sound/items/Wirecutter.ogg', 50, 1)
var/obj/item/weapon/cable_coil/coil = new /obj/item/weapon/cable_coil()
coil.amount = 5
coil.loc = user.loc
user << "You cut the wires from \the [src]"
update_icon()
if(1)
if(istype(W, /obj/item/weapon/cable_coil))
var/obj/item/weapon/cable_coil/coil = W
+10 -3
View File
@@ -145,12 +145,19 @@
src.active1 = null
src.active2 = null
else if (href_list["login"])
if (istype(usr, /mob/living/silicon))
if (istype(usr, /mob/living/silicon/ai))
src.active1 = null
src.active2 = null
src.authenticated = 1
src.authenticated = usr.name
src.rank = "AI"
src.screen = 1
else if (istype(usr, /mob/living/silicon/robot))
src.active1 = null
src.active2 = null
src.authenticated = usr.name
var/mob/living/silicon/robot/R = usr
src.rank = R.braintype
src.screen = 1
else if (istype(src.scan, /obj/item/weapon/card/id))
src.active1 = null
src.active2 = null
@@ -388,7 +395,7 @@
var/counter = 1
while(src.active2.fields[text("com_[]", counter)])
counter++
src.active2.fields[text("com_[]", counter)] = text("Made by [] ([]) on [], 2053<BR>[]", src.authenticated, src.rank, time2text(world.realtime, "DDD MMM DD hh:mm:ss"), t1)
src.active2.fields[text("com_[counter]")] = text("Made by [authenticated] ([rank]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], 2557<BR>[t1]")
if (href_list["del_c"])
if ((istype(src.active2, /datum/data/record) && src.active2.fields[text("com_[]", href_list["del_c"])]))
+14 -7
View File
@@ -245,12 +245,19 @@ What a mess.*/
active2 = null
if("Log In")
if (istype(usr, /mob/living/silicon))
active1 = null
active2 = null
authenticated = 1
rank = "AI"
screen = 1
if (istype(usr, /mob/living/silicon/ai))
src.active1 = null
src.active2 = null
src.authenticated = usr.name
src.rank = "AI"
src.screen = 1
else if (istype(usr, /mob/living/silicon/robot))
src.active1 = null
src.active2 = null
src.authenticated = usr.name
var/mob/living/silicon/robot/R = usr
src.rank = R.braintype
src.screen = 1
else if (istype(scan, /obj/item/weapon/card/id))
active1 = null
active2 = null
@@ -362,7 +369,7 @@ What a mess.*/
var/counter = 1
while(active2.fields[text("com_[]", counter)])
counter++
active2.fields[text("com_[]", counter)] = text("Made by [] ([]) on [], 2053<BR>[]", authenticated, rank, time2text(world.realtime, "DDD MMM DD hh:mm:ss"), t1)
active2.fields[text("com_[counter]")] = text("Made by [authenticated] ([rank]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], 2557<BR>[t1]")
if ("Delete Record (ALL)")
if (active1)
+12 -12
View File
@@ -23,7 +23,7 @@
"diamond"=0,
"plasma"=0,
"uranium"=0,
"bananium"=0
//"bananium"=0 No need to state what it can no longer hold
)
var/res_max_amount = 200000
var/datum/research/files
@@ -89,7 +89,7 @@
/obj/item/mecha_parts/part/durand_right_leg,
/obj/item/mecha_parts/part/durand_armour
),
"H.O.N.K"=list(
/*"H.O.N.K"=list(
/obj/item/mecha_parts/chassis/honker,
/obj/item/mecha_parts/part/honker_torso,
/obj/item/mecha_parts/part/honker_head,
@@ -97,7 +97,7 @@
/obj/item/mecha_parts/part/honker_right_arm,
/obj/item/mecha_parts/part/honker_left_leg,
/obj/item/mecha_parts/part/honker_right_leg
),
), No need for HONK stuff*/
"Exosuit Equipment"=list(
/obj/item/mecha_parts/mecha_equipment/tool/hydraulic_clamp,
/obj/item/mecha_parts/mecha_equipment/tool/drill,
@@ -111,9 +111,9 @@
///obj/item/mecha_parts/mecha_equipment/jetpack, //TODO MECHA JETPACK SPRITE MISSING
/obj/item/mecha_parts/mecha_equipment/weapon/energy/taser,
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/lmg,
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/mousetrap_mortar,
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/banana_mortar,
/obj/item/mecha_parts/mecha_equipment/weapon/honker
///obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/mousetrap_mortar, HONK-related mech part
///obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/banana_mortar, Also HONK-related
///obj/item/mecha_parts/mecha_equipment/weapon/honker Thirdly HONK-related
),
"Robotic Upgrade Modules" = list(
@@ -680,8 +680,8 @@
type = /obj/item/stack/sheet/mineral/plasma
if("uranium")
type = /obj/item/stack/sheet/mineral/uranium
if("bananium")
type = /obj/item/stack/sheet/mineral/clown
/*if("bananium")
type = /obj/item/stack/sheet/mineral/clown Sorry, but no more clown mechs, even if you do manage to get to the clown planet.*/
else
return 0
var/result = 0
@@ -739,9 +739,9 @@
if(src.resources["diamond"] >= 2000)
var/obj/item/stack/sheet/mineral/diamond/G = new /obj/item/stack/sheet/mineral/diamond(src.loc)
G.amount = round(src.resources["diamond"] / G.perunit)
if(src.resources["bananium"] >= 2000)
/*if(src.resources["bananium"] >= 2000)
var/obj/item/stack/sheet/mineral/clown/G = new /obj/item/stack/sheet/mineral/clown(src.loc)
G.amount = round(src.resources["bananium"] / G.perunit)
G.amount = round(src.resources["bananium"] / G.perunit) Sorry, but no bananium allowed*/
del(src)
return 1
else
@@ -765,8 +765,8 @@
material = "metal"
if(/obj/item/stack/sheet/glass)
material = "glass"
if(/obj/item/stack/sheet/mineral/clown)
material = "bananium"
/*if(/obj/item/stack/sheet/mineral/clown)
material = "bananium"*/
if(/obj/item/stack/sheet/mineral/uranium)
material = "uranium"
else
+9 -4
View File
@@ -349,13 +349,12 @@ var/global/list/obj/item/device/pda/PDAs = list()
dat += "<ul>"
dat += "<li><a href='byond://?src=\ref[src];choice=1'><img src=pda_notes.png> Notekeeper</a></li>"
dat += "<li><a href='byond://?src=\ref[src];choice=2'><img src=pda_mail.png> Messenger</a></li>"
dat += "<li><a href='byond://?src=\ref[src];choice=41'><img src=pda_notes.png> View Crew Manifest</a></li>"
//dat += "<li><a href='byond://?src=\red[src];choice=chatroom'><img src=pda_chatroom.png> Nanotrasen Relay Chat</a></li>"
if (cartridge)
if (cartridge.access_clown)
dat += "<li><a href='byond://?src=\ref[src];choice=Honk'><img src=pda_honk.png> Honk Synthesizer</a></li>"
if (cartridge.access_manifest)
dat += "<li><a href='byond://?src=\ref[src];choice=41'><img src=pda_notes.png> View Crew Manifest</a></li>"
if(cartridge.access_status_display)
dat += "<li><a href='byond://?src=\ref[src];choice=42'><img src=pda_status.png> Set Status Display</a></li>"
dat += "</ul>"
@@ -500,7 +499,12 @@ var/global/list/obj/item/device/pda/PDAs = list()
dat += " <img src=pda_locked.png>"
dat += "</li>"
if (41) //crew manifest
dat += "<h4><img src=pda_notes.png> Crew Manifest</h4>"
dat += "Entries cannot be modified from this terminal.<br><br>"
if(data_core)
dat += data_core.get_manifest(1) // make it monochrome
dat += "<br>"
else//Else it links to the cart menu proc. Although, it really uses menu hub 4--menu 4 doesn't really exist as it simply redirects to hub.
dat += cart
@@ -572,6 +576,8 @@ var/global/list/obj/item/device/pda/PDAs = list()
mode = 0
if("chatroom") // chatroom hub
mode = 5
if("41") //Manifest
mode = 41
//MAIN FUNCTIONS===================================
@@ -700,7 +706,6 @@ var/global/list/obj/item/device/pda/PDAs = list()
difficulty += P.cartridge.access_engine
difficulty += P.cartridge.access_clown
difficulty += P.cartridge.access_janitor
difficulty += P.cartridge.access_manifest * 2
else
difficulty += 2
@@ -11,7 +11,6 @@
var/access_engine = 0
var/access_atmos = 0
var/access_medical = 0
var/access_manifest = 1 // Make all jobs able to access the manifest
var/access_clown = 0
var/access_mime = 0
var/access_janitor = 0
@@ -68,7 +67,6 @@
icon_state = "cart-s"
access_security = 1
access_medical = 1
access_manifest = 1
janitor
@@ -132,13 +130,11 @@
head
name = "Easy-Record DELUXE"
icon_state = "cart-h"
access_manifest = 1
access_status_display = 1
hop
name = "HumanResources9001"
icon_state = "cart-h"
access_manifest = 1
access_status_display = 1
access_quartermaster = 1
access_janitor = 1
@@ -152,7 +148,6 @@
hos
name = "R.O.B.U.S.T. DELUXE"
icon_state = "cart-hos"
access_manifest = 1
access_status_display = 1
access_security = 1
@@ -164,7 +159,6 @@
ce
name = "Power-On DELUXE"
icon_state = "cart-ce"
access_manifest = 1
access_status_display = 1
access_engine = 1
access_atmos = 1
@@ -172,7 +166,6 @@
cmo
name = "Med-U DELUXE"
icon_state = "cart-cmo"
access_manifest = 1
access_status_display = 1
access_reagent_scanner = 1
access_medical = 1
@@ -180,7 +173,6 @@
rd
name = "Signal Ace DELUXE"
icon_state = "cart-rd"
access_manifest = 1
access_status_display = 1
access_reagent_scanner = 1
access_atmos = 1
@@ -194,7 +186,6 @@
name = "Value-PAK Cartridge"
desc = "Now with 200% more value!"
icon_state = "cart-c"
access_manifest = 1
access_engine = 1
access_security = 1
access_medical = 1
@@ -276,14 +267,6 @@ Code:
[radio:code]
<a href='byond://?src=\ref[src];choice=Signal Code;scode=1'>+</a>
<a href='byond://?src=\ref[src];choice=Signal Code;scode=5'>+</a><br>"}
if (41) //crew manifest
menu = "<h4><img src=pda_notes.png> Crew Manifest</h4>"
menu += "Entries cannot be modified from this terminal.<br><br>"
if(data_core)
menu += data_core.get_manifest(1) // make it monochrome
menu += "<br>"
if (42) //status displays
menu = "<h4><img src=pda_status.png> Station Status Display Interlink</h4>"
@@ -147,7 +147,7 @@
R.module.modules += new/obj/item/weapon/tank/jetpack/carbondioxide
for(var/obj/item/weapon/tank/jetpack/carbondioxide in R.module.modules)
R.internals = src
R.icon_state="Miner+j"
//R.icon_state="Miner+j"
return 1
+4 -4
View File
@@ -449,12 +449,12 @@
if(S.brute_dam)
S.heal_damage(15,0,0,1)
if(user != M)
user.visible_message("\red You patch some dents on \the [M]'s [S.display_name]",\
"\red \The [user] patches some dents on \the [M]'s [S.display_name] with \the [src]",\
user.visible_message("\red \The [user] patches some dents on \the [M]'s [S.display_name] with \the [src]",\
"\red You patch some dents on \the [M]'s [S.display_name]",\
"You hear a welder.")
else
user.visible_message("\red You patch some dents on your [S.display_name]",\
"\red \The [user] patches some dents on their [S.display_name] with \the [src]",\
user.visible_message("\red \The [user] patches some dents on their [S.display_name] with \the [src]",\
"\red You patch some dents on your [S.display_name]",\
"You hear a welder.")
else
user << "Nothing to fix!"
+1 -1
View File
@@ -5,7 +5,7 @@
temperature = TCMB
thermal_conductivity = OPEN_HEAT_TRANSFER_COEFFICIENT
heat_capacity = 700000
// heat_capacity = 700000 No.
/turf/space/New()
if(!istype(src, /turf/space/transit))
+4 -4
View File
@@ -462,7 +462,8 @@ client/proc/one_click_antag()
candidates.Remove(G)
if(candidates.len)
var/raiders = 4
var/max_raiders = 6
var/raiders = max_raiders
//Spawns vox raiders and equips them.
for (var/obj/effect/landmark/L in world)
if(L.name == "Response Team")
@@ -484,18 +485,17 @@ client/proc/one_click_antag()
new_vox << "\red Don't forget to turn on your nitrogen internals!"
raiders--
if(raiders > 4)
if(raiders > max_raiders)
return 0
else
return 0
return 1
/datum/admins/proc/create_vox_raider(obj/spawn_location, leader_chosen = 0)
var/mob/living/carbon/human/new_vox = new(spawn_location.loc)
new_vox.gender = pick(MALE, FEMALE)
var/datum/preferences/A = new() //Randomize appearance for the raider.
A.randomize_appearance_for(new_vox)
new_vox.h_style = "Short Vox Quills"
new_vox.regenerate_icons()
+11 -4
View File
@@ -1,3 +1,5 @@
var/global/vox_tick = 1
/mob/living/carbon/human/proc/equip_vox_raider()
var/obj/item/device/radio/R = new /obj/item/device/radio/headset/syndicate(src)
@@ -8,7 +10,7 @@
equip_to_slot_or_del(new /obj/item/clothing/shoes/magboots/vox(src), slot_shoes) // REPLACE THESE WITH CODED VOX ALTERNATIVES.
equip_to_slot_or_del(new /obj/item/clothing/gloves/yellow/vox(src), slot_gloves) // AS ABOVE.
switch(rand(1,4)) // Come up with a better way of doing this - ticker of some sort maybe.
switch(vox_tick)
if(1) // Vox raider!
equip_to_slot_or_del(new /obj/item/clothing/suit/space/vox/carapace(src), slot_wear_suit)
equip_to_slot_or_del(new /obj/item/clothing/head/helmet/space/vox/carapace(src), slot_head)
@@ -41,14 +43,16 @@
W.cell.charge = 500
equip_to_slot_or_del(W, slot_r_hand)
var/obj/item/stack/rods/A = new(src)
A.amount = 20
equip_to_slot_or_del(A, slot_l_hand)
if(4) // Vox medic!
equip_to_slot_or_del(new /obj/item/clothing/suit/space/vox/pressure(src), slot_wear_suit)
equip_to_slot_or_del(new /obj/item/clothing/head/helmet/space/vox/pressure(src), slot_head)
equip_to_slot_or_del(new /obj/item/weapon/storage/belt/utility/full(src), slot_belt) // Who needs actual surgical tools?
equip_to_slot_or_del(new /obj/item/clothing/glasses/hud/health(src), slot_glasses) // REPLACE WITH CODED VOX ALTERNATIVE.
equip_to_slot_or_del(new /obj/item/weapon/reagent_containers/hypospray(src), slot_l_store)
equip_to_slot_or_del(new /obj/item/weapon/circular_saw(src), slot_l_hand)
equip_to_slot_or_del(new /obj/item/weapon/circular_saw(src), slot_l_store)
equip_to_slot_or_del(new /obj/item/weapon/gun/dartgun/vox/medical, slot_r_hand)
equip_to_slot_or_del(new /obj/item/clothing/mask/breath/vox(src), slot_wear_mask)
@@ -63,4 +67,7 @@
W.registered_name = real_name
equip_to_slot_or_del(W, slot_wear_id)
vox_tick++
if (vox_tick > 4) vox_tick = 1
return 1
+60 -47
View File
@@ -387,60 +387,50 @@
msg += "[t_He] [t_is] repulsively uncanny!\n"
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
if(usr.stat || H != usr) //|| !usr.canmove || usr.restrained()) Fluff: Sechuds have eye-tracking technology and sets 'arrest' to people that the wearer looks and blinks at.
return //Non-fluff: This allows sec to set people to arrest as they get disarmed or beaten
if(hasHUD(usr,"security"))
var/perpname = "wot"
var/criminal = "None"
var/perpname = "wot"
var/criminal = "None"
if(wear_id)
var/obj/item/weapon/card/id/I = wear_id.GetID()
if(I)
perpname = I.registered_name
else
perpname = name
if(wear_id)
var/obj/item/weapon/card/id/I = wear_id.GetID()
if(I)
perpname = I.registered_name
else
perpname = name
else
perpname = name
if(perpname)
for (var/datum/data/record/E in data_core.general)
if(E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if(R.fields["id"] == E.fields["id"])
criminal = R.fields["criminal"]
msg += "<span class = 'deptradio'>Criminal status:</span> <a href='?src=\ref[src];criminal=1'>\[[criminal]\]</a>\n"
msg += "<span class = 'deptradio'>Security records:</span> <a href='?src=\ref[src];secrecord=`'>\[View\]</a> <a href='?src=\ref[src];secrecordadd=`'>\[Add comment\]</a>\n"
//msg += "\[Set Hostile Identification\]\n"
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
var/perpname = "wot"
var/medical = "None"
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
if(perpname)
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.general)
if (R.fields["id"] == E.fields["id"])
medical = R.fields["p_stat"]
if(E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if(R.fields["id"] == E.fields["id"])
criminal = R.fields["criminal"]
msg += "<span class = 'deptradio'>Criminal status:</span> <a href='?src=\ref[src];criminal=1'>\[[criminal]\]</a>\n"
msg += "<span class = 'deptradio'>Security records:</span> <a href='?src=\ref[src];secrecord=`'>\[View\]</a> <a href='?src=\ref[src];secrecordadd=`'>\[Add comment\]</a>\n"
msg += "<span class = 'deptradio'>Physical status:</span> <a href='?src=\ref[src];medical=1'>\[[medical]\]</a>\n"
msg += "<span class = 'deptradio'>Medical records:</span> <a href='?src=\ref[src];medrecord=`'>\[View\]</a> <a href='?src=\ref[src];medrecordadd=`'>\[Add comment\]</a>\n"
if(hasHUD(usr,"medical"))
var/perpname = "wot"
var/medical = "None"
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.general)
if (R.fields["id"] == E.fields["id"])
medical = R.fields["p_stat"]
msg += "<span class = 'deptradio'>Physical status:</span> <a href='?src=\ref[src];medical=1'>\[[medical]\]</a>\n"
msg += "<span class = 'deptradio'>Medical records:</span> <a href='?src=\ref[src];medrecord=`'>\[View\]</a> <a href='?src=\ref[src];medrecordadd=`'>\[Add comment\]</a>\n"
if(print_flavor_text()) msg += "[print_flavor_text()]\n"
@@ -452,3 +442,26 @@
msg += "\n[t_He] is [pose]"
usr << msg
//Helper procedure. Called by /mob/living/carbon/human/examine() and /mob/living/carbon/human/Topic() to determine HUD access to security and medical records.
/proc/hasHUD(mob/M as mob, hudtype)
if(istype(M, /mob/living/carbon/human))
var/mob/living/carbon/human/H = M
switch(hudtype)
if("security")
return istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud)
if("medical")
return istype(H.glasses, /obj/item/clothing/glasses/hud/health)
else
return 0
else if(istype(M, /mob/living/silicon/robot))
var/mob/living/silicon/robot/R = M
switch(hudtype)
if("security")
return istype(R.module_state_1, /obj/item/borg/sight/hud/sec) || istype(R.module_state_2, /obj/item/borg/sight/hud/sec) || istype(R.module_state_3, /obj/item/borg/sight/hud/sec)
if("medical")
return istype(R.module_state_1, /obj/item/borg/sight/hud/med) || istype(R.module_state_2, /obj/item/borg/sight/hud/med) || istype(R.module_state_3, /obj/item/borg/sight/hud/med)
else
return 0
else
return 0
+236 -244
View File
@@ -499,267 +499,258 @@
return
if (href_list["criminal"])
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
if(hasHUD(usr,"security"))
/* // Uncomment if you want sechuds to need security access
var/allowed_access = 0
if(H.wear_id)
var/list/access = H.wear_id.GetAccess()
if(access_security in access)
allowed_access = 1
return
if(!allowed_access)
H << "<span class='warning'>ERROR: Invalid Access</span>"
return
*/
var/modified = 0
var/perpname = "wot"
if(wear_id)
var/obj/item/weapon/card/id/I = wear_id.GetID()
if(I)
perpname = I.registered_name
else
perpname = name
var/modified = 0
var/perpname = "wot"
if(wear_id)
var/obj/item/weapon/card/id/I = wear_id.GetID()
if(I)
perpname = I.registered_name
else
perpname = name
else
perpname = name
if(perpname)
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if (R.fields["id"] == E.fields["id"])
var/setcriminal = input(usr, "Specify a new criminal status for this person.", "Security HUD", R.fields["criminal"]) in list("None", "*Arrest*", "Incarcerated", "Parolled", "Released", "Cancel")
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
if(setcriminal != "Cancel")
R.fields["criminal"] = setcriminal
modified = 1
spawn()
H.handle_regular_hud_updates()
if(!modified)
usr << "\red Unable to locate a data core entry for this person."
if (href_list["secrecord"])
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
var/perpname = "wot"
var/read = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
if(perpname)
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if (R.fields["id"] == E.fields["id"])
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
usr << "<b>Name:</b> [R.fields["name"]] <b>Criminal Status:</b> [R.fields["criminal"]]"
usr << "<b>Minor Crimes:</b> [R.fields["mi_crim"]]"
usr << "<b>Details:</b> [R.fields["mi_crim_d"]]"
usr << "<b>Major Crimes:</b> [R.fields["ma_crim"]]"
usr << "<b>Details:</b> [R.fields["ma_crim_d"]]"
usr << "<b>Notes:</b> [R.fields["notes"]]"
usr << "<a href='?src=\ref[src];secrecordComment=`'>\[View Comment Log\]</a>"
read = 1
if(!read)
usr << "\red Unable to locate a data core entry for this person."
var/setcriminal = input(usr, "Specify a new criminal status for this person.", "Security HUD", R.fields["criminal"]) in list("None", "*Arrest*", "Incarcerated", "Parolled", "Released", "Cancel")
if (href_list["secrecordComment"])
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
var/perpname = "wot"
var/read = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if (R.fields["id"] == E.fields["id"])
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
read = 1
var/counter = 1
while(R.fields[text("com_[]", counter)])
usr << text("[]", R.fields[text("com_[]", counter)])
counter++
if (counter == 1)
usr << "No comment found"
usr << "<a href='?src=\ref[src];secrecordadd=`'>\[Add comment\]</a>"
if(!read)
usr << "\red Unable to locate a data core entry for this person."
if (href_list["secrecordadd"])
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
var/perpname = "wot"
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if (R.fields["id"] == E.fields["id"])
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
var/t1 = copytext(sanitize(input("Add Comment:", "Sec. records", null, null) as message),1,MAX_MESSAGE_LEN)
if ((!( t1 ) || src.stat || src.restrained() || !(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))))
return
var/counter = 1
while(R.fields[text("com_[]", counter)])
counter++
R.fields[text("com_[]", counter)] = text("Made by [] ([]) on [], 2053<BR>[]",H.get_authentification_name(), H.get_assignment(), time2text(world.realtime, "DDD MMM DD hh:mm:ss"), t1)
if (href_list["medical"])
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
var/perpname = "wot"
var/modified = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.general)
if (R.fields["id"] == E.fields["id"])
var/setmedical = input(usr, "Specify a new medical status for this person.", "Medical HUD", R.fields["p_stat"]) in list("*Deceased*", "*Unconscious*", "Physically Unfit", "Active", "Cancel")
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
if(setmedical != "Cancel")
R.fields["p_stat"] = setmedical
if(hasHUD(usr, "security"))
if(setcriminal != "Cancel")
R.fields["criminal"] = setcriminal
modified = 1
spawn()
H.handle_regular_hud_updates()
if(istype(usr,/mob/living/carbon/human))
var/mob/living/carbon/human/U = usr
U.handle_regular_hud_updates()
if(istype(usr,/mob/living/silicon/robot))
var/mob/living/silicon/robot/U = usr
U.handle_regular_hud_updates()
if(!modified)
usr << "\red Unable to locate a data core entry for this person."
if(!modified)
usr << "\red Unable to locate a data core entry for this person."
if (href_list["secrecord"])
if(hasHUD(usr,"security"))
var/perpname = "wot"
var/read = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if (R.fields["id"] == E.fields["id"])
if(hasHUD(usr,"security"))
usr << "<b>Name:</b> [R.fields["name"]] <b>Criminal Status:</b> [R.fields["criminal"]]"
usr << "<b>Minor Crimes:</b> [R.fields["mi_crim"]]"
usr << "<b>Details:</b> [R.fields["mi_crim_d"]]"
usr << "<b>Major Crimes:</b> [R.fields["ma_crim"]]"
usr << "<b>Details:</b> [R.fields["ma_crim_d"]]"
usr << "<b>Notes:</b> [R.fields["notes"]]"
usr << "<a href='?src=\ref[src];secrecordComment=`'>\[View Comment Log\]</a>"
read = 1
if(!read)
usr << "\red Unable to locate a data core entry for this person."
if (href_list["secrecordComment"])
if(hasHUD(usr,"security"))
var/perpname = "wot"
var/read = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if (R.fields["id"] == E.fields["id"])
if(hasHUD(usr,"security"))
read = 1
var/counter = 1
while(R.fields[text("com_[]", counter)])
usr << text("[]", R.fields[text("com_[]", counter)])
counter++
if (counter == 1)
usr << "No comment found"
usr << "<a href='?src=\ref[src];secrecordadd=`'>\[Add comment\]</a>"
if(!read)
usr << "\red Unable to locate a data core entry for this person."
if (href_list["secrecordadd"])
if(hasHUD(usr,"security"))
var/perpname = "wot"
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if (R.fields["id"] == E.fields["id"])
if(hasHUD(usr,"security"))
var/t1 = copytext(sanitize(input("Add Comment:", "Sec. records", null, null) as message),1,MAX_MESSAGE_LEN)
if ( !(t1) || usr.stat || usr.restrained() || !(hasHUD(usr,"security")) )
return
var/counter = 1
while(R.fields[text("com_[]", counter)])
counter++
if(istype(usr,/mob/living/carbon/human))
var/mob/living/carbon/human/U = usr
R.fields[text("com_[counter]")] = text("Made by [U.get_authentification_name()] ([U.get_assignment()]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], 2557<BR>[t1]")
if(istype(usr,/mob/living/silicon/robot))
var/mob/living/silicon/robot/U = usr
R.fields[text("com_[counter]")] = text("Made by [U.name] ([U.braintype]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], 2557<BR>[t1]")
if (href_list["medical"])
if(hasHUD(usr,"medical"))
var/perpname = "wot"
var/modified = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.general)
if (R.fields["id"] == E.fields["id"])
var/setmedical = input(usr, "Specify a new medical status for this person.", "Medical HUD", R.fields["p_stat"]) in list("*Deceased*", "*Unconscious*", "Physically Unfit", "Active", "Cancel")
if(hasHUD(usr,"medical"))
if(setmedical != "Cancel")
R.fields["p_stat"] = setmedical
modified = 1
spawn()
if(istype(usr,/mob/living/carbon/human))
var/mob/living/carbon/human/U = usr
U.handle_regular_hud_updates()
if(istype(usr,/mob/living/silicon/robot))
var/mob/living/silicon/robot/U = usr
U.handle_regular_hud_updates()
if(!modified)
usr << "\red Unable to locate a data core entry for this person."
if (href_list["medrecord"])
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
var/perpname = "wot"
var/read = 0
if(hasHUD(usr,"medical"))
var/perpname = "wot"
var/read = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.medical)
if (R.fields["id"] == E.fields["id"])
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
usr << "<b>Name:</b> [R.fields["name"]] <b>Blood Type:</b> [R.fields["b_type"]]"
usr << "<b>DNA:</b> [R.fields["b_dna"]]"
usr << "<b>Minor Disabilities:</b> [R.fields["mi_dis"]]"
usr << "<b>Details:</b> [R.fields["mi_dis_d"]]"
usr << "<b>Major Disabilities:</b> [R.fields["ma_dis"]]"
usr << "<b>Details:</b> [R.fields["ma_dis_d"]]"
usr << "<b>Notes:</b> [R.fields["notes"]]"
usr << "<a href='?src=\ref[src];medrecordComment=`'>\[View Comment Log\]</a>"
read = 1
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.medical)
if (R.fields["id"] == E.fields["id"])
if(hasHUD(usr,"medical"))
usr << "<b>Name:</b> [R.fields["name"]] <b>Blood Type:</b> [R.fields["b_type"]]"
usr << "<b>DNA:</b> [R.fields["b_dna"]]"
usr << "<b>Minor Disabilities:</b> [R.fields["mi_dis"]]"
usr << "<b>Details:</b> [R.fields["mi_dis_d"]]"
usr << "<b>Major Disabilities:</b> [R.fields["ma_dis"]]"
usr << "<b>Details:</b> [R.fields["ma_dis_d"]]"
usr << "<b>Notes:</b> [R.fields["notes"]]"
usr << "<a href='?src=\ref[src];medrecordComment=`'>\[View Comment Log\]</a>"
read = 1
if(!read)
usr << "\red Unable to locate a data core entry for this person."
if(!read)
usr << "\red Unable to locate a data core entry for this person."
if (href_list["medrecordComment"])
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
var/perpname = "wot"
var/read = 0
if(hasHUD(usr,"medical"))
var/perpname = "wot"
var/read = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.medical)
if (R.fields["id"] == E.fields["id"])
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
read = 1
var/counter = 1
while(R.fields[text("com_[]", counter)])
usr << text("[]", R.fields[text("com_[]", counter)])
counter++
if (counter == 1)
usr << "No comment found"
usr << "<a href='?src=\ref[src];medrecordadd=`'>\[Add comment\]</a>"
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.medical)
if (R.fields["id"] == E.fields["id"])
if(hasHUD(usr,"medical"))
read = 1
var/counter = 1
while(R.fields[text("com_[]", counter)])
usr << text("[]", R.fields[text("com_[]", counter)])
counter++
if (counter == 1)
usr << "No comment found"
usr << "<a href='?src=\ref[src];medrecordadd=`'>\[Add comment\]</a>"
if(!read)
usr << "\red Unable to locate a data core entry for this person."
if(!read)
usr << "\red Unable to locate a data core entry for this person."
if (href_list["medrecordadd"])
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
var/perpname = "wot"
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.medical)
if (R.fields["id"] == E.fields["id"])
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health))
var/t1 = copytext(sanitize(input("Add Comment:", "Med. records", null, null) as message),1,MAX_MESSAGE_LEN)
if ((!( t1 ) || src.stat || src.restrained() || !(istype(H.glasses, /obj/item/clothing/glasses/hud/health))))
return
var/counter = 1
while(R.fields[text("com_[]", counter)])
counter++
R.fields[text("com_[]", counter)] = text("Made by [] ([]) on [], 2053<BR>[]",H.get_authentification_name(), H.get_assignment(), time2text(world.realtime, "DDD MMM DD hh:mm:ss"), t1)
if(hasHUD(usr,"medical"))
var/perpname = "wot"
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
else
perpname = src.name
for (var/datum/data/record/E in data_core.general)
if (E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.medical)
if (R.fields["id"] == E.fields["id"])
if(hasHUD(usr,"medical"))
var/t1 = copytext(sanitize(input("Add Comment:", "Med. records", null, null) as message),1,MAX_MESSAGE_LEN)
if ( !(t1) || usr.stat || usr.restrained() || !(hasHUD(usr,"medical")) )
return
var/counter = 1
while(R.fields[text("com_[]", counter)])
counter++
if(istype(usr,/mob/living/carbon/human))
var/mob/living/carbon/human/U = usr
R.fields[text("com_[counter]")] = text("Made by [U.get_authentification_name()] ([U.get_assignment()]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], 2557<BR>[t1]")
if(istype(usr,/mob/living/silicon/robot))
var/mob/living/silicon/robot/U = usr
R.fields[text("com_[counter]")] = text("Made by [U.name] ([U.braintype]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], 2557<BR>[t1]")
..()
return
@@ -1166,21 +1157,22 @@ mob/living/carbon/human/yank_out_object()
if(O == selection)
affected = organ
if(self)
src << "<span class='warning'>You attempt to get a good grip on the [selection] in your [affected] with bloody fingers.</span>"
src << "<span class='warning'>You attempt to get a good grip on the [selection] in your [affected.display_name] with bloody fingers.</span>"
else
U << "<span class='warning'>You attempt to get a good grip on the [selection] in [S]'s [affected] with bloody fingers.</span>"
U << "<span class='warning'>You attempt to get a good grip on the [selection] in [S]'s [affected.display_name] with bloody fingers.</span>"
if(istype(U,/mob/living/carbon/human/)) U.bloody_hands(S)
if(!do_after(U, 80))
return
if(!selection || !affected || !S || !U)
return
if(!selection || !affected || !S || !U)
return
if(self)
visible_message("<span class='warning'><b>[src] rips [selection] out of their [affected] in a welter of blood.</b></span>","<span class='warning'><b>You rip [selection] out of your [affected] in a welter of blood.</b></span>")
visible_message("<span class='warning'><b>[src] rips [selection] out of their [affected.display_name] in a welter of blood.</b></span>","<span class='warning'><b>You rip [selection] out of your [affected] in a welter of blood.</b></span>")
else
visible_message("<span class='warning'><b>[usr] rips [selection] out of [src]'s [affected] in a welter of blood.</b></span>","<span class='warning'><b>[src] rips [selection] out of your [affected] in a welter of blood.</b></span>")
visible_message("<span class='warning'><b>[usr] rips [selection] out of [src]'s [affected.display_name] in a welter of blood.</b></span>","<span class='warning'><b>[usr] rips [selection] out of your [affected] in a welter of blood.</b></span>")
selection.loc = get_turf(src)
affected.implants -= selection
@@ -1226,4 +1218,4 @@ mob/living/carbon/human/yank_out_object()
organ.status |= ORGAN_BLEEDING
organ.take_damage(rand(1,3), 0, 0)
src.adjustToxLoss(rand(1,3))
src.adjustToxLoss(rand(1,3))
+43 -51
View File
@@ -31,6 +31,8 @@ var/list/ai_list = list()
var/icon/holo_icon//Default is assigned when AI is created.
var/obj/item/device/pda/ai/aiPDA = null
var/obj/item/device/multitool/aiMulti = null
var/custom_sprite = 0 //For our custom sprites
//Hud stuff
//MALFUNCTION
var/datum/AI_Module/module_picker/malf_picker
@@ -125,55 +127,45 @@ var/list/ai_list = list()
set name = "Set AI Core Display"
if(stat || aiRestorePowerRoutine)
return
if(!custom_sprite) //Check to see if custom sprite time, checking the appopriate file to change a var
var/file = file2text("config/custom_sprites.txt")
var/lines = text2list(file, "\n")
for(var/line in lines)
// split & clean up
var/list/Entry = text2list(line, "-")
for(var/i = 1 to Entry.len)
Entry[i] = trim(Entry[i])
if(Entry.len < 2)
continue;
if(Entry[1] == src.ckey && Entry[2] == src.real_name)
custom_sprite = 1 //They're in the list? Custom sprite time
icon = 'icons/mob/custom-synthetic.dmi'
//if(icon_state == initial(icon_state))
var/icontype = ""
var/list/icons = list("Monochrome", "Blue", "Inverted", "Text", "Smiley", "Angry", "Dorf", "Matrix", "Bliss", "Firewall", "Green", "Red", "Static", "Triumvirate", "Triumvirate Static")
if (src.name == "M00X-BC" && src.ckey == "searif")
icons += "M00X-BC"
if (src.name == "Skuld" && src.ckey == "ravensdale")
icons += "Skuld"
if (src.name == "REMNANT" && src.ckey == "serithi")
icons += "REMNANT"
icontype = input("Please, select a display!", "AI", null/*, null*/) in icons
if(icontype == "Clown")
icon_state = "ai-clown2"
else if(icontype == "Monochrome")
icon_state = "ai-mono"
else if(icontype == "Blue")
icon_state = "ai"
else if(icontype == "Inverted")
icon_state = "ai-u"
else if(icontype == "Firewall")
icon_state = "ai-magma"
else if(icontype == "Green")
icon_state = "ai-wierd"
else if(icontype == "Red")
icon_state = "ai-malf"
else if(icontype == "Static")
icon_state = "ai-static"
else if(icontype == "Text")
icon_state = "ai-text"
else if(icontype == "Smiley")
icon_state = "ai-smiley"
else if(icontype == "Matrix")
icon_state = "ai-matrix"
else if(icontype == "Angry")
icon_state = "ai-angryface"
else if(icontype == "Dorf")
icon_state = "ai-dorf"
else if(icontype == "Bliss")
icon_state = "ai-bliss"
else if(icontype == "M00X-BC")
icon_state = "ai-searif"
else if(icontype == "Triumvirate")
icon_state = "ai-triumvirate"
else if(icontype == "Triumvirate Static")
icon_state = "ai-triumvirate-malf"
else if(icontype == "Skuld")
icon_state = "ai-ravensdale"
else if(icontype == "REMNANT")
icon_state = "ai-serithi"
if (custom_sprite == 1) icontype = ("Custom")//automagically selects custom sprite if one is available
else icontype = input("Select an icon!", "AI", null, null) in list("Monochrome", "Blue", "Inverted", "Text", "Smiley", "Angry", "Dorf", "Matrix", "Bliss", "Firewall", "Green", "Red", "Static", "Triumvirate", "Triumvirate Static")
switch(icontype)
if("Custom") icon_state = "[src.ckey]-ai"
if("Clown") icon_state = "ai-clown2"
if("Monochrome") icon_state = "ai-mono"
if("Inverted") icon_state = "ai-u"
if("Firewall") icon_state = "ai-magma"
if("Green") icon_state = "ai-wierd"
if("Red") icon_state = "ai-red"
if("Static") icon_state = "ai-static"
if("Text") icon_state = "ai-text"
if("Smiley") icon_state = "ai-smiley"
if("Matrix") icon_state = "ai-matrix"
if("Angry") icon_state = "ai-angryface"
if("Dorf") icon_state = "ai-dorf"
if("Bliss") icon_state = "ai-bliss"
if("Triumvirate") icon_state = "ai-triumvirate"
if("Triumvirate Static") icon_state = "ai-triumvirate-malf"
else icon_state = "ai"
//else
//usr <<"You can only change your display once!"
//return
@@ -188,7 +180,7 @@ var/list/ai_list = list()
if (malf.apcs >= 3)
stat(null, "Time until station control secured: [max(malf.AI_win_timeleft/(malf.apcs/3), 0)] seconds")
/mob/living/silicon/ai/proc/ai_alerts()
set category = "AI Commands"
set name = "Show Alerts"
@@ -337,10 +329,6 @@ var/list/ai_list = list()
else
src << "<span class='notice'>Unable to locate the holopad.</span>"
if(href_list["say_word"])
src.announcement(href_list["say_word"])
return
if (href_list["lawc"]) // Toggling whether or not a law gets stated by the State Laws verb --NeoFite
var/L = text2num(href_list["lawc"])
switch(lawcheck[L+1])
@@ -349,6 +337,10 @@ var/list/ai_list = list()
// src << text ("Switching Law [L]'s report status to []", lawcheck[L+1])
checklaws()
if(href_list["say_word"])
src.announcement(href_list["say_word"])
return
if (href_list["lawi"]) // Toggling whether or not a law gets stated by the State Laws verb --NeoFite
var/L = text2num(href_list["lawi"])
switch(ioncheck[L])
+2 -4
View File
@@ -1,10 +1,8 @@
/mob/living/silicon/ai/death(gibbed)
if(stat == DEAD) return
stat = DEAD
if (src.name == "Skuld" && src.ckey == "ravensdale")//checks ID of AI and player to see if it needs to pull the custom death sprite and goes to blue-screen if it doesn't
icon_state = "ai-ravensdale-crash"
else if (src.name == "REMNANT" && src.ckey == "serithi")
icon_state = "ai-serithi-crash"
if (src.custom_sprite == 1)//check for custom AI sprite, defaulting to blue screen if no.
icon_state = "[ckey]-ai-crash"
else icon_state = "ai-crash"
update_canmove()
if(src.eyeobj)
@@ -39,7 +39,7 @@
brute_damage += brute
electronics_damage += electronics
if(brute_damage + electronics_damage > max_damage) destroy()
if(brute_damage + electronics_damage >= max_damage) destroy()
/datum/robot_component/proc/heal_damage(brute, electronics)
if(installed != 1)
@@ -50,7 +50,7 @@
electronics_damage = max(0, electronics_damage - electronics)
/datum/robot_component/proc/is_powered()
return installed == 1 && (!energy_consumption || powered)
return (installed == 1) && (brute_damage + electronics_damage < max_damage) && (!energy_consumption || powered)
/datum/robot_component/proc/consume_power()
@@ -66,9 +66,7 @@
else
src.camera.status = 1
health = 200 - (getOxyLoss() + getFireLoss() + getBruteLoss())
if(getOxyLoss() > 50) Paralyse(3)
updatehealth()
if(src.sleeping)
Paralyse(3)
+34 -16
View File
@@ -10,6 +10,7 @@
var/sight_mode = 0
var/custom_name = ""
var/base_icon
var/custom_sprite = 0 //Due to all the sprites involved, a var for our custom borgs may be best
//Hud stuff
@@ -145,7 +146,7 @@
/mob/living/silicon/robot/proc/pick_module()
if(module)
return
var/list/modules = list("Standard", "Engineering", "Medical", "Miner", "Janitor","Service", "Security","Combat")
var/list/modules = list("Standard", "Engineering", "Medical", "Miner", "Janitor", "Service", "Security", "Combat")
if(emagged || security_level > SEC_LEVEL_BLUE)
src << "\red Crisis mode active. Combat module available."
modules+="Combat"
@@ -156,7 +157,7 @@
if(module)
return
switch(mod)
if("Standard")
module = new /obj/item/weapon/robot_module/standard(src)
@@ -177,10 +178,10 @@
if("Miner")
module = new /obj/item/weapon/robot_module/miner(src)
modtype = "Miner"
channels = list("Mining" = 1)
channels = list("Supply" = 1)
module_sprites["Basic"] = "Miner_old"
module_sprites["Advanced Droid"] = "droid-miner"
module_sprites["Default"] = "Miner"
module_sprites["Treadhead"] = "Miner"
if("Medical")
module = new /obj/item/weapon/robot_module/medical(src)
@@ -221,18 +222,10 @@
module_sprites["Combat Android"] = "droid-combat"
channels = list("Security" = 1)
//Begin awful custom item checks.
if (src.name == "Lucy" && src.ckey == "rowtree")
switch(mod)
if("Medical")
module_sprites["Lucy"] = "rowtree-medical"
if("Security" || "Combat")
module_sprites["Lucy"] = "rowtree-security"
if("Engineering")
module_sprites["Lucy"] = "rowtree-engineering"
else
module_sprites["Lucy"] = "rowtree-lucy"
//Custom_sprite check and entry
if (custom_sprite == 1)
module_sprites["Custom"] = "[src.ckey]-[mod]"
hands.icon_state = lowertext(mod)
feedback_inc("cyborg_[lowertext(mod)]",1)
updatename(mod)
@@ -265,6 +258,23 @@
//We also need to update name of internal camera.
if (camera)
camera.c_tag = changed_name
if(!custom_sprite) //Check for custom sprite
var/file = file2text("config/custom_sprites.txt")
var/lines = text2list(file, "\n")
for(var/line in lines)
// split & clean up
var/list/Entry = text2list(line, "-")
for(var/i = 1 to Entry.len)
Entry[i] = trim(Entry[i])
if(Entry.len < 2)
continue;
if(Entry[1] == src.ckey && Entry[2] == src.real_name) //They're in the list? Custom sprite time, var and icon change required
custom_sprite = 1
icon = 'icons/mob/custom-synthetic.dmi'
/mob/living/silicon/robot/verb/Namepick()
if(custom_name)
@@ -979,6 +989,14 @@
overlays += "eyes-[icon_state]"
else
overlays -= "eyes"
if(opened && custom_sprite == 1) //Custom borgs also have custom panels, heh
if(wiresexposed)
overlays += "[src.ckey]-openpanel +w"
else if(cell)
overlays += "[src.ckey]-openpanel +c"
else
overlays += "[src.ckey]-openpanel -c"
if(opened)
if(wiresexposed)
@@ -3,21 +3,21 @@
health = 100
stat = CONSCIOUS
return
health = 100 - getBruteLoss() - getFireLoss()
health = 100 - (getBruteLoss() + getFireLoss())
return
/mob/living/silicon/robot/getBruteLoss()
var/amount = 0
for(var/V in components)
var/datum/robot_component/C = components[V]
if(C.installed == 1) amount += C.brute_damage
if(C.installed != 0) amount += C.brute_damage
return amount
/mob/living/silicon/robot/getFireLoss()
var/amount = 0
for(var/V in components)
var/datum/robot_component/C = components[V]
if(C.installed == 1) amount += C.electronics_damage
if(C.installed != 0) amount += C.electronics_damage
return amount
/mob/living/silicon/robot/adjustBruteLoss(var/amount)
@@ -52,16 +52,31 @@
if(!parts.len) return
var/datum/robot_component/picked = pick(parts)
picked.heal_damage(brute,burn)
updatehealth()
/mob/living/silicon/robot/take_organ_damage(var/brute, var/burn, var/sharp = 0)
/mob/living/silicon/robot/take_organ_damage(var/brute = 0, var/burn = 0, var/sharp = 0)
var/list/components = get_damageable_components()
if(components.len)
if(!components.len)
return
//Combat shielding absorbs a percentage of damage directly into the cell.
if(module_active && istype(module_active,/obj/item/borg/combat/shield))
var/obj/item/borg/combat/shield/shield = module_active
//Shields absorb a certain percentage of damage based on their power setting.
var/absorb_brute = brute*shield.shield_level
var/absorb_burn = burn*shield.shield_level
var/cost = (absorb_brute+absorb_burn)*100
cell.charge -= cost
if(cell.charge <= 0)
cell.charge = 0
src << "\red Your shield has overloaded!"
else
brute -= absorb_brute
burn -= absorb_burn
src << "\red Your shield absorbs some of the impact!"
var/datum/robot_component/C = pick(components)
C.take_damage(brute,burn,sharp)
updatehealth()
/mob/living/silicon/robot/heal_overall_damage(var/brute, var/burn)
var/list/datum/robot_component/parts = get_damaged_components(brute,burn)
@@ -78,7 +93,6 @@
burn -= (burn_was-picked.electronics_damage)
parts -= picked
updatehealth()
/mob/living/silicon/robot/take_overall_damage(var/brute = 0, var/burn = 0, var/sharp = 0, var/used_weapon = null)
if(status_flags & GODMODE) return //godmode
@@ -112,6 +126,4 @@
brute -= (picked.brute_damage - brute_was)
burn -= (picked.electronics_damage - burn_was)
parts -= picked
updatehealth()
parts -= picked
+1 -1
View File
@@ -946,7 +946,7 @@ mob/verb/yank_out_object()
if(self)
visible_message("<span class='warning'><b>[src] rips [selection] out of their body.</b></span>","<span class='warning'><b>You rip [selection] out of your body.</b></span>")
else
visible_message("<span class='warning'><b>[usr] rips [selection] out of [src]'s body.</b></span>","<span class='warning'><b>[src] rips [selection] out of your body.</b></span>")
visible_message("<span class='warning'><b>[usr] rips [selection] out of [src]'s body.</b></span>","<span class='warning'><b>[usr] rips [selection] out of your body.</b></span>")
selection.loc = get_turf(src)
@@ -269,6 +269,14 @@
proc/AttemptLateSpawn(rank)
if (src != usr)
return 0
if(!ticker || ticker.current_state != GAME_STATE_PLAYING)
usr << "\red The round is either not ready, or has already finished..."
return 0
if(!enter_allowed)
usr << "\blue There is an administrative lock on entering the game!"
return 0
if(!IsJobAvailable(rank))
src << alert("[rank] is not available. Please try another.")
return 0
+2 -4
View File
@@ -211,12 +211,10 @@ NUDGE_SCRIPT_PATH nudge.py
## Comment this to unrestrict the number of alien players allowed in the round. The number represents the number of alien players for every human player.
ALIEN_PLAYER_RATIO 0.2
##Remove the # to let ghosts spin chairs
#GHOST_INTERACTION
##Remove the # to let ghosts spin chairs
## Uncomment this to enable external .rsc downloads. URLs must be separated by no more than one space.
## The linked .zip file should contain the required .rsc
#resource_urls http://firstserver.org/myresource.zip http://secondserver.org/myresource.zip http://10.22.11.1/myresource.zip
#resource_urls http://firstserver.org/myresource.zip http://secondserver.org/myresource.zip http://10.22.11.1/myresource.zip
## Uncomment to enable sending data to the IRC bot.
#USE_IRC_BOT
+6
View File
@@ -0,0 +1,6 @@
rowtree-Lucy
sydrec-SINA
mordeth221-Elly
ravensdale-Blunt
ravensdale-Skuld
serithi-REMNANT
+12 -7
View File
@@ -57,6 +57,13 @@ Stuff which is in development and not yet visible to players or just code relate
(ie. code improvements for expandability, etc.) should not be listed here. They
should be listed in the changelog upon commit though. Thanks. -->
<div class="commit sansserif">
<h2 class="date">03.07.2013</h2>
<h3 class="author">Segrain updated:</h3>
<ul class="changes bgimages16">
<li class="rscadd">Security and medical cyborgs can use their HUDs to access records.</li>
</ul>
</div>
<div class="commit sansserif">
<h2 class="date">June 28th, 2013</h2>
<h3 class="author">Segrain updated:</h3>
@@ -85,14 +92,17 @@ should be listed in the changelog upon commit though. Thanks. -->
<li class="rscadd">A few space ninja titles/names have been added and removed to be slightly more believable</li>
<li class="bugfix">The antagonist selector no longer chooses jobbanned players when it runs out of willing options</li>
</ul>
</div><div class="commit sansserif">
</div>
<div class="commit sansserif">
<h2 class="date">June 26th, 2013</h2>
<h3 class="author">Segrain updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">Autopsy scanner properly displays time of wound infliction and death.</li>
<li class="bugfix">Autopsy scanner properly displays wounds by projectile weapons.</li>
</ul>
</div> <h2 class="date">June 23rd, 2013</h2>
</div>
<div class="commit sansserif">
<h2 class="date">June 23rd, 2013</h2>
<h3 class="author">Segrain updated:</h3>
<ul class="changes bgimages16">
<li class="rscadd">Airlocks of various models can be constructed again.</li>
@@ -107,11 +117,6 @@ should be listed in the changelog upon commit though. Thanks. -->
<li class="tweak">Some maintenance doors within RnD and Medbay have had their accesses changed. Maintenance doors in the joint areas (leading to the research shuttle, virology, and xenobiology) are now zero access. Which means anyone in those joints can enter the maintenance tunnels. This was done to add additional evacuation locations during radiation storms. Additional maintenance doors were added to the tunnels in these areas to prevent docs and scientists from running about.</li>
<li class="tweak">Starboard emergency storage isn't gone now, it's simply located in the escape wing.</li>
<li class="experiment">An engineering training room has been added to engineering. This location was previously where surgery was located. If you are new to engineering or need to brush up on your skills, please use this area for testing.</li>
<h2 class="date">26.06.2013</h2>
<h3 class="author">Segrain updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">Autopsy scanner properly displays time of wound infliction and death.</li>
<li class="bugfix">Autopsy scanner properly displays wounds by projectile weapons.</li>
</ul>
</div>
BIN
View File
Binary file not shown.

Before

Width:  |  Height:  |  Size: 212 KiB

After

Width:  |  Height:  |  Size: 193 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB