mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-14 08:34:16 +01:00
Merge branch 'master' into character-slot-clearing
This commit is contained in:
@@ -146,7 +146,7 @@ datum/admins/proc/DB_ban_record(var/bantype, var/mob/banned_mob, var/duration =
|
||||
|
||||
if(kickbannedckey)
|
||||
if(banned_mob && banned_mob.client && banned_mob.client.ckey == banckey)
|
||||
del(banned_mob.client)
|
||||
qdel(banned_mob.client)
|
||||
|
||||
if(isjobban)
|
||||
jobban_client_fullban(ckey, job)
|
||||
|
||||
@@ -72,7 +72,7 @@ GLOBAL_VAR_INIT(nologevent, 0)
|
||||
body += "\[<A href='?_src_=holder;editrights=rank;ckey=[M.ckey]'>[M.client.holder ? M.client.holder.rank : "Player"]</A>\] "
|
||||
body += "\[<A href='?_src_=holder;getplaytimewindow=[M.UID()]'>" + M.client.get_exp_type(EXP_TYPE_CREW) + " as [EXP_TYPE_CREW]</a>\]"
|
||||
|
||||
if(istype(M, /mob/new_player))
|
||||
if(isnewplayer(M))
|
||||
body += " <B>Hasn't Entered Game</B> "
|
||||
else
|
||||
body += " \[<A href='?_src_=holder;revive=[M.UID()]'>Heal</A>\] "
|
||||
@@ -147,7 +147,7 @@ GLOBAL_VAR_INIT(nologevent, 0)
|
||||
body += {" | <A href='?_src_=holder;cryossd=[M.UID()]'>Cryo</A> "}
|
||||
|
||||
if(M.client)
|
||||
if(!istype(M, /mob/new_player))
|
||||
if(!isnewplayer(M))
|
||||
body += "<br><br>"
|
||||
body += "<b>Transformation:</b>"
|
||||
body += "<br>"
|
||||
@@ -1004,13 +1004,13 @@ GLOBAL_VAR_INIT(gamma_ship_location, 1) // 0 = station , 1 = space
|
||||
/proc/kick_clients_in_lobby(message, kick_only_afk = 0)
|
||||
var/list/kicked_client_names = list()
|
||||
for(var/client/C in GLOB.clients)
|
||||
if(istype(C.mob, /mob/new_player))
|
||||
if(isnewplayer(C.mob))
|
||||
if(kick_only_afk && !C.is_afk()) //Ignore clients who are not afk
|
||||
continue
|
||||
if(message)
|
||||
to_chat(C, message)
|
||||
kicked_client_names.Add("[C.ckey]")
|
||||
del(C)
|
||||
qdel(C)
|
||||
return kicked_client_names
|
||||
|
||||
//returns 1 to let the dragdrop code know we are trapping this event
|
||||
|
||||
@@ -337,7 +337,7 @@ GLOBAL_LIST_INIT(admin_verbs_ticket, list(
|
||||
ghost.reenter_corpse()
|
||||
log_admin("[key_name(usr)] re-entered their body")
|
||||
feedback_add_details("admin_verb","P") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
else if(istype(mob,/mob/new_player))
|
||||
else if(isnewplayer(mob))
|
||||
to_chat(src, "<font color='red'>Error: Aghost: Can't admin-ghost whilst in the lobby. Join or observe first.</font>")
|
||||
else
|
||||
//ghostize
|
||||
@@ -542,7 +542,7 @@ GLOBAL_LIST_INIT(admin_verbs_ticket, list(
|
||||
message_admins("[key_name_admin(src)] has warned [key_name_admin(C)] resulting in a [AUTOBANTIME] minute ban")
|
||||
log_admin("[key_name(src)] has warned [key_name(C)] resulting in a [AUTOBANTIME] minute ban")
|
||||
to_chat(C, "<font color='red'><BIG><B>You have been autobanned due to a warning by [ckey].</B></BIG><br>This is a temporary ban, it will be removed in [AUTOBANTIME] minutes.")
|
||||
del(C)
|
||||
qdel(C)
|
||||
else
|
||||
message_admins("[key_name_admin(src)] has warned [warned_ckey] resulting in a [AUTOBANTIME] minute ban")
|
||||
log_admin("[key_name(src)] has warned [warned_ckey] resulting in a [AUTOBANTIME] minute ban")
|
||||
|
||||
@@ -268,7 +268,7 @@
|
||||
else
|
||||
M_job = "Living"
|
||||
|
||||
else if(istype(M,/mob/new_player))
|
||||
else if(isnewplayer(M))
|
||||
M_job = "New player"
|
||||
|
||||
else if(isobserver(M))
|
||||
@@ -356,7 +356,7 @@
|
||||
dat += "<td>[M.real_name]</td>"
|
||||
else if(istype(M, /mob/living/silicon/pai))
|
||||
dat += "<td>pAI</td>"
|
||||
else if(istype(M, /mob/new_player))
|
||||
else if(isnewplayer(M))
|
||||
dat += "<td>New Player</td>"
|
||||
else if(isobserver(M))
|
||||
dat += "<td>Ghost</td>"
|
||||
|
||||
@@ -186,9 +186,13 @@
|
||||
var/err = query_list_notes.ErrorMsg()
|
||||
log_game("SQL ERROR obtaining ckey from notes table. Error : \[[err]\]\n")
|
||||
return
|
||||
to_chat(usr, "<span class='notice'>Started regex note search for [search]. Please wait for results...</span>")
|
||||
message_admins("[usr.ckey] has started a note search with the following regex: [search] | CPU usage may be higher.")
|
||||
while(query_list_notes.NextRow())
|
||||
index_ckey = query_list_notes.item[1]
|
||||
output += "<a href='?_src_=holder;shownoteckey=[index_ckey]'>[index_ckey]</a><br>"
|
||||
CHECK_TICK
|
||||
message_admins("The note search started by [usr.ckey] has complete. CPU should return to normal.")
|
||||
else
|
||||
output += "<center><a href='?_src_=holder;addnoteempty=1'>\[Add Note\]</a></center>"
|
||||
output += ruler
|
||||
|
||||
@@ -909,7 +909,7 @@
|
||||
log_admin("[key_name(usr)] booted [key_name(M)].")
|
||||
message_admins("<span class='notice'>[key_name_admin(usr)] booted [key_name_admin(M)].</span>", 1)
|
||||
//M.client = null
|
||||
del(M.client)
|
||||
qdel(M.client)
|
||||
|
||||
//Player Notes
|
||||
else if(href_list["addnote"])
|
||||
@@ -1011,8 +1011,7 @@
|
||||
log_admin("[key_name(usr)] has banned [M.ckey].\nReason: [reason]\nThis will be removed in [mins] minutes.")
|
||||
message_admins("<span class='notice'>[key_name_admin(usr)] has banned [M.ckey].\nReason: [reason]\nThis will be removed in [mins] minutes.</span>")
|
||||
|
||||
del(M.client)
|
||||
//qdel(M) // See no reason why to delete mob. Important stuff can be lost. And ban can be lifted before round ends.
|
||||
qdel(M.client)
|
||||
if("No")
|
||||
var/reason = input(usr,"Please state the reason","Reason") as message|null
|
||||
if(!reason)
|
||||
@@ -1032,8 +1031,7 @@
|
||||
feedback_inc("ban_perma",1)
|
||||
DB_ban_record(BANTYPE_PERMA, M, -1, reason)
|
||||
|
||||
del(M.client)
|
||||
//qdel(M)
|
||||
qdel(M.client)
|
||||
if("Cancel")
|
||||
return
|
||||
|
||||
@@ -1507,7 +1505,7 @@
|
||||
if(!check_rights(R_SPAWN)) return
|
||||
|
||||
var/mob/M = locateUID(href_list["makeanimal"])
|
||||
if(istype(M, /mob/new_player))
|
||||
if(isnewplayer(M))
|
||||
to_chat(usr, "This cannot be used on instances of type /mob/new_player")
|
||||
return
|
||||
if(alert(usr, "Confirm make animal?",, "Yes", "No") != "Yes")
|
||||
|
||||
@@ -430,7 +430,7 @@
|
||||
else if(expression[start + 1] == "\[" && islist(v))
|
||||
var/list/L = v
|
||||
var/index = SDQL_expression(source, expression[start + 2])
|
||||
if(isnum(index) && (!IsInteger(index) || L.len < index))
|
||||
if(isnum(index) && (!ISINTEGER(index) || L.len < index))
|
||||
to_chat(world, "<span class='danger'>Invalid list index: [index]</span>")
|
||||
return null
|
||||
return L[index]
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
var/list/client/targets[0]
|
||||
for(var/client/T)
|
||||
if(T.mob)
|
||||
if(istype(T.mob, /mob/new_player))
|
||||
if(isnewplayer(T.mob))
|
||||
targets["(New Player) - [T]"] = T
|
||||
else if(istype(T.mob, /mob/dead/observer))
|
||||
targets["[T.mob.name](Ghost) - [T]"] = T
|
||||
@@ -42,7 +42,7 @@
|
||||
var/list/client/targets[0]
|
||||
for(var/client/T)
|
||||
if(T.mob)
|
||||
if(istype(T.mob, /mob/new_player))
|
||||
if(isnewplayer(T.mob))
|
||||
targets["[T] - (New Player)"] = T
|
||||
else if(istype(T.mob, /mob/dead/observer))
|
||||
targets["[T] - [T.mob.name](Ghost)"] = T
|
||||
|
||||
@@ -251,7 +251,7 @@ GLOBAL_PROTECT(AdminProcCaller)
|
||||
alert("That mob doesn't seem to exist, close the panel and try again.")
|
||||
return
|
||||
|
||||
if(istype(M, /mob/new_player))
|
||||
if(isnewplayer(M))
|
||||
alert("The mob must not be a new_player.")
|
||||
return
|
||||
|
||||
@@ -382,7 +382,7 @@ GLOBAL_PROTECT(AdminProcCaller)
|
||||
if(!check_rights(R_DEBUG))
|
||||
return
|
||||
|
||||
//This gets a confirmation check because it's way easier to accidentally hit this and delete things than it is with del-all
|
||||
//This gets a confirmation check because it's way easier to accidentally hit this and delete things than it is with qdel-all
|
||||
var/confirm = alert("This will delete ALL Singularities and Tesla orbs except for any that are on away mission z-levels or the centcomm z-level. Are you sure you want to delete them?", "Confirm Panic Button", "Yes", "No")
|
||||
if(confirm != "Yes")
|
||||
return
|
||||
@@ -816,21 +816,6 @@ GLOBAL_PROTECT(AdminProcCaller)
|
||||
else
|
||||
alert("Invalid mob")
|
||||
|
||||
/client/proc/reload_nanoui_resources()
|
||||
set category = "Debug"
|
||||
set name = "Reload NanoUI Resources"
|
||||
set desc = "Force the client to redownload NanoUI Resources"
|
||||
|
||||
// Close open NanoUIs.
|
||||
SSnanoui.close_user_uis(usr)
|
||||
|
||||
// Re-load the assets.
|
||||
var/datum/asset/assets = get_asset_datum(/datum/asset/nanoui)
|
||||
assets.register()
|
||||
|
||||
// Clear the user's cache so they get resent.
|
||||
usr.client.cache = list()
|
||||
|
||||
/client/proc/view_runtimes()
|
||||
set category = "Debug"
|
||||
set name = "View Runtimes"
|
||||
|
||||
@@ -15,9 +15,7 @@
|
||||
if(T.active_hotspot)
|
||||
burning = 1
|
||||
|
||||
to_chat(usr, "<span class='notice'>@[target.x],[target.y]: O:[GM.oxygen] T:[GM.toxins] N:[GM.nitrogen] C:[GM.carbon_dioxide] w [GM.temperature] Kelvin, [GM.return_pressure()] kPa [(burning)?("<span class='warning'>BURNING</span>"):(null)]</span>")
|
||||
for(var/datum/gas/trace_gas in GM.trace_gases)
|
||||
to_chat(usr, "[trace_gas.type]: [trace_gas.moles]")
|
||||
to_chat(usr, "<span class='notice'>@[target.x],[target.y]: O:[GM.oxygen] T:[GM.toxins] N:[GM.nitrogen] C:[GM.carbon_dioxide] N2O: [GM.sleeping_agent] Agent B: [GM.agent_b] w [GM.temperature] Kelvin, [GM.return_pressure()] kPa [(burning)?("<span class='warning'>BURNING</span>"):(null)]</span>")
|
||||
|
||||
message_admins("[key_name_admin(usr)] has checked the air status of [target]")
|
||||
log_admin("[key_name(usr)] has checked the air status of [target]")
|
||||
|
||||
@@ -73,9 +73,11 @@
|
||||
..()
|
||||
if((ishuman(hit_atom)))
|
||||
var/mob/living/carbon/human/H = hit_atom
|
||||
if(H.r_hand == src) return
|
||||
if(H.l_hand == src) return
|
||||
var/mob/A = H.LAssailant
|
||||
if(H.r_hand == src)
|
||||
return
|
||||
if(H.l_hand == src)
|
||||
return
|
||||
var/mob/A = thrownby
|
||||
if((H in GLOB.team_alpha) && (A in GLOB.team_alpha))
|
||||
to_chat(A, "<span class='warning'>He's on your team!</span>")
|
||||
return
|
||||
@@ -89,4 +91,3 @@
|
||||
playsound(src, 'sound/items/dodgeball.ogg', 50, 1)
|
||||
visible_message("<span class='danger'>[H] HAS BEEN ELIMINATED!</span>")
|
||||
H.melt()
|
||||
return
|
||||
|
||||
@@ -18,7 +18,6 @@ GLOBAL_LIST_INIT(admin_verbs_show_debug_verbs, list(
|
||||
/client/proc/print_jobban_old_filter,
|
||||
/client/proc/forceEvent,
|
||||
/client/proc/nanomapgen_DumpImage,
|
||||
/client/proc/reload_nanoui_resources,
|
||||
/client/proc/admin_redo_space_transitions,
|
||||
/client/proc/make_turf_space_map,
|
||||
/client/proc/vv_by_ref
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
sources_assoc[source] = AS
|
||||
// Currently only non-0 durations can be altered (normal alarms VS EMP blasts)
|
||||
if(AS.duration)
|
||||
duration = SecondsToTicks(duration)
|
||||
duration = duration SECONDS
|
||||
AS.duration = duration
|
||||
AS.severity = severity
|
||||
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
/obj/machinery/computer/mob_battle_terminal/proc/eject_card(override = 0)
|
||||
if(!override)
|
||||
if(ready && SSmob_hunt.battle_turn != team)
|
||||
audible_message("You can't recall on your rival's turn!", null, 2)
|
||||
atom_say("You can't recall on your rival's turn!")
|
||||
return
|
||||
card.mob_data = mob_info
|
||||
mob_info = null
|
||||
@@ -202,7 +202,7 @@
|
||||
start_battle()
|
||||
else if(option == 2)
|
||||
ready = 0
|
||||
audible_message("[team] Player cancels their battle challenge.", null, 5)
|
||||
atom_say("[team] Player cancels their battle challenge.")
|
||||
|
||||
updateUsrDialog()
|
||||
|
||||
@@ -246,7 +246,7 @@
|
||||
var/message = "[mob_info.mob_name] attacks!"
|
||||
if(mob_info.nickname)
|
||||
message = "[mob_info.nickname] attacks!"
|
||||
audible_message(message, null, 5)
|
||||
atom_say(message)
|
||||
SSmob_hunt.launch_attack(team, mob_info.get_raw_damage(), mob_info.get_attack_type())
|
||||
|
||||
/obj/machinery/computer/mob_battle_terminal/proc/start_battle()
|
||||
@@ -255,7 +255,7 @@
|
||||
if(!card) //don't do anything if there isn't a card inserted
|
||||
return
|
||||
ready = 1
|
||||
audible_message("[team] Player is ready for battle! Waiting for rival...", null, 5)
|
||||
atom_say("[team] Player is ready for battle! Waiting for rival...")
|
||||
SSmob_hunt.start_check()
|
||||
|
||||
/obj/machinery/computer/mob_battle_terminal/proc/receive_attack(raw_damage, datum/mob_type/attack_type)
|
||||
@@ -268,7 +268,7 @@
|
||||
SSmob_hunt.end_turn()
|
||||
|
||||
/obj/machinery/computer/mob_battle_terminal/proc/surrender()
|
||||
audible_message("[team] Player surrenders the battle!", null, 5)
|
||||
atom_say("[team] Player surrenders the battle!")
|
||||
SSmob_hunt.end_battle(team, 1)
|
||||
|
||||
//////////////////////////////
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
var/datum/data/pda/app/mob_hunter_game/client = P.current_app
|
||||
var/total_catch_mod = client.catch_mod + catch_mod //negative values decrease the chance of the mob running, positive values makes it more likely to flee
|
||||
if(!client.connected) //must be connected to attempt captures
|
||||
P.audible_message("[bicon(P)] No server connection. Capture aborted.", null, 4)
|
||||
P.atom_say("No server connection. Capture aborted.")
|
||||
return
|
||||
|
||||
if(mob_info.is_trap) //traps work even if you ran into them before, which is why this is before the clients_encountered check
|
||||
@@ -79,7 +79,7 @@
|
||||
return
|
||||
else //deal with the new hunter by either running away or getting caught
|
||||
clients_encountered += client
|
||||
var/message = "[bicon(P)] "
|
||||
var/message = null
|
||||
var/effective_run_chance = mob_info.run_chance + total_catch_mod
|
||||
if((effective_run_chance > 0) && prob(effective_run_chance))
|
||||
message += "Capture failed! [name] escaped [P.owner ? "from [P.owner]" : "from this hunter"]!"
|
||||
@@ -91,7 +91,7 @@
|
||||
else
|
||||
message += "Capture error! Try again."
|
||||
clients_encountered -= client //if the capture registration failed somehow, let them have another chance with this mob
|
||||
P.audible_message(message, null, 4)
|
||||
P.atom_say(message)
|
||||
|
||||
/obj/effect/nanomob/proc/despawn()
|
||||
if(SSmob_hunt)
|
||||
|
||||
@@ -139,7 +139,7 @@
|
||||
for(var/areapath in typesof(A))
|
||||
possible_areas[areapath] -= 2
|
||||
//removes "bad areas" which shouldn't be on-station but are subtypes of station areas. probably should the unused ones and consider repathing the rest
|
||||
var/list/bad_areas = list(subtypesof(/area/construction), /area/solar/derelict_starboard, /area/solar/derelict_aft, /area/solar/constructionsite)
|
||||
var/list/bad_areas = list(subtypesof(/area/construction), /area/solar/derelict_starboard, /area/solar/derelict_aft)
|
||||
for(var/A in bad_areas)
|
||||
possible_areas -= A
|
||||
//weight check, remove negative or zero weight areas from the list, then return the list.
|
||||
|
||||
@@ -59,8 +59,7 @@
|
||||
cooldown--
|
||||
if(cooldown <= 0)
|
||||
return FALSE
|
||||
spawn(10)
|
||||
process_cooldown()
|
||||
addtimer(CALLBACK(src, .proc/process_cooldown), 10)
|
||||
return TRUE
|
||||
|
||||
/obj/item/assembly/Destroy()
|
||||
@@ -94,8 +93,7 @@
|
||||
if(!secured || cooldown > 0)
|
||||
return FALSE
|
||||
cooldown = 2
|
||||
spawn(10)
|
||||
process_cooldown()
|
||||
addtimer(CALLBACK(src, .proc/process_cooldown), 10)
|
||||
return TRUE
|
||||
|
||||
/obj/item/assembly/toggle_secure()
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
health_scan = M.health
|
||||
if(health_scan <= alarm_health)
|
||||
pulse()
|
||||
audible_message("[bicon(src)] *beep* *beep*", "*beep* *beep*")
|
||||
audible_message("[bicon(src)] *beep* *beep*")
|
||||
toggle_scan()
|
||||
return
|
||||
return
|
||||
|
||||
@@ -127,13 +127,12 @@
|
||||
/obj/item/assembly/infra/proc/trigger_beam()
|
||||
if(!secured || !on || cooldown > 0)
|
||||
return FALSE
|
||||
pulse(0)
|
||||
audible_message("[bicon(src)] *beep* *beep*", null, 3)
|
||||
cooldown = 2
|
||||
pulse(FALSE)
|
||||
audible_message("[bicon(src)] *beep* *beep*", hearing_distance = 3)
|
||||
if(first)
|
||||
qdel(first)
|
||||
cooldown = 2
|
||||
spawn(10)
|
||||
process_cooldown()
|
||||
addtimer(CALLBACK(src, .proc/process_cooldown), 10)
|
||||
|
||||
/obj/item/assembly/infra/interact(mob/user)//TODO: change this this to the wire control panel
|
||||
if(!secured) return
|
||||
|
||||
@@ -47,11 +47,10 @@
|
||||
/obj/item/assembly/prox_sensor/proc/sense()
|
||||
if(!secured || !scanning || cooldown > 0)
|
||||
return FALSE
|
||||
pulse(0)
|
||||
visible_message("[bicon(src)] *beep* *beep*", "*beep* *beep*")
|
||||
cooldown = 2
|
||||
spawn(10)
|
||||
process_cooldown()
|
||||
pulse(FALSE)
|
||||
visible_message("[bicon(src)] *beep* *beep*", "*beep* *beep*")
|
||||
addtimer(CALLBACK(src, .proc/process_cooldown), 10)
|
||||
|
||||
/obj/item/assembly/prox_sensor/process()
|
||||
if(timing && (time >= 0))
|
||||
|
||||
@@ -41,8 +41,7 @@
|
||||
if(cooldown > 0)
|
||||
return FALSE
|
||||
cooldown = 2
|
||||
spawn(10)
|
||||
process_cooldown()
|
||||
addtimer(CALLBACK(src, .proc/process_cooldown), 10)
|
||||
|
||||
signal()
|
||||
return TRUE
|
||||
|
||||
@@ -39,12 +39,11 @@
|
||||
/obj/item/assembly/timer/proc/timer_end()
|
||||
if(!secured || cooldown > 0)
|
||||
return FALSE
|
||||
pulse(0)
|
||||
cooldown = 2
|
||||
pulse(FALSE)
|
||||
if(loc)
|
||||
loc.visible_message("[bicon(src)] *beep* *beep*", "*beep* *beep*")
|
||||
cooldown = 2
|
||||
spawn(10)
|
||||
process_cooldown()
|
||||
addtimer(CALLBACK(src, .proc/process_cooldown), 10)
|
||||
|
||||
/obj/item/assembly/timer/process()
|
||||
if(timing && (time > 0))
|
||||
|
||||
@@ -7,32 +7,32 @@
|
||||
|
||||
/area/awaymission/centcomAway/general
|
||||
name = "XCC-P5831"
|
||||
music = "music/ambigen3.ogg"
|
||||
ambientsounds = list('sound/ambience/ambigen3.ogg')
|
||||
|
||||
/area/awaymission/centcomAway/maint
|
||||
name = "XCC-P5831 Maintenance"
|
||||
icon_state = "away1"
|
||||
music = "music/ambisin1.ogg"
|
||||
ambientsounds = list('sound/ambience/ambisin1.ogg')
|
||||
|
||||
/area/awaymission/centcomAway/thunderdome
|
||||
name = "XCC-P5831 Thunderdome"
|
||||
icon_state = "away2"
|
||||
music = "music/ambisin2.ogg"
|
||||
ambientsounds = list('sound/ambience/ambisin2.ogg')
|
||||
|
||||
/area/awaymission/centcomAway/cafe
|
||||
name = "XCC-P5831 Kitchen Arena"
|
||||
icon_state = "away3"
|
||||
music = "music/ambisin3.ogg"
|
||||
ambientsounds = list('sound/ambience/ambisin3.ogg')
|
||||
|
||||
/area/awaymission/centcomAway/courtroom
|
||||
name = "XCC-P5831 Courtroom"
|
||||
icon_state = "away4"
|
||||
music = "music/ambisin4.ogg"
|
||||
ambientsounds = list('sound/ambience/ambisin4.ogg')
|
||||
|
||||
/area/awaymission/centcomAway/hangar
|
||||
name = "XCC-P5831 Hangars"
|
||||
icon_state = "away4"
|
||||
music = "music/ambigen5.ogg"
|
||||
ambientsounds = list('sound/ambience/ambigen5.ogg')
|
||||
|
||||
//centcomAway items
|
||||
|
||||
|
||||
@@ -321,6 +321,7 @@
|
||||
name = "Beta Station Atmospherics"
|
||||
icon_state = "red"
|
||||
has_gravity = FALSE
|
||||
ambientsounds = ENGINEERING_SOUNDS
|
||||
|
||||
/area/ruin/space/ancientstation/betanorth
|
||||
name = "Beta Station North Corridor"
|
||||
@@ -333,6 +334,7 @@
|
||||
/area/ruin/space/ancientstation/engi
|
||||
name = "Charlie Station Engineering"
|
||||
icon_state = "engine"
|
||||
ambientsounds = ENGINEERING_SOUNDS
|
||||
|
||||
/area/ruin/space/ancientstation/comm
|
||||
name = "Charlie Station Command"
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
var/matrix/mat = matrix()
|
||||
mat.Translate(0, 16)
|
||||
mat.Scale(1, sqrt((x_offset * x_offset) + (y_offset * y_offset)) / 32)
|
||||
mat.Turn(90 - Atan2(x_offset, y_offset)) // So... You pass coords in order x,y to this version of atan2. It should be called acsc2.
|
||||
mat.Turn(90 - ATAN2(x_offset, y_offset)) // So... You pass coords in order x,y to this version of atan2. It should be called acsc2.
|
||||
mat.Translate(atom_a.pixel_x, atom_a.pixel_y)
|
||||
|
||||
transform = mat
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
var/plasma = 0
|
||||
var/cdiox = 0
|
||||
var/nitrox = 0
|
||||
var/agentbx = 0
|
||||
|
||||
|
||||
/datum/buildmode_mode/atmos/show_help(mob/user)
|
||||
@@ -29,6 +30,7 @@
|
||||
plasma = input(user, "Plasma ratio", "Input", 0) as num|null
|
||||
cdiox = input(user, "CO2 ratio", "Input", 0) as num|null
|
||||
nitrox = input(user, "N2O ratio", "Input", 0) as num|null
|
||||
agentbx = input(user, "Agent B ratio", "Input", 0) as num|null
|
||||
|
||||
/datum/buildmode_mode/atmos/proc/ppratio_to_moles(ppratio)
|
||||
// ideal gas equation: Pressure * Volume = Moles * r * Temperature
|
||||
@@ -52,11 +54,8 @@
|
||||
S.air.nitrogen = ppratio_to_moles(nitrogen)
|
||||
S.air.toxins = ppratio_to_moles(plasma)
|
||||
S.air.carbon_dioxide = ppratio_to_moles(cdiox)
|
||||
S.air.trace_gases.Cut()
|
||||
if(nitrox)
|
||||
var/datum/gas/TG = new /datum/gas/sleeping_agent
|
||||
TG.moles = ppratio_to_moles(nitrox)
|
||||
S.air.trace_gases += TG
|
||||
S.air.sleeping_agent = ppratio_to_moles(nitrox)
|
||||
S.air.agent_b = ppratio_to_moles(agentbx)
|
||||
S.update_visuals()
|
||||
S.air_update_turf()
|
||||
else if(ctrl_click) // overwrite "default" unsimulated air
|
||||
@@ -65,7 +64,8 @@
|
||||
T.nitrogen = ppratio_to_moles(nitrogen)
|
||||
T.toxins = ppratio_to_moles(plasma)
|
||||
T.carbon_dioxide = ppratio_to_moles(cdiox)
|
||||
// no interface for trace gases on unsim turfs
|
||||
T.sleeping_agent = ppratio_to_moles(nitrox)
|
||||
T.agent_b = ppratio_to_moles(agentbx)
|
||||
T.air_update_turf()
|
||||
|
||||
// admin log
|
||||
|
||||
@@ -22,6 +22,6 @@
|
||||
if(stored)
|
||||
DuplicateObject(stored, perfectcopy=1, sameloc=0,newloc=T)
|
||||
else if(right_click)
|
||||
if(ismovableatom(object)) // No copying turfs for now.
|
||||
if(ismovable(object)) // No copying turfs for now.
|
||||
to_chat(user, "<span class='notice'>[object] set as template.</span>")
|
||||
stored = object
|
||||
|
||||
@@ -177,6 +177,12 @@ GLOBAL_LIST_EMPTY(asset_datums)
|
||||
|
||||
|
||||
//DEFINITIONS FOR ASSET DATUMS START HERE.
|
||||
/datum/asset/simple/tgui
|
||||
assets = list(
|
||||
"tgui.bundle.js" = 'tgui/packages/tgui/public/tgui.bundle.js',
|
||||
"tgui.bundle.css" = 'tgui/packages/tgui/public/tgui.bundle.css'
|
||||
)
|
||||
|
||||
/datum/asset/simple/paper
|
||||
assets = list(
|
||||
"large_stamp-clown.png" = 'icons/paper_icons/large_stamp-clown.png',
|
||||
@@ -344,3 +350,15 @@ GLOBAL_LIST_EMPTY(asset_datums)
|
||||
|
||||
/datum/asset/mob_hunt/send(client)
|
||||
send_asset_list(client, assets, verify)
|
||||
|
||||
// Fontawesome
|
||||
/datum/asset/simple/fontawesome
|
||||
verify = FALSE
|
||||
assets = list(
|
||||
"fa-regular-400.eot" = 'html/font-awesome/webfonts/fa-regular-400.eot',
|
||||
"fa-regular-400.woff" = 'html/font-awesome/webfonts/fa-regular-400.woff',
|
||||
"fa-solid-900.eot" = 'html/font-awesome/webfonts/fa-solid-900.eot',
|
||||
"fa-solid-900.woff" = 'html/font-awesome/webfonts/fa-solid-900.woff',
|
||||
"font-awesome.css" = 'html/font-awesome/css/all.min.css',
|
||||
"v4shim.css" = 'html/font-awesome/css/v4-shims.min.css'
|
||||
)
|
||||
|
||||
@@ -59,10 +59,6 @@
|
||||
var/karma = 0
|
||||
var/karma_spent = 0
|
||||
var/karma_tab = 0
|
||||
/////////////////////////////////////////////
|
||||
// /vg/: MEDIAAAAAAAA
|
||||
// Set on login.
|
||||
var/datum/media_manager/media = null
|
||||
|
||||
var/topic_debugging = 0 //if set to true, allows client to see nanoUI errors -- yes i realize this is messy but it'll make live testing infinitely easier
|
||||
|
||||
@@ -85,10 +81,10 @@
|
||||
// If set to true, this client can interact with atoms such as buttons and doors on top of regular machinery interaction
|
||||
var/advanced_admin_interaction = FALSE
|
||||
|
||||
// Has the client been varedited by an admin? [Inherits from datum now]
|
||||
// var/var_edited = FALSE
|
||||
|
||||
var/client_keysend_amount = 0
|
||||
var/next_keysend_reset = 0
|
||||
var/next_keysend_trip_reset = 0
|
||||
var/keysend_tripped = FALSE
|
||||
|
||||
// Last world.time that the player tried to request their resources.
|
||||
var/last_ui_resource_send = 0
|
||||
|
||||
@@ -432,7 +432,13 @@
|
||||
//////////////
|
||||
//DISCONNECT//
|
||||
//////////////
|
||||
|
||||
/client/Del()
|
||||
if(!gc_destroyed)
|
||||
Destroy() //Clean up signals and timers.
|
||||
return ..()
|
||||
|
||||
/client/Destroy()
|
||||
if(holder)
|
||||
holder.owner = null
|
||||
GLOB.admins -= src
|
||||
@@ -442,7 +448,8 @@
|
||||
movingmob.client_mobs_in_contents -= mob
|
||||
UNSETEMPTY(movingmob.client_mobs_in_contents)
|
||||
Master.UpdateTickRate()
|
||||
return ..()
|
||||
..() //Even though we're going to be hard deleted there are still some things that want to know the destroy is happening
|
||||
return QDEL_HINT_HARDDEL_NOW
|
||||
|
||||
|
||||
/client/proc/donator_check()
|
||||
@@ -556,7 +563,7 @@
|
||||
if(GLOB.panic_bunker_enabled)
|
||||
var/threshold = config.panic_bunker_threshold
|
||||
src << "Server is not accepting connections from never-before-seen players until player count is less than [threshold]. Please try again later."
|
||||
del(src)
|
||||
qdel(src)
|
||||
return // Dont insert or they can just go in again
|
||||
|
||||
var/DBQuery/query_insert = GLOB.dbcon.NewQuery("INSERT INTO [format_table_name("player")] (id, ckey, firstseen, lastseen, ip, computerid, lastadminrank) VALUES (null, '[ckey]', Now(), Now(), '[sql_ip]', '[sql_computerid]', '[sql_admin_rank]')")
|
||||
@@ -906,3 +913,35 @@
|
||||
return TRUE
|
||||
|
||||
#undef SSD_WARNING_TIMER
|
||||
|
||||
/client/verb/resend_ui_resources()
|
||||
set name = "Reload UI Resources"
|
||||
set desc = "Reload your UI assets if they are not working"
|
||||
set category = "Special Verbs"
|
||||
|
||||
if(last_ui_resource_send > world.time)
|
||||
to_chat(usr, "<span class='warning'>You requested your UI resource files too quickly. Please try again in [(last_ui_resource_send - world.time)/10] seconds.</span>")
|
||||
return
|
||||
|
||||
var/choice = alert(usr, "This will reload your NanoUI and TGUI resources. If you have any open UIs this may break them. Are you sure?", "Resource Reloading", "Yes", "No")
|
||||
if(choice == "Yes")
|
||||
// 600 deciseconds = 1 minute
|
||||
last_ui_resource_send = world.time + 60 SECONDS
|
||||
|
||||
// Close their open UIs
|
||||
SSnanoui.close_user_uis(usr)
|
||||
SStgui.close_user_uis(usr)
|
||||
|
||||
// Resend the resources
|
||||
var/datum/asset/nano_assets = get_asset_datum(/datum/asset/nanoui)
|
||||
nano_assets.register()
|
||||
|
||||
var/datum/asset/tgui_assets = get_asset_datum(/datum/asset/simple/tgui)
|
||||
tgui_assets.register()
|
||||
|
||||
// Clear the user's cache so they get resent.
|
||||
// This is not fully clearing their BYOND cache, just their assets sent from the server this round
|
||||
cache = list()
|
||||
|
||||
to_chat(usr, "<span class='notice'>UI resource files resent successfully. If you are still having issues, please try manually clearing your BYOND cache. <b>This can be achieved by opening your BYOND launcher, pressing the cog in the top right, selecting preferences, going to the Games tab, and pressing 'Clear Cache'.</b></span>")
|
||||
|
||||
|
||||
@@ -96,7 +96,7 @@
|
||||
UI_style_alpha='[UI_style_alpha]',
|
||||
be_role='[sanitizeSQL(list2params(be_special))]',
|
||||
default_slot='[default_slot]',
|
||||
toggles='[num2text(toggles, Ceiling(log(10, (TOGGLES_TOTAL))))]',
|
||||
toggles='[num2text(toggles, CEILING(log(10, (TOGGLES_TOTAL)), 1))]',
|
||||
atklog='[atklog]',
|
||||
sound='[sound]',
|
||||
randomslot='[randomslot]',
|
||||
|
||||
@@ -113,7 +113,7 @@
|
||||
|
||||
/obj/item/clothing/head/soft/sec/corp
|
||||
name = "corporate security cap"
|
||||
desc = "It's baseball hat in corpotate colours."
|
||||
desc = "It's a baseball hat in corporate colours."
|
||||
icon_state = "corpsoft"
|
||||
item_color = "corp"
|
||||
|
||||
|
||||
@@ -531,7 +531,7 @@
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/process()
|
||||
if(world.time > recharge_cooldown && current_charges < max_charges)
|
||||
current_charges = Clamp((current_charges + recharge_rate), 0, max_charges)
|
||||
current_charges = clamp((current_charges + recharge_rate), 0, max_charges)
|
||||
playsound(loc, 'sound/magic/charge.ogg', 50, TRUE)
|
||||
if(current_charges == max_charges)
|
||||
playsound(loc, 'sound/machines/ding.ogg', 50, TRUE)
|
||||
|
||||
@@ -155,9 +155,8 @@
|
||||
if(piece.siemens_coefficient > siemens_coefficient) //So that insulated gloves keep their insulation.
|
||||
piece.siemens_coefficient = siemens_coefficient
|
||||
piece.permeability_coefficient = permeability_coefficient
|
||||
if(islist(armor))
|
||||
var/list/L = armor
|
||||
piece.armor = L.Copy()
|
||||
if(armor)
|
||||
piece.armor = armor
|
||||
|
||||
update_icon(1)
|
||||
|
||||
@@ -286,7 +285,7 @@
|
||||
if(helmet)
|
||||
helmet.update_light(wearer)
|
||||
|
||||
correct_piece.armor["bio"] = 100
|
||||
correct_piece.armor = correct_piece.armor.setRating(bio_value = 100)
|
||||
|
||||
sealing = FALSE
|
||||
|
||||
@@ -389,7 +388,7 @@
|
||||
if(helmet)
|
||||
helmet.update_light(wearer)
|
||||
|
||||
correct_piece.armor["bio"] = armor["bio"]
|
||||
correct_piece.armor = correct_piece.armor.setRating(bio_value = armor.getRating("bio"))
|
||||
|
||||
sealing = FALSE
|
||||
|
||||
@@ -553,7 +552,7 @@
|
||||
|
||||
data["charge"] = cell ? round(cell.charge,1) : 0
|
||||
data["maxcharge"] = cell ? cell.maxcharge : 0
|
||||
data["chargestatus"] = cell ? Floor((cell.charge/cell.maxcharge)*50) : 0
|
||||
data["chargestatus"] = cell ? FLOOR((cell.charge/cell.maxcharge)*50, 1) : 0
|
||||
|
||||
data["emagged"] = subverted
|
||||
data["coverlock"] = locked
|
||||
|
||||
@@ -9,13 +9,22 @@
|
||||
multi *= (100 - chest.damage) / 100 //If we have some breaches, lower the armor value.
|
||||
|
||||
//TODO check for other armor mods, likely modules, which need to be coded.
|
||||
if(!armor) //Did we even give them some armor, if this is the case, the list should be initialized from New()
|
||||
return
|
||||
|
||||
var/datum/armor/A = armor
|
||||
for(var/obj/item/piece in list(gloves, helmet, boots, chest))
|
||||
if(!istype(piece)) //Do we have the piece
|
||||
continue
|
||||
if(islist(armor)) //Did we even give them some armor, if this is the case, the list should be initialized from New()
|
||||
var/list/L = armor
|
||||
for(var/armortype in L)
|
||||
piece.armor[armortype] = L[armortype]*multi
|
||||
|
||||
piece.armor = piece.armor.setRating(melee_value = A.getRating("melee") * multi,
|
||||
bullet_value = A.getRating("bullet") * multi,
|
||||
laser_value = A.getRating("laser") * multi,
|
||||
energy_value = A.getRating("energy") * multi,
|
||||
bomb_value = A.getRating("bomb") * multi,
|
||||
bio_value = A.getRating("bio") * multi,
|
||||
rad_value = A.getRating("rad") * multi,
|
||||
fire_value = A.getRating("fire") * multi,
|
||||
acid_value = A.getRating("acidd") * multi)
|
||||
|
||||
//Perfect place to also add something like shield modules, or any other hit_reaction modules check.
|
||||
|
||||
@@ -37,8 +37,13 @@
|
||||
var/mob/M = has_suit.loc
|
||||
A.Grant(M)
|
||||
|
||||
for(var/armor_type in armor)
|
||||
has_suit.armor[armor_type] += armor[armor_type]
|
||||
if (islist(has_suit.armor) || isnull(has_suit.armor)) // This proc can run before /obj/Initialize has run for U and src,
|
||||
has_suit.armor = getArmor(arglist(has_suit.armor)) // we have to check that the armor list has been transformed into a datum before we try to call a proc on it
|
||||
// This is safe to do as /obj/Initialize only handles setting up the datum if actually needed.
|
||||
if (islist(armor) || isnull(armor))
|
||||
armor = getArmor(arglist(armor))
|
||||
|
||||
has_suit.armor = has_suit.armor.attachArmor(armor)
|
||||
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You attach [src] to [has_suit].</span>")
|
||||
@@ -56,8 +61,7 @@
|
||||
var/mob/M = has_suit.loc
|
||||
A.Remove(M)
|
||||
|
||||
for(var/armor_type in armor)
|
||||
has_suit.armor[armor_type] -= armor[armor_type]
|
||||
has_suit.armor = has_suit.armor.detachArmor(armor)
|
||||
|
||||
has_suit = null
|
||||
if(user)
|
||||
@@ -314,6 +318,36 @@
|
||||
if(isliving(user))
|
||||
user.visible_message("<span class='warning'>[user] invades [M]'s personal space, thrusting [src] into [M.p_their()] face insistently.</span>","<span class='warning'>You invade [M]'s personal space, thrusting [src] into [M.p_their()] face insistently. You are the law.</span>")
|
||||
|
||||
//////////////
|
||||
//OBJECTION!//
|
||||
//////////////
|
||||
|
||||
/obj/item/clothing/accessory/lawyers_badge
|
||||
name = "attorney's badge"
|
||||
desc = "Fills you with the conviction of JUSTICE. Lawyers tend to want to show it to everyone they meet."
|
||||
icon_state = "lawyerbadge"
|
||||
item_state = "lawyerbadge"
|
||||
item_color = "lawyerbadge"
|
||||
var/cached_bubble_icon = null
|
||||
|
||||
/obj/item/clothing/accessory/lawyers_badge/attack_self(mob/user)
|
||||
if(prob(1))
|
||||
user.say("The testimony contradicts the evidence!")
|
||||
user.visible_message("<span class='notice'>[user] shows [user.p_their()] attorney's badge.</span>", "<span class='notice'>You show your attorney's badge.</span>")
|
||||
|
||||
/obj/item/clothing/accessory/lawyers_badge/on_attached(obj/item/clothing/under/S, mob/user)
|
||||
..()
|
||||
if(has_suit && ismob(has_suit.loc))
|
||||
var/mob/M = has_suit.loc
|
||||
cached_bubble_icon = M.bubble_icon
|
||||
M.bubble_icon = "lawyer"
|
||||
|
||||
/obj/item/clothing/accessory/lawyers_badge/on_removed(mob/user)
|
||||
if(has_suit && ismob(has_suit.loc))
|
||||
var/mob/M = has_suit.loc
|
||||
M.bubble_icon = cached_bubble_icon
|
||||
..()
|
||||
|
||||
///////////
|
||||
//SCARVES//
|
||||
///////////
|
||||
|
||||
@@ -128,7 +128,7 @@
|
||||
continue main_loop
|
||||
return FALSE
|
||||
for(var/obj/item/T in tools_used)
|
||||
if(!T.tool_start_check(user, 0)) //Check if all our tools are valid for their use
|
||||
if(!T.tool_start_check(null, user, 0)) //Check if all our tools are valid for their use
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
|
||||
var/mob/living/carbon/human/target = M
|
||||
|
||||
if(ismachine(target))
|
||||
if(ismachineperson(target))
|
||||
to_chat(user, "<span class= 'notice'>[target] has no skin, how do you expect to tattoo [target.p_them()]?</span>")
|
||||
return
|
||||
|
||||
|
||||
@@ -18,7 +18,6 @@
|
||||
amount_per_transfer_from_this = 5
|
||||
possible_transfer_amounts = list(5)
|
||||
volume = 5
|
||||
can_be_placed_into = null
|
||||
flags = NOBLUDGEON
|
||||
container_type = OPENCONTAINER
|
||||
has_lid = FALSE
|
||||
|
||||
@@ -159,7 +159,7 @@ GLOBAL_VAR(current_date_string)
|
||||
var/account_name = href_list["holder_name"]
|
||||
var/starting_funds = max(text2num(href_list["starting_funds"]), 0)
|
||||
|
||||
starting_funds = Clamp(starting_funds, 0, GLOB.station_account.money) // Not authorized to put the station in debt.
|
||||
starting_funds = clamp(starting_funds, 0, GLOB.station_account.money) // Not authorized to put the station in debt.
|
||||
starting_funds = min(starting_funds, fund_cap) // Not authorized to give more than the fund cap.
|
||||
|
||||
var/datum/money_account/M = create_account(account_name, starting_funds, src)
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
if(!newAnomaly)
|
||||
kill()
|
||||
return
|
||||
if(IsMultiple(activeFor, 5))
|
||||
if(ISMULTIPLE(activeFor, 5))
|
||||
newAnomaly.anomalyEffect()
|
||||
|
||||
/datum/event/anomaly/anomaly_pyro/end()
|
||||
|
||||
@@ -55,12 +55,12 @@
|
||||
kill()
|
||||
return
|
||||
|
||||
if(IsMultiple(activeFor, 4))
|
||||
if(ISMULTIPLE(activeFor, 4))
|
||||
var/obj/machinery/vending/rebel = pick(vendingMachines)
|
||||
vendingMachines.Remove(rebel)
|
||||
infectedMachines.Add(rebel)
|
||||
rebel.shut_up = 0
|
||||
rebel.shoot_inventory = 1
|
||||
|
||||
if(IsMultiple(activeFor, 8))
|
||||
if(ISMULTIPLE(activeFor, 8))
|
||||
originMachine.speak(pick(rampant_speeches))
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
/datum/event/communications_blackout/start()
|
||||
// This only affects the cores, relays should be unaffected imo
|
||||
for(var/obj/machinery/tcomms/core/T in GLOB.tcomms_machines)
|
||||
T.disable_machine()
|
||||
T.start_ion()
|
||||
// Bring it back sometime between 3-5 minutes. This uses deciseconds, so 1800 and 3000 respecticely.
|
||||
// Note that because this is a strict enable not a toggle, the crew or AI can re-enable the machine themselves
|
||||
addtimer(CALLBACK(T, /obj/machinery/tcomms.proc/enable_machine), rand(1800, 3000))
|
||||
// The AI cannot disable this, it must be waited for
|
||||
addtimer(CALLBACK(T, /obj/machinery/tcomms.proc/end_ion), rand(1800, 3000))
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
density = 1
|
||||
anchored = 1
|
||||
var/strength = 2 //ex_act severity number
|
||||
var/life = 2 //how many things we hit before del(src)
|
||||
var/life = 2 //how many things we hit before qdel(src)
|
||||
var/atom/goal = null
|
||||
|
||||
/obj/effect/space_dust/weak
|
||||
|
||||
@@ -493,7 +493,7 @@
|
||||
/proc/generate_static_ion_law()
|
||||
var/list/players = list()
|
||||
for(var/mob/living/carbon/human/player in GLOB.player_list)
|
||||
if( !player.mind || player.mind.assigned_role == player.mind.special_role || player.client.inactivity > MinutesToTicks(10))
|
||||
if( !player.mind || player.mind.assigned_role == player.mind.special_role || player.client.inactivity > 10 MINUTES)
|
||||
continue
|
||||
players += player.real_name
|
||||
var/random_player = "The Captain"
|
||||
|
||||
@@ -72,8 +72,8 @@
|
||||
if(istype(H.head, /obj/item/clothing/head) && affecting == "head")
|
||||
|
||||
// If their head has an armor value, assign headarmor to it, else give it 0.
|
||||
if(H.head.armor["melee"])
|
||||
headarmor = H.head.armor["melee"]
|
||||
if(H.head.armor.getRating("melee"))
|
||||
headarmor = H.head.armor.getRating("melee")
|
||||
else
|
||||
headarmor = 0
|
||||
else
|
||||
@@ -115,7 +115,7 @@
|
||||
//The reagents in the bottle splash all over the target, thanks for the idea Nodrak
|
||||
SplashReagents(target)
|
||||
|
||||
//Finally, smash the bottle. This kills (del) the bottle.
|
||||
//Finally, smash the bottle. This kills (qdel) the bottle.
|
||||
smash(target, user)
|
||||
|
||||
/obj/item/reagent_containers/food/drinks/bottle/proc/SplashReagents(mob/M)
|
||||
|
||||
@@ -278,11 +278,6 @@
|
||||
if(!UserOverride)
|
||||
add_attack_logs(user, occupant, "Gibbed in [src]", !!occupant.ckey ? ATKLOG_FEW : ATKLOG_ALL)
|
||||
|
||||
if(!iscarbon(user))
|
||||
occupant.LAssailant = null
|
||||
else
|
||||
occupant.LAssailant = user
|
||||
|
||||
else //this looks ugly but it's better than a copy-pasted startgibbing proc override
|
||||
occupant.create_attack_log("Was gibbed by <b>an autogibber (\the [src])</b>")
|
||||
add_attack_logs(src, occupant, "gibbed")
|
||||
|
||||
@@ -438,7 +438,7 @@
|
||||
overlays += I
|
||||
return
|
||||
|
||||
var/offset = Floor(20/cards.len + 1)
|
||||
var/offset = FLOOR(20/cards.len + 1, 1)
|
||||
|
||||
var/matrix/M = matrix()
|
||||
if(direction)
|
||||
|
||||
@@ -327,7 +327,7 @@
|
||||
else if(href_list["create"])
|
||||
var/amount = (text2num(href_list["amount"]))
|
||||
//Can't be outside these (if you change this keep a sane limit)
|
||||
amount = Clamp(amount, 1, 10)
|
||||
amount = clamp(amount, 1, 10)
|
||||
var/datum/design/D = locate(href_list["create"])
|
||||
create_product(D, amount)
|
||||
updateUsrDialog()
|
||||
|
||||
@@ -71,7 +71,7 @@
|
||||
|
||||
for(var/obj/item/stock_parts/micro_laser/ML in component_parts)
|
||||
var/wratemod = ML.rating * 2.5
|
||||
min_wrate = Floor(10-wratemod) // 7,5,2,0 Clamps at 0 and 10 You want this low
|
||||
min_wrate = FLOOR(10-wratemod, 1) // 7,5,2,0 Clamps at 0 and 10 You want this low
|
||||
min_wchance = 67-(ML.rating*16) // 48,35,19,3 Clamps at 0 and 67 You want this low
|
||||
for(var/obj/item/circuitboard/plantgenes/vaultcheck in component_parts)
|
||||
if(istype(vaultcheck, /obj/item/circuitboard/plantgenes/vault)) // TRAIT_DUMB BOTANY TUTS
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
for(var/datum/plant_gene/trait/T in seed.genes)
|
||||
T.on_new(src, newloc)
|
||||
seed.prepare_result(src)
|
||||
transform *= TransformUsingVariable(seed.potency, 100, 0.5) //Makes the resulting produce's sprite larger or smaller based on potency!
|
||||
transform *= TRANSFORM_USING_VARIABLE(seed.potency, 100) + 0.5 //Makes the resulting produce's sprite larger or smaller based on potency!
|
||||
add_juice()
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/grown/Destroy()
|
||||
@@ -154,12 +154,6 @@
|
||||
T.on_consume(src, usr)
|
||||
..()
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/grown/Crossed(atom/movable/AM, oldloc)
|
||||
if(seed)
|
||||
for(var/datum/plant_gene/trait/T in seed.genes)
|
||||
T.on_cross(src, AM)
|
||||
..()
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/grown/after_slip(mob/living/carbon/human/H)
|
||||
if(!seed)
|
||||
return
|
||||
@@ -190,3 +184,4 @@
|
||||
D.consume(src)
|
||||
else
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
if(istype(src, seed.product)) // no adding reagents if it is just a trash item
|
||||
seed.prepare_result(src)
|
||||
transform *= TransformUsingVariable(seed.potency, 100, 0.5)
|
||||
transform *= TRANSFORM_USING_VARIABLE(seed.potency, 100) + 0.5
|
||||
add_juice()
|
||||
|
||||
/obj/item/grown/Destroy()
|
||||
@@ -50,13 +50,6 @@
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/obj/item/grown/Crossed(atom/movable/AM, oldloc)
|
||||
if(seed)
|
||||
for(var/datum/plant_gene/trait/T in seed.genes)
|
||||
T.on_cross(src, AM)
|
||||
..()
|
||||
|
||||
/obj/item/grown/after_slip(mob/living/carbon/human/H)
|
||||
if(!seed)
|
||||
return
|
||||
|
||||
@@ -888,7 +888,7 @@
|
||||
|
||||
/obj/machinery/hydroponics/wrench_act(mob/user, obj/item/I)
|
||||
. = TRUE
|
||||
if(!I.tool_start_check(user, 0))
|
||||
if(!I.tool_start_check(src, user, 0))
|
||||
return
|
||||
if(wrenchable)
|
||||
if(using_irrigation)
|
||||
@@ -949,36 +949,36 @@
|
||||
|
||||
/// Tray Setters - The following procs adjust the tray or plants variables, and make sure that the stat doesn't go out of bounds.///
|
||||
/obj/machinery/hydroponics/proc/adjustNutri(adjustamt)
|
||||
nutrilevel = Clamp(nutrilevel + adjustamt, 0, maxnutri)
|
||||
nutrilevel = clamp(nutrilevel + adjustamt, 0, maxnutri)
|
||||
plant_hud_set_nutrient()
|
||||
|
||||
/obj/machinery/hydroponics/proc/adjustWater(adjustamt)
|
||||
waterlevel = Clamp(waterlevel + adjustamt, 0, maxwater)
|
||||
waterlevel = clamp(waterlevel + adjustamt, 0, maxwater)
|
||||
plant_hud_set_water()
|
||||
if(adjustamt>0)
|
||||
adjustToxic(-round(adjustamt/4))//Toxicity dilutation code. The more water you put in, the lesser the toxin concentration.
|
||||
|
||||
/obj/machinery/hydroponics/proc/adjustHealth(adjustamt)
|
||||
if(myseed && !dead)
|
||||
plant_health = Clamp(plant_health + adjustamt, 0, myseed.endurance)
|
||||
plant_health = clamp(plant_health + adjustamt, 0, myseed.endurance)
|
||||
plant_hud_set_health()
|
||||
|
||||
/obj/machinery/hydroponics/proc/adjustToxic(adjustamt)
|
||||
toxic = Clamp(toxic + adjustamt, 0, 100)
|
||||
toxic = clamp(toxic + adjustamt, 0, 100)
|
||||
plant_hud_set_toxin()
|
||||
|
||||
/obj/machinery/hydroponics/proc/adjustPests(adjustamt)
|
||||
pestlevel = Clamp(pestlevel + adjustamt, 0, 10)
|
||||
pestlevel = clamp(pestlevel + adjustamt, 0, 10)
|
||||
plant_hud_set_pest()
|
||||
|
||||
/obj/machinery/hydroponics/proc/adjustWeeds(adjustamt)
|
||||
weedlevel = Clamp(weedlevel + adjustamt, 0, 10)
|
||||
weedlevel = clamp(weedlevel + adjustamt, 0, 10)
|
||||
plant_hud_set_weed()
|
||||
|
||||
/obj/machinery/hydroponics/proc/spawnplant() // why would you put strange reagent in a hydro tray you monster I bet you also feed them blood
|
||||
var/list/livingplants = list(/mob/living/simple_animal/hostile/tree, /mob/living/simple_animal/hostile/killertomato)
|
||||
var/chosen = pick(livingplants)
|
||||
var/mob/living/simple_animal/hostile/C = new chosen
|
||||
var/mob/living/simple_animal/hostile/C = new chosen(get_turf(src))
|
||||
C.faction = list("plants")
|
||||
|
||||
/obj/machinery/hydroponics/proc/become_self_sufficient() // Ambrosia Gaia effect
|
||||
|
||||
@@ -175,9 +175,6 @@
|
||||
/datum/plant_gene/trait/proc/on_consume(obj/item/reagent_containers/food/snacks/grown/G, mob/living/carbon/target)
|
||||
return
|
||||
|
||||
/datum/plant_gene/trait/proc/on_cross(obj/item/reagent_containers/food/snacks/grown/G, atom/target)
|
||||
return
|
||||
|
||||
/datum/plant_gene/trait/proc/on_slip(obj/item/reagent_containers/food/snacks/grown/G, mob/living/carbon/target)
|
||||
return
|
||||
|
||||
|
||||
@@ -182,7 +182,7 @@
|
||||
/// Setters procs ///
|
||||
/obj/item/seeds/proc/adjust_yield(adjustamt)
|
||||
if(yield != -1) // Unharvestable shouldn't suddenly turn harvestable
|
||||
yield = Clamp(yield + adjustamt, 0, 10)
|
||||
yield = clamp(yield + adjustamt, 0, 10)
|
||||
|
||||
if(yield <= 0 && get_gene(/datum/plant_gene/trait/plant_type/fungal_metabolism))
|
||||
yield = 1 // Mushrooms always have a minimum yield of 1.
|
||||
@@ -191,39 +191,39 @@
|
||||
C.value = yield
|
||||
|
||||
/obj/item/seeds/proc/adjust_lifespan(adjustamt)
|
||||
lifespan = Clamp(lifespan + adjustamt, 10, 100)
|
||||
lifespan = clamp(lifespan + adjustamt, 10, 100)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/lifespan)
|
||||
if(C)
|
||||
C.value = lifespan
|
||||
|
||||
/obj/item/seeds/proc/adjust_endurance(adjustamt)
|
||||
endurance = Clamp(endurance + adjustamt, 10, 100)
|
||||
endurance = clamp(endurance + adjustamt, 10, 100)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/endurance)
|
||||
if(C)
|
||||
C.value = endurance
|
||||
|
||||
/obj/item/seeds/proc/adjust_production(adjustamt)
|
||||
if(yield != -1)
|
||||
production = Clamp(production + adjustamt, 1, 10)
|
||||
production = clamp(production + adjustamt, 1, 10)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/production)
|
||||
if(C)
|
||||
C.value = production
|
||||
|
||||
/obj/item/seeds/proc/adjust_potency(adjustamt)
|
||||
if(potency != -1)
|
||||
potency = Clamp(potency + adjustamt, 0, 100)
|
||||
potency = clamp(potency + adjustamt, 0, 100)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/potency)
|
||||
if(C)
|
||||
C.value = potency
|
||||
|
||||
/obj/item/seeds/proc/adjust_weed_rate(adjustamt)
|
||||
weed_rate = Clamp(weed_rate + adjustamt, 0, 10)
|
||||
weed_rate = clamp(weed_rate + adjustamt, 0, 10)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/weed_rate)
|
||||
if(C)
|
||||
C.value = weed_rate
|
||||
|
||||
/obj/item/seeds/proc/adjust_weed_chance(adjustamt)
|
||||
weed_chance = Clamp(weed_chance + adjustamt, 0, 67)
|
||||
weed_chance = clamp(weed_chance + adjustamt, 0, 67)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/weed_chance)
|
||||
if(C)
|
||||
C.value = weed_chance
|
||||
@@ -232,7 +232,7 @@
|
||||
|
||||
/obj/item/seeds/proc/set_yield(adjustamt)
|
||||
if(yield != -1) // Unharvestable shouldn't suddenly turn harvestable
|
||||
yield = Clamp(adjustamt, 0, 10)
|
||||
yield = clamp(adjustamt, 0, 10)
|
||||
|
||||
if(yield <= 0 && get_gene(/datum/plant_gene/trait/plant_type/fungal_metabolism))
|
||||
yield = 1 // Mushrooms always have a minimum yield of 1.
|
||||
@@ -241,39 +241,39 @@
|
||||
C.value = yield
|
||||
|
||||
/obj/item/seeds/proc/set_lifespan(adjustamt)
|
||||
lifespan = Clamp(adjustamt, 10, 100)
|
||||
lifespan = clamp(adjustamt, 10, 100)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/lifespan)
|
||||
if(C)
|
||||
C.value = lifespan
|
||||
|
||||
/obj/item/seeds/proc/set_endurance(adjustamt)
|
||||
endurance = Clamp(adjustamt, 10, 100)
|
||||
endurance = clamp(adjustamt, 10, 100)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/endurance)
|
||||
if(C)
|
||||
C.value = endurance
|
||||
|
||||
/obj/item/seeds/proc/set_production(adjustamt)
|
||||
if(yield != -1)
|
||||
production = Clamp(adjustamt, 1, 10)
|
||||
production = clamp(adjustamt, 1, 10)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/production)
|
||||
if(C)
|
||||
C.value = production
|
||||
|
||||
/obj/item/seeds/proc/set_potency(adjustamt)
|
||||
if(potency != -1)
|
||||
potency = Clamp(adjustamt, 0, 100)
|
||||
potency = clamp(adjustamt, 0, 100)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/potency)
|
||||
if(C)
|
||||
C.value = potency
|
||||
|
||||
/obj/item/seeds/proc/set_weed_rate(adjustamt)
|
||||
weed_rate = Clamp(adjustamt, 0, 10)
|
||||
weed_rate = clamp(adjustamt, 0, 10)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/weed_rate)
|
||||
if(C)
|
||||
C.value = weed_rate
|
||||
|
||||
/obj/item/seeds/proc/set_weed_chance(adjustamt)
|
||||
weed_chance = Clamp(adjustamt, 0, 67)
|
||||
weed_chance = clamp(adjustamt, 0, 67)
|
||||
var/datum/plant_gene/core/C = get_gene(/datum/plant_gene/core/weed_chance)
|
||||
if(C)
|
||||
C.value = weed_chance
|
||||
|
||||
@@ -95,7 +95,7 @@
|
||||
dat += "<font color=red><b>ERROR</b>: Unable to contact External Archive. Please contact your system administrator for assistance.</font>"
|
||||
else
|
||||
num_results = src.get_num_results()
|
||||
num_pages = Ceiling(num_results/LIBRARY_BOOKS_PER_PAGE)
|
||||
num_pages = CEILING(num_results/LIBRARY_BOOKS_PER_PAGE, 1)
|
||||
dat += {"<ul>
|
||||
<li><A href='?src=[UID()];id=-1'>(Order book by SS<sup>13</sup>BN)</A></li>
|
||||
</ul>"}
|
||||
@@ -207,7 +207,7 @@
|
||||
var/obj/item/barcodescanner/scanner = W
|
||||
scanner.computer = src
|
||||
to_chat(user, "[scanner]'s associated machine has been set to [src].")
|
||||
audible_message("[src] lets out a low, short blip.", 2)
|
||||
audible_message("[src] lets out a low, short blip.", hearing_distance = 2)
|
||||
return 1
|
||||
else
|
||||
return ..()
|
||||
@@ -224,13 +224,13 @@
|
||||
else
|
||||
var/pn = text2num(href_list["pagenum"])
|
||||
if(!isnull(pn))
|
||||
page_num = Clamp(pn, 1, num_pages)
|
||||
page_num = clamp(pn, 1, num_pages)
|
||||
|
||||
if(href_list["page"])
|
||||
if(num_pages == 0)
|
||||
page_num = 1
|
||||
else
|
||||
page_num = Clamp(text2num(href_list["page"]), 1, num_pages)
|
||||
page_num = clamp(text2num(href_list["page"]), 1, num_pages)
|
||||
if(href_list["settitle"])
|
||||
var/newtitle = input("Enter a title to search for:") as text|null
|
||||
if(newtitle)
|
||||
@@ -252,7 +252,7 @@
|
||||
|
||||
if(href_list["search"])
|
||||
num_results = src.get_num_results()
|
||||
num_pages = Ceiling(num_results/LIBRARY_BOOKS_PER_PAGE)
|
||||
num_pages = CEILING(num_results/LIBRARY_BOOKS_PER_PAGE, 1)
|
||||
page_num = 1
|
||||
|
||||
screenstate = 4
|
||||
@@ -413,7 +413,7 @@
|
||||
return
|
||||
|
||||
if(bibledelay)
|
||||
audible_message("<b>[src]</b>'s monitor flashes, \"Printer unavailable. Please allow a short time before attempting to print.\"")
|
||||
visible_message("<b>[src]</b>'s monitor flashes, \"Printer unavailable. Please allow a short time before attempting to print.\"")
|
||||
else
|
||||
bibledelay = 1
|
||||
spawn(60)
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
else
|
||||
var/pn = text2num(href_list["pagenum"])
|
||||
if(!isnull(pn))
|
||||
page_num = Clamp(pn, 1, num_pages)
|
||||
page_num = clamp(pn, 1, num_pages)
|
||||
|
||||
if(href_list["settitle"])
|
||||
var/newtitle = input("Enter a title to search for:") as text|null
|
||||
@@ -100,11 +100,11 @@
|
||||
if(num_pages == 0)
|
||||
page_num = 1
|
||||
else
|
||||
page_num = Clamp(text2num(href_list["page"]), 1, num_pages)
|
||||
page_num = clamp(text2num(href_list["page"]), 1, num_pages)
|
||||
|
||||
if(href_list["search"])
|
||||
num_results = src.get_num_results()
|
||||
num_pages = Ceiling(num_results/LIBRARY_BOOKS_PER_PAGE)
|
||||
num_pages = CEILING(num_results/LIBRARY_BOOKS_PER_PAGE, 1)
|
||||
page_num = 1
|
||||
|
||||
screenstate = 1
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
if(!light_power || !light_range) // We won't emit light anyways, destroy the light source.
|
||||
QDEL_NULL(light)
|
||||
else
|
||||
if(!ismovableatom(loc)) // We choose what atom should be the top atom of the light here.
|
||||
if(!ismovable(loc)) // We choose what atom should be the top atom of the light here.
|
||||
. = src
|
||||
else
|
||||
. = loc
|
||||
|
||||
@@ -220,13 +220,14 @@
|
||||
var/oldlum = source_turf.luminosity
|
||||
source_turf.luminosity = CEILING(light_range, 1)
|
||||
for(T in view(CEILING(light_range, 1), source_turf))
|
||||
if((!IS_DYNAMIC_LIGHTING(T) && !T.light_sources) || T.has_opaque_atom)
|
||||
if((!IS_DYNAMIC_LIGHTING(T) && !T.light_sources))
|
||||
continue
|
||||
if(!T.lighting_corners_initialised)
|
||||
T.generate_missing_corners()
|
||||
for(thing in T.corners)
|
||||
C = thing
|
||||
corners[C] = 0
|
||||
if(!T.has_opaque_atom)
|
||||
if(!T.lighting_corners_initialised)
|
||||
T.generate_missing_corners()
|
||||
for(thing in T.corners)
|
||||
C = thing
|
||||
corners[C] = 0
|
||||
turfs += T
|
||||
source_turf.luminosity = oldlum
|
||||
|
||||
|
||||
@@ -195,6 +195,9 @@
|
||||
icon = 'icons/obj/library.dmi'
|
||||
icon_state = "cqcmanual"
|
||||
|
||||
/obj/item/CQC_manual/chef
|
||||
desc = "A small, black manual. Written on the back it says: Bringing the home advantage with you."
|
||||
|
||||
/obj/item/CQC_manual/attack_self(mob/living/carbon/human/user)
|
||||
if(!istype(user) || !user)
|
||||
return
|
||||
|
||||
@@ -81,7 +81,7 @@
|
||||
var/mob/dead/observer/current_spirits = list()
|
||||
|
||||
for(var/mob/dead/observer/O in GLOB.player_list)
|
||||
if((O.following in contents))
|
||||
if((O.orbiting in contents))
|
||||
ghost_counter++
|
||||
O.invisibility = 0
|
||||
current_spirits |= O
|
||||
@@ -97,13 +97,13 @@
|
||||
force = 0
|
||||
var/ghost_counter = ghost_check()
|
||||
|
||||
force = Clamp((ghost_counter * 4), 0, 75)
|
||||
force = clamp((ghost_counter * 4), 0, 75)
|
||||
user.visible_message("<span class='danger'>[user] strikes with the force of [ghost_counter] vengeful spirits!</span>")
|
||||
..()
|
||||
|
||||
/obj/item/melee/ghost_sword/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
|
||||
var/ghost_counter = ghost_check()
|
||||
final_block_chance += Clamp((ghost_counter * 5), 0, 75)
|
||||
final_block_chance += clamp((ghost_counter * 5), 0, 75)
|
||||
owner.visible_message("<span class='danger'>[owner] is protected by a ring of [ghost_counter] ghosts!</span>")
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
blast_range = initial(blast_range)
|
||||
if(isliving(user))
|
||||
var/mob/living/L = user
|
||||
var/health_percent = L.health / L.maxHealth
|
||||
var/health_percent = max(L.health / L.maxHealth, 0) // Don't go negative
|
||||
chaser_cooldown += round(health_percent * 20) //two tenths of a second for each missing 10% of health
|
||||
cooldown_time += round(health_percent * 10) //one tenth of a second for each missing 10% of health
|
||||
chaser_speed = max(chaser_speed + health_percent, 0.5) //one tenth of a second faster for each missing 10% of health
|
||||
|
||||
@@ -221,7 +221,7 @@
|
||||
. = TRUE
|
||||
if(!powered())
|
||||
return
|
||||
if(!I.tool_start_check(user, 0))
|
||||
if(!I.tool_start_check(src, user, 0))
|
||||
return
|
||||
input_dir = turn(input_dir, -90)
|
||||
output_dir = turn(output_dir, -90)
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
if(user.a_intent != INTENT_HELP)
|
||||
return
|
||||
. = TRUE
|
||||
if(!I.tool_start_check(user, 0))
|
||||
if(!I.tool_start_check(src, user, 0))
|
||||
return
|
||||
I.melee_attack_chain(user, stored_gun)
|
||||
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
if(materials.materials[href_list["choose"]])
|
||||
chosen = href_list["choose"]
|
||||
if(href_list["chooseAmt"])
|
||||
coinsToProduce = Clamp(coinsToProduce + text2num(href_list["chooseAmt"]), 0, 1000)
|
||||
coinsToProduce = clamp(coinsToProduce + text2num(href_list["chooseAmt"]), 0, 1000)
|
||||
if(href_list["makeCoins"])
|
||||
var/temp_coins = coinsToProduce
|
||||
processing = TRUE
|
||||
|
||||
@@ -23,7 +23,6 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
|
||||
//If you died in the game and are a ghsot - this will remain as null.
|
||||
//Note that this is not a reliable way to determine if admins started as observers, since they change mobs a lot.
|
||||
universal_speak = TRUE
|
||||
var/atom/movable/following = null
|
||||
var/image/ghostimage = null //this mobs ghost image, for deleting and stuff
|
||||
var/ghostvision = TRUE //is the ghost able to see things humans can't?
|
||||
var/seedarkness = TRUE
|
||||
@@ -230,7 +229,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
|
||||
/mob/dead/observer/Move(NewLoc, direct)
|
||||
update_parallax_contents()
|
||||
following = null
|
||||
setDir(direct)
|
||||
ghostimage.setDir(dir)
|
||||
|
||||
@@ -412,7 +410,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
|
||||
forceMove(pick(L))
|
||||
update_parallax_contents()
|
||||
following = null
|
||||
|
||||
/mob/dead/observer/verb/follow()
|
||||
set category = "Ghost"
|
||||
@@ -424,7 +421,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
A.on_close(CALLBACK(src, .proc/ManualFollow))
|
||||
|
||||
// This is the ghost's follow verb with an argument
|
||||
/mob/dead/observer/proc/ManualFollow(var/atom/movable/target)
|
||||
/mob/dead/observer/proc/ManualFollow(atom/movable/target)
|
||||
if(!target || !isobserver(usr))
|
||||
return
|
||||
|
||||
@@ -432,7 +429,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
return
|
||||
|
||||
if(target != src)
|
||||
if(following && following == target)
|
||||
if(orbiting && orbiting == target)
|
||||
return
|
||||
|
||||
var/icon/I = icon(target.icon,target.icon_state,target.dir)
|
||||
@@ -458,7 +455,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
else //Circular
|
||||
rot_seg = 36 //360/10 bby, smooth enough aproximation of a circle
|
||||
|
||||
following = target
|
||||
to_chat(src, "<span class='notice'>Now following [target]</span>")
|
||||
orbit(target,orbitsize, FALSE, 20, rot_seg)
|
||||
|
||||
@@ -485,7 +481,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
if(T && isturf(T)) //Make sure the turf exists, then move the source to that destination.
|
||||
A.forceMove(T)
|
||||
M.update_parallax_contents()
|
||||
following = null
|
||||
return
|
||||
to_chat(A, "This mob is not located in the game world.")
|
||||
|
||||
@@ -642,7 +637,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
if(!client)
|
||||
return
|
||||
forceMove(T)
|
||||
following = null
|
||||
|
||||
if(href_list["reenter"])
|
||||
reenter_corpse()
|
||||
|
||||
@@ -135,7 +135,7 @@
|
||||
|
||||
if(message)
|
||||
for(var/mob/M in GLOB.player_list)
|
||||
if(istype(M, /mob/new_player))
|
||||
if(isnewplayer(M))
|
||||
continue
|
||||
|
||||
if(check_rights(R_ADMIN|R_MOD, 0, M) && M.get_preference(CHAT_DEAD)) // Show the emote to admins/mods
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
|
||||
for(var/i = 0;i<name_count;i++)
|
||||
new_name = ""
|
||||
for(var/x = rand(Floor(syllable_count/2),syllable_count);x>0;x--)
|
||||
for(var/x = rand(FLOOR(syllable_count/2, 1),syllable_count);x>0;x--)
|
||||
new_name += pick(syllables)
|
||||
full_name += " [capitalize(lowertext(new_name))]"
|
||||
|
||||
@@ -767,17 +767,6 @@
|
||||
desc = "Bark bark bark."
|
||||
key = "vu"
|
||||
|
||||
/datum/language/zombie
|
||||
name = "Zombie"
|
||||
desc = "BRAAAAAAINS!"
|
||||
speech_verb = "moans"
|
||||
whisper_verb = "mutters"
|
||||
exclaim_verb = "wails"
|
||||
colour = "zombie"
|
||||
key = "zom"
|
||||
flags = RESTRICTED
|
||||
syllables = list("BRAAAAAAAAAAAAAAAAINS", "BRAAINS", "BRAINS")
|
||||
|
||||
/mob/proc/grant_all_babel_languages()
|
||||
for(var/la in GLOB.all_languages)
|
||||
var/datum/language/new_language = GLOB.all_languages[la]
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
name = "alien"
|
||||
voice_name = "alien"
|
||||
speak_emote = list("hisses")
|
||||
bubble_icon = "alien"
|
||||
icon = 'icons/mob/alien.dmi'
|
||||
gender = NEUTER
|
||||
dna = null
|
||||
@@ -226,7 +227,7 @@ Des: Removes all infected images from the alien.
|
||||
|
||||
/mob/living/carbon/alien/handle_footstep(turf/T)
|
||||
if(..())
|
||||
if(T.footstep_sounds["xeno"])
|
||||
if(T.footstep_sounds && T.footstep_sounds["xeno"])
|
||||
var/S = pick(T.footstep_sounds["xeno"])
|
||||
if(S)
|
||||
if(m_intent == MOVE_INTENT_RUN)
|
||||
|
||||
@@ -136,14 +136,11 @@ Doesn't work on other aliens/AI.*/
|
||||
set category = "Alien"
|
||||
|
||||
if(powerc())
|
||||
if(stomach_contents.len)
|
||||
if(LAZYLEN(stomach_contents))
|
||||
for(var/mob/M in src)
|
||||
if(M in stomach_contents)
|
||||
stomach_contents.Remove(M)
|
||||
M.forceMove(loc)
|
||||
//Paralyse(10)
|
||||
src.visible_message("<span class='alertalien'><B>[src] hurls out the contents of [p_their()] stomach!</span>")
|
||||
return
|
||||
LAZYREMOVE(stomach_contents, M)
|
||||
M.forceMove(drop_location())
|
||||
visible_message("<span class='alertalien'><B>[src] hurls out the contents of [p_their()] stomach!</span>")
|
||||
|
||||
/mob/living/carbon/proc/getPlasma()
|
||||
var/obj/item/organ/internal/xenos/plasmavessel/vessel = get_int_organ(/obj/item/organ/internal/xenos/plasmavessel)
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
icon_state = "alienq_s"
|
||||
status_flags = CANPARALYSE
|
||||
mob_size = MOB_SIZE_LARGE
|
||||
bubble_icon = "alienroyal"
|
||||
large = 1
|
||||
ventcrawler = 0
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
playsound(loc, 'sound/weapons/punchmiss.ogg', 25, 1, -1)
|
||||
visible_message("<span class='danger'>[M] has attempted to disarm [src]!</span>")
|
||||
|
||||
/mob/living/carbon/alien/humanoid/do_attack_animation(atom/A, visual_effect_icon, obj/item/used_item, no_effect, end_pixel_y)
|
||||
/mob/living/carbon/alien/humanoid/do_attack_animation(atom/A, visual_effect_icon, obj/item/used_item, no_effect)
|
||||
if(!no_effect && !visual_effect_icon)
|
||||
visual_effect_icon = ATTACK_EFFECT_CLAW
|
||||
..()
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
step_away(src, user, 15)
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/alien/larva/do_attack_animation(atom/A, visual_effect_icon, obj/item/used_item, no_effect, end_pixel_y)
|
||||
/mob/living/carbon/alien/larva/do_attack_animation(atom/A, visual_effect_icon, obj/item/used_item, no_effect)
|
||||
if(!no_effect && !visual_effect_icon)
|
||||
visual_effect_icon = ATTACK_EFFECT_BITE
|
||||
..()
|
||||
|
||||
@@ -2,6 +2,10 @@
|
||||
var/canEnterVentWith = "/obj/item/implant=0&/obj/item/clothing/mask/facehugger=0&/obj/item/radio/borg=0&/obj/machinery/camera=0"
|
||||
var/datum/middleClickOverride/middleClickOverride = null
|
||||
|
||||
/mob/living/carbon/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.carbon_list += src
|
||||
|
||||
/mob/living/carbon/Destroy()
|
||||
// This clause is here due to items falling off from limb deletion
|
||||
for(var/obj/item in get_all_slots())
|
||||
@@ -14,11 +18,11 @@
|
||||
if(B)
|
||||
B.leave_host()
|
||||
qdel(B)
|
||||
GLOB.carbon_list -= src
|
||||
return ..()
|
||||
|
||||
/mob/living/carbon/handle_atom_del(atom/A)
|
||||
if(A in processing_patches)
|
||||
processing_patches -= A
|
||||
LAZYREMOVE(processing_patches, A)
|
||||
return ..()
|
||||
|
||||
/mob/living/carbon/blob_act(obj/structure/blob/B)
|
||||
@@ -46,41 +50,40 @@
|
||||
|
||||
/mob/living/carbon/var/last_stomach_attack //defining this here because no one would look in carbon_defines for it
|
||||
|
||||
/mob/living/carbon/relaymove(var/mob/user, direction)
|
||||
if(user in src.stomach_contents)
|
||||
if(last_stomach_attack + STOMACH_ATTACK_DELAY > world.time) return
|
||||
/mob/living/carbon/relaymove(mob/user, direction)
|
||||
if(LAZYLEN(stomach_contents))
|
||||
if(user in stomach_contents)
|
||||
if(last_stomach_attack + STOMACH_ATTACK_DELAY > world.time)
|
||||
return
|
||||
|
||||
last_stomach_attack = world.time
|
||||
for(var/mob/M in hearers(4, src))
|
||||
if(M.client)
|
||||
M.show_message(text("<span class='warning'>You hear something rumbling inside [src]'s stomach...</span>"), 2)
|
||||
|
||||
var/obj/item/I = user.get_active_hand()
|
||||
if(I && I.force)
|
||||
var/d = rand(round(I.force / 4), I.force)
|
||||
|
||||
if(istype(src, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = src
|
||||
var/obj/item/organ/external/organ = H.get_organ("chest")
|
||||
if(istype(organ))
|
||||
if(organ.receive_damage(d, 0))
|
||||
H.UpdateDamageIcon()
|
||||
|
||||
H.updatehealth("stomach attack")
|
||||
|
||||
else
|
||||
src.take_organ_damage(d)
|
||||
|
||||
for(var/mob/M in viewers(user, null))
|
||||
last_stomach_attack = world.time
|
||||
for(var/mob/M in hearers(4, src))
|
||||
if(M.client)
|
||||
M.show_message(text("<span class='warning'><B>[user] attacks [src]'s stomach wall with the [I.name]!</span>"), 2)
|
||||
playsound(user.loc, 'sound/effects/attackblob.ogg', 50, 1)
|
||||
M.show_message(text("<span class='warning'>You hear something rumbling inside [src]'s stomach...</span>"), 2)
|
||||
|
||||
if(prob(src.getBruteLoss() - 50))
|
||||
for(var/atom/movable/A in stomach_contents)
|
||||
A.forceMove(drop_location())
|
||||
stomach_contents.Remove(A)
|
||||
src.gib()
|
||||
var/obj/item/I = user.get_active_hand()
|
||||
if(I && I.force)
|
||||
var/d = rand(round(I.force / 4), I.force)
|
||||
|
||||
if(istype(src, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = src
|
||||
var/obj/item/organ/external/organ = H.get_organ("chest")
|
||||
if(istype(organ))
|
||||
if(organ.receive_damage(d, 0))
|
||||
H.UpdateDamageIcon()
|
||||
|
||||
H.updatehealth("stomach attack")
|
||||
|
||||
else
|
||||
take_organ_damage(d)
|
||||
|
||||
for(var/mob/M in viewers(user, null))
|
||||
if(M.client)
|
||||
M.show_message(text("<span class='warning'><B>[user] attacks [src]'s stomach wall with the [I.name]!</span>"), 2)
|
||||
playsound(user.loc, 'sound/effects/attackblob.ogg', 50, 1)
|
||||
|
||||
if(prob(getBruteLoss() - 50))
|
||||
gib()
|
||||
|
||||
#undef STOMACH_ATTACK_DELAY
|
||||
|
||||
@@ -135,9 +138,8 @@
|
||||
I.throw_at(get_edge_target_turf(src,pick(GLOB.alldirs)),rand(1,3),5)
|
||||
|
||||
for(var/mob/M in src)
|
||||
if(M in src.stomach_contents)
|
||||
src.stomach_contents.Remove(M)
|
||||
M.forceMove(get_turf(src))
|
||||
LAZYREMOVE(stomach_contents, M)
|
||||
M.forceMove(drop_location())
|
||||
visible_message("<span class='danger'>[M] bursts out of [src]!</span>")
|
||||
|
||||
/mob/living/carbon/electrocute_act(shock_damage, obj/source, siemens_coeff = 1, safety = FALSE, override = FALSE, tesla_shock = FALSE, illusion = FALSE, stun = TRUE)
|
||||
@@ -1064,10 +1066,6 @@ GLOBAL_LIST_INIT(ventcrawl_machinery, list(/obj/machinery/atmospherics/unary/ven
|
||||
|
||||
/mob/living/carbon/proc/forceFedAttackLog(var/obj/item/reagent_containers/food/toEat, mob/user)
|
||||
add_attack_logs(user, src, "Fed [toEat]. Reagents: [toEat.reagents.log_list(toEat)]", toEat.reagents.harmless_helper() ? ATKLOG_ALMOSTALL : null)
|
||||
if(!iscarbon(user))
|
||||
LAssailant = null
|
||||
else
|
||||
LAssailant = user
|
||||
|
||||
|
||||
/*TO DO - If/when stomach organs are introduced, override this at the human level sending the item to the stomach
|
||||
@@ -1200,3 +1198,18 @@ so that different stomachs can handle things in different ways VB*/
|
||||
I.acid_level = 0 //washes off the acid on our clothes
|
||||
I.extinguish() //extinguishes our clothes
|
||||
..()
|
||||
|
||||
/mob/living/carbon/clean_blood(clean_hands = TRUE, clean_mask = TRUE, clean_feet = TRUE)
|
||||
if(head)
|
||||
if(head.clean_blood())
|
||||
update_inv_head()
|
||||
if(head.flags_inv & HIDEMASK)
|
||||
clean_mask = FALSE
|
||||
if(wear_suit)
|
||||
if(wear_suit.clean_blood())
|
||||
update_inv_wear_suit()
|
||||
if(wear_suit.flags_inv & HIDESHOES)
|
||||
clean_feet = FALSE
|
||||
if(wear_suit.flags_inv & HIDEGLOVES)
|
||||
clean_hands = FALSE
|
||||
..(clean_hands, clean_mask, clean_feet)
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
visible_message("<span class='warning'>[src] catches [AM]!</span>")
|
||||
throw_mode_off()
|
||||
return TRUE
|
||||
..()
|
||||
return ..()
|
||||
|
||||
/mob/living/carbon/water_act(volume, temperature, source, method = REAGENT_TOUCH)
|
||||
. = ..()
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
/mob/living/carbon
|
||||
gender = MALE
|
||||
pressure_resistance = 15
|
||||
var/list/stomach_contents = list()
|
||||
var/list/processing_patches = list()
|
||||
var/list/stomach_contents
|
||||
var/list/processing_patches
|
||||
var/list/internal_organs = list()
|
||||
var/list/internal_organs_slot = list() //Same as above, but stores "slot ID" - "organ" pairs for easy access.
|
||||
var/antibodies = 0
|
||||
|
||||
var/life_tick = 0 // The amount of life ticks that have processed on this mob.
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
canmove = 0
|
||||
icon = null
|
||||
invisibility = 101
|
||||
if(!isSynthetic())
|
||||
if(!ismachineperson(src))
|
||||
animation = new(loc)
|
||||
animation.icon_state = "blank"
|
||||
animation.icon = 'icons/mob/mob.dmi'
|
||||
@@ -32,12 +32,11 @@
|
||||
E.droplimb(DROPLIMB_SHARP)
|
||||
|
||||
for(var/mob/M in src)
|
||||
if(M in stomach_contents)
|
||||
stomach_contents.Remove(M)
|
||||
M.forceMove(get_turf(src))
|
||||
LAZYREMOVE(stomach_contents, M)
|
||||
M.forceMove(drop_location())
|
||||
visible_message("<span class='danger'>[M] bursts out of [src]!</span>")
|
||||
|
||||
if(!isSynthetic())
|
||||
if(!ismachineperson(src))
|
||||
flick("gibbed-h", animation)
|
||||
hgibs(loc, dna)
|
||||
else
|
||||
@@ -106,11 +105,6 @@
|
||||
//Handle species-specific deaths.
|
||||
dna.species.handle_death(gibbed, src)
|
||||
|
||||
if(ishuman(LAssailant))
|
||||
var/mob/living/carbon/human/H=LAssailant
|
||||
if(H.mind)
|
||||
H.mind.kills += "[key_name(src)]"
|
||||
|
||||
if(SSticker && SSticker.mode)
|
||||
// log_world("k")
|
||||
sql_report_death(src)
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
//Cooldown-inducing emotes
|
||||
if("ping", "pings", "buzz", "buzzes", "beep", "beeps", "yes", "no", "buzz2")
|
||||
var/found_machine_head = FALSE
|
||||
if(ismachine(src)) //Only Machines can beep, ping, and buzz, yes, no, and make a silly sad trombone noise.
|
||||
if(ismachineperson(src)) //Only Machines can beep, ping, and buzz, yes, no, and make a silly sad trombone noise.
|
||||
on_CD = handle_emote_CD() //proc located in code\modules\mob\emote.dm
|
||||
found_machine_head = TRUE
|
||||
else
|
||||
@@ -139,10 +139,18 @@
|
||||
//WHO THE FUCK THOUGHT THAT WAS A GOOD FUCKING IDEA!?!?
|
||||
|
||||
if("howl", "howls")
|
||||
var/M = handle_emote_param(param) //Check to see if the param is valid (mob with the param name is in view).
|
||||
message = "<B>[src]</B> howls[M ? " at [M]" : ""]!"
|
||||
playsound(loc, 'sound/goonstation/voice/howl.ogg', 100, 1, 10, frequency = get_age_pitch())
|
||||
m_type = 2
|
||||
var/M = handle_emote_param(param)
|
||||
if(miming)
|
||||
message = "<B>[src]</B> acts out a howl[M ? " at [M]" : ""]!"
|
||||
m_type = 1
|
||||
else
|
||||
if(!muzzled)
|
||||
message = "<B>[src]</B> howls[M ? " at [M]" : ""]!"
|
||||
playsound(loc, 'sound/goonstation/voice/howl.ogg', 100, 1, 10, frequency = get_age_pitch())
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a very loud noise[M ? " at [M]" : ""]."
|
||||
m_type = 2
|
||||
|
||||
if("growl", "growls")
|
||||
var/M = handle_emote_param(param)
|
||||
@@ -939,7 +947,7 @@
|
||||
if("Skrell")
|
||||
emotelist += "\nSkrell specific emotes :- warble(s)"
|
||||
|
||||
if(ismachine(src))
|
||||
if(ismachineperson(src))
|
||||
emotelist += "\nMachine specific emotes :- beep(s)-(none)/mob, buzz(es)-none/mob, no-(none)/mob, ping(s)-(none)/mob, yes-(none)/mob, buzz2-(none)/mob"
|
||||
else
|
||||
var/obj/item/organ/external/head/H = get_organ("head") // If you have a robotic head, you can make beep-boop noises
|
||||
|
||||
@@ -208,7 +208,7 @@
|
||||
if(!E)
|
||||
wound_flavor_text["[organ_tag]"] = "<B>[p_they(TRUE)] [p_are()] missing [p_their()] [organ_descriptor].</B>\n"
|
||||
else
|
||||
if(!isSynthetic())
|
||||
if(!ismachineperson(src))
|
||||
if(E.is_robotic())
|
||||
wound_flavor_text["[E.limb_name]"] = "[p_they(TRUE)] [p_have()] a robotic [E.name]!\n"
|
||||
|
||||
@@ -252,7 +252,7 @@
|
||||
var/temp = getBruteLoss() //no need to calculate each of these twice
|
||||
|
||||
if(temp)
|
||||
var/brute_message = !isSynthetic() ? "bruising" : "denting"
|
||||
var/brute_message = !ismachineperson(src) ? "bruising" : "denting"
|
||||
if(temp < 30)
|
||||
msg += "[p_they(TRUE)] [p_have()] minor [brute_message ].\n"
|
||||
else
|
||||
@@ -301,13 +301,13 @@
|
||||
else if(nutrition >= NUTRITION_LEVEL_FAT)
|
||||
msg += "[p_they(TRUE)] [p_are()] quite chubby.\n"
|
||||
|
||||
if(!isSynthetic() && blood_volume < BLOOD_VOLUME_SAFE)
|
||||
if(!ismachineperson(src) && blood_volume < BLOOD_VOLUME_SAFE)
|
||||
msg += "[p_they(TRUE)] [p_have()] pale skin.\n"
|
||||
|
||||
if(bleedsuppress)
|
||||
msg += "[p_they(TRUE)] [p_are()] bandaged with something.\n"
|
||||
else if(bleed_rate)
|
||||
var/bleed_message = !isSynthetic() ? "bleeding" : "leaking"
|
||||
var/bleed_message = !ismachineperson(src) ? "bleeding" : "leaking"
|
||||
msg += "<B>[p_they(TRUE)] [p_are()] [bleed_message]!</B>\n"
|
||||
|
||||
if(reagents.has_reagent("teslium"))
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
dna = new /datum/dna(null)
|
||||
// Species name is handled by set_species()
|
||||
|
||||
..()
|
||||
. = ..()
|
||||
|
||||
set_species(new_species, 1, delay_icon_update = 1, skip_same_check = TRUE)
|
||||
|
||||
@@ -41,6 +41,7 @@
|
||||
sync_organ_dna(1)
|
||||
|
||||
UpdateAppearance()
|
||||
GLOB.human_list += src
|
||||
|
||||
/mob/living/carbon/human/OpenCraftingMenu()
|
||||
handcrafting.ui_interact(src)
|
||||
@@ -60,61 +61,62 @@
|
||||
SSmobs.cubemonkeys -= src
|
||||
QDEL_LIST(bodyparts)
|
||||
splinted_limbs.Cut()
|
||||
GLOB.human_list -= src
|
||||
|
||||
/mob/living/carbon/human/dummy
|
||||
real_name = "Test Dummy"
|
||||
status_flags = GODMODE|CANPUSH
|
||||
|
||||
/mob/living/carbon/human/skrell/Initialize(mapload)
|
||||
..(mapload, /datum/species/skrell)
|
||||
. = ..(mapload, /datum/species/skrell)
|
||||
|
||||
/mob/living/carbon/human/tajaran/Initialize(mapload)
|
||||
..(mapload, /datum/species/tajaran)
|
||||
. = ..(mapload, /datum/species/tajaran)
|
||||
|
||||
/mob/living/carbon/human/vulpkanin/Initialize(mapload)
|
||||
..(mapload, /datum/species/vulpkanin)
|
||||
. = ..(mapload, /datum/species/vulpkanin)
|
||||
|
||||
/mob/living/carbon/human/unathi/Initialize(mapload)
|
||||
..(mapload, /datum/species/unathi)
|
||||
. = ..(mapload, /datum/species/unathi)
|
||||
|
||||
/mob/living/carbon/human/vox/Initialize(mapload)
|
||||
..(mapload, /datum/species/vox)
|
||||
. = ..(mapload, /datum/species/vox)
|
||||
|
||||
/mob/living/carbon/human/voxarmalis/Initialize(mapload)
|
||||
..(mapload, /datum/species/vox/armalis)
|
||||
. = ..(mapload, /datum/species/vox/armalis)
|
||||
|
||||
/mob/living/carbon/human/skeleton/Initialize(mapload)
|
||||
..(mapload, /datum/species/skeleton)
|
||||
. = ..(mapload, /datum/species/skeleton)
|
||||
|
||||
/mob/living/carbon/human/kidan/Initialize(mapload)
|
||||
..(mapload, /datum/species/kidan)
|
||||
. = ..(mapload, /datum/species/kidan)
|
||||
|
||||
/mob/living/carbon/human/plasma/Initialize(mapload)
|
||||
..(mapload, /datum/species/plasmaman)
|
||||
. = ..(mapload, /datum/species/plasmaman)
|
||||
|
||||
/mob/living/carbon/human/slime/Initialize(mapload)
|
||||
..(mapload, /datum/species/slime)
|
||||
. = ..(mapload, /datum/species/slime)
|
||||
|
||||
/mob/living/carbon/human/grey/Initialize(mapload)
|
||||
..(mapload, /datum/species/grey)
|
||||
. = ..(mapload, /datum/species/grey)
|
||||
|
||||
/mob/living/carbon/human/abductor/Initialize(mapload)
|
||||
..(mapload, /datum/species/abductor)
|
||||
. = ..(mapload, /datum/species/abductor)
|
||||
|
||||
/mob/living/carbon/human/diona/Initialize(mapload)
|
||||
..(mapload, /datum/species/diona)
|
||||
. = ..(mapload, /datum/species/diona)
|
||||
|
||||
/mob/living/carbon/human/pod_diona/Initialize(mapload)
|
||||
..(mapload, /datum/species/diona/pod)
|
||||
. = ..(mapload, /datum/species/diona/pod)
|
||||
|
||||
/mob/living/carbon/human/machine/Initialize(mapload)
|
||||
..(mapload, /datum/species/machine)
|
||||
. = ..(mapload, /datum/species/machine)
|
||||
|
||||
/mob/living/carbon/human/machine/created
|
||||
name = "Integrated Robotic Chassis"
|
||||
|
||||
/mob/living/carbon/human/machine/created/Initialize(mapload)
|
||||
..()
|
||||
. = ..()
|
||||
rename_character(null, "Integrated Robotic Chassis ([rand(1, 9999)])")
|
||||
update_dna()
|
||||
for(var/obj/item/organ/external/E in bodyparts)
|
||||
@@ -127,34 +129,34 @@
|
||||
death()
|
||||
|
||||
/mob/living/carbon/human/shadow/Initialize(mapload)
|
||||
..(mapload, /datum/species/shadow)
|
||||
. = ..(mapload, /datum/species/shadow)
|
||||
|
||||
/mob/living/carbon/human/golem/Initialize(mapload)
|
||||
..(mapload, /datum/species/golem)
|
||||
. = ..(mapload, /datum/species/golem)
|
||||
|
||||
/mob/living/carbon/human/wryn/Initialize(mapload)
|
||||
..(mapload, /datum/species/wryn)
|
||||
. = ..(mapload, /datum/species/wryn)
|
||||
|
||||
/mob/living/carbon/human/nucleation/Initialize(mapload)
|
||||
..(mapload, /datum/species/nucleation)
|
||||
. = ..(mapload, /datum/species/nucleation)
|
||||
|
||||
/mob/living/carbon/human/drask/Initialize(mapload)
|
||||
..(mapload, /datum/species/drask)
|
||||
. = ..(mapload, /datum/species/drask)
|
||||
|
||||
/mob/living/carbon/human/monkey/Initialize(mapload)
|
||||
..(mapload, /datum/species/monkey)
|
||||
. = ..(mapload, /datum/species/monkey)
|
||||
|
||||
/mob/living/carbon/human/farwa/Initialize(mapload)
|
||||
..(mapload, /datum/species/monkey/tajaran)
|
||||
. = ..(mapload, /datum/species/monkey/tajaran)
|
||||
|
||||
/mob/living/carbon/human/wolpin/Initialize(mapload)
|
||||
..(mapload, /datum/species/monkey/vulpkanin)
|
||||
. = ..(mapload, /datum/species/monkey/vulpkanin)
|
||||
|
||||
/mob/living/carbon/human/neara/Initialize(mapload)
|
||||
..(mapload, /datum/species/monkey/skrell)
|
||||
. = ..(mapload, /datum/species/monkey/skrell)
|
||||
|
||||
/mob/living/carbon/human/stok/Initialize(mapload)
|
||||
..(mapload, /datum/species/monkey/unathi)
|
||||
. = ..(mapload, /datum/species/monkey/unathi)
|
||||
|
||||
/mob/living/carbon/human/Stat()
|
||||
..()
|
||||
@@ -1160,18 +1162,6 @@
|
||||
custom_pain("You feel a stabbing pain in your chest!")
|
||||
L.damage = L.min_bruised_damage
|
||||
|
||||
//returns 1 if made bloody, returns 0 otherwise
|
||||
|
||||
/mob/living/carbon/human/clean_blood(var/clean_feet)
|
||||
.=..()
|
||||
if(clean_feet && !shoes && istype(feet_blood_DNA, /list) && feet_blood_DNA.len)
|
||||
feet_blood_color = null
|
||||
qdel(feet_blood_DNA)
|
||||
bloody_feet = list(BLOOD_STATE_HUMAN = 0, BLOOD_STATE_XENO = 0, BLOOD_STATE_NOT_BLOODY = 0)
|
||||
blood_state = BLOOD_STATE_NOT_BLOODY
|
||||
update_inv_shoes()
|
||||
return 1
|
||||
|
||||
/mob/living/carbon/human/cuff_resist(obj/item/I)
|
||||
if(HULK in mutations)
|
||||
say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ))
|
||||
@@ -1699,14 +1689,14 @@ Eyes need to have significantly high darksight to shine unless the mob has the X
|
||||
|
||||
/mob/living/carbon/human/forceFed(var/obj/item/reagent_containers/food/toEat, mob/user, fullness)
|
||||
if(!check_has_mouth())
|
||||
if(!((istype(toEat, /obj/item/reagent_containers/food/drinks) && (ismachine(src)))))
|
||||
if(!((istype(toEat, /obj/item/reagent_containers/food/drinks) && (ismachineperson(src)))))
|
||||
to_chat(user, "Where do you intend to put \the [toEat]? \The [src] doesn't have a mouth!")
|
||||
return 0
|
||||
return ..()
|
||||
|
||||
/mob/living/carbon/human/selfDrink(var/obj/item/reagent_containers/food/drinks/toDrink)
|
||||
if(!check_has_mouth())
|
||||
if(!ismachine(src))
|
||||
if(!ismachineperson(src))
|
||||
to_chat(src, "Where do you intend to put \the [src]? You don't have a mouth!")
|
||||
return 0
|
||||
else
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
if(dna.species && amount > 0)
|
||||
if(use_brain_mod)
|
||||
amount = amount * dna.species.brain_mod
|
||||
sponge.damage = Clamp(sponge.damage + amount, 0, 120)
|
||||
sponge.damage = clamp(sponge.damage + amount, 0, 120)
|
||||
if(sponge.damage >= 120)
|
||||
visible_message("<span class='alert'><B>[src]</B> goes limp, [p_their()] facial expression utterly blank.</span>")
|
||||
death()
|
||||
@@ -48,7 +48,7 @@
|
||||
if(dna.species && amount > 0)
|
||||
if(use_brain_mod)
|
||||
amount = amount * dna.species.brain_mod
|
||||
sponge.damage = Clamp(amount, 0, 120)
|
||||
sponge.damage = clamp(amount, 0, 120)
|
||||
if(sponge.damage >= 120)
|
||||
visible_message("<span class='alert'><B>[src]</B> goes limp, [p_their()] facial expression utterly blank.</span>")
|
||||
death()
|
||||
|
||||
@@ -84,7 +84,7 @@ emp_act
|
||||
E.heal_damage(rembrute,0,0,1)
|
||||
rembrute = nrembrute
|
||||
user.visible_message("<span class='alert'>[user] patches some dents on [src]'s [E.name] with [I].</span>")
|
||||
if(bleed_rate && isSynthetic())
|
||||
if(bleed_rate && ismachineperson(src))
|
||||
bleed_rate = 0
|
||||
user.visible_message("<span class='alert'>[user] patches some leaks on [src] with [I].</span>")
|
||||
if(IgniteMob())
|
||||
@@ -134,7 +134,7 @@ emp_act
|
||||
if(bp && istype(bp ,/obj/item/clothing))
|
||||
var/obj/item/clothing/C = bp
|
||||
if(C.body_parts_covered & def_zone.body_part)
|
||||
protection += C.armor[type]
|
||||
protection += C.armor.getRating(type)
|
||||
|
||||
return protection
|
||||
|
||||
@@ -185,19 +185,19 @@ emp_act
|
||||
var/block_chance_modifier = round(damage / -3)
|
||||
|
||||
if(l_hand && !istype(l_hand, /obj/item/clothing))
|
||||
var/final_block_chance = l_hand.block_chance - (Clamp((armour_penetration-l_hand.armour_penetration)/2,0,100)) + block_chance_modifier //So armour piercing blades can still be parried by other blades, for example
|
||||
var/final_block_chance = l_hand.block_chance - (clamp((armour_penetration-l_hand.armour_penetration)/2,0,100)) + block_chance_modifier //So armour piercing blades can still be parried by other blades, for example
|
||||
if(l_hand.hit_reaction(src, AM, attack_text, final_block_chance, damage, attack_type))
|
||||
return 1
|
||||
if(r_hand && !istype(r_hand, /obj/item/clothing))
|
||||
var/final_block_chance = r_hand.block_chance - (Clamp((armour_penetration-r_hand.armour_penetration)/2,0,100)) + block_chance_modifier //Need to reset the var so it doesn't carry over modifications between attempts
|
||||
var/final_block_chance = r_hand.block_chance - (clamp((armour_penetration-r_hand.armour_penetration)/2,0,100)) + block_chance_modifier //Need to reset the var so it doesn't carry over modifications between attempts
|
||||
if(r_hand.hit_reaction(src, AM, attack_text, final_block_chance, damage, attack_type))
|
||||
return 1
|
||||
if(wear_suit)
|
||||
var/final_block_chance = wear_suit.block_chance - (Clamp((armour_penetration-wear_suit.armour_penetration)/2,0,100)) + block_chance_modifier
|
||||
var/final_block_chance = wear_suit.block_chance - (clamp((armour_penetration-wear_suit.armour_penetration)/2,0,100)) + block_chance_modifier
|
||||
if(wear_suit.hit_reaction(src, AM, attack_text, final_block_chance, damage, attack_type))
|
||||
return 1
|
||||
if(w_uniform)
|
||||
var/final_block_chance = w_uniform.block_chance - (Clamp((armour_penetration-w_uniform.armour_penetration)/2,0,100)) + block_chance_modifier
|
||||
var/final_block_chance = w_uniform.block_chance - (clamp((armour_penetration-w_uniform.armour_penetration)/2,0,100)) + block_chance_modifier
|
||||
if(w_uniform.hit_reaction(src, AM, attack_text, final_block_chance, damage, attack_type))
|
||||
return 1
|
||||
return 0
|
||||
@@ -387,11 +387,6 @@ emp_act
|
||||
to_chat(user, "<span class='warning'>You hack off a chunk of meat from [name]</span>")
|
||||
if(!meatleft)
|
||||
add_attack_logs(user, src, "Chopped up into meat")
|
||||
if(!iscarbon(user))
|
||||
LAssailant = null
|
||||
else
|
||||
LAssailant = user
|
||||
|
||||
qdel(src)
|
||||
|
||||
var/obj/item/organ/external/affecting = get_organ(ran_zone(user.zone_selected))
|
||||
|
||||
@@ -37,7 +37,6 @@ GLOBAL_DATUM_INIT(default_martial_art, /datum/martial_art, new())
|
||||
var/obj/item/s_store = null
|
||||
|
||||
var/icon/stand_icon = null
|
||||
var/icon/lying_icon = null
|
||||
|
||||
var/voice = "" //Instead of new say code calling GetVoice() over and over and over, we're just going to ask this variable, which gets updated in Life()
|
||||
|
||||
|
||||
@@ -81,7 +81,7 @@
|
||||
|
||||
/mob/living/carbon/human/handle_footstep(turf/T)
|
||||
if(..())
|
||||
if(T.footstep_sounds["human"])
|
||||
if(T.footstep_sounds && T.footstep_sounds["human"])
|
||||
var/S = pick(T.footstep_sounds["human"])
|
||||
if(S)
|
||||
if(m_intent == MOVE_INTENT_RUN)
|
||||
|
||||
@@ -197,7 +197,7 @@
|
||||
|
||||
if(!(RADIMMUNE in dna.species.species_traits))
|
||||
if(radiation)
|
||||
radiation = Clamp(radiation, 0, 200)
|
||||
radiation = clamp(radiation, 0, 200)
|
||||
|
||||
var/autopsy_damage = 0
|
||||
switch(radiation)
|
||||
@@ -635,7 +635,7 @@
|
||||
else
|
||||
overeatduration -= 2
|
||||
|
||||
if(!ismachine(src) && nutrition < NUTRITION_LEVEL_HYPOGLYCEMIA) //Gosh damn snowflakey IPCs
|
||||
if(!ismachineperson(src) && nutrition < NUTRITION_LEVEL_HYPOGLYCEMIA) //Gosh damn snowflakey IPCs
|
||||
var/datum/disease/D = new /datum/disease/critical/hypoglycemia
|
||||
ForceContractDisease(D)
|
||||
|
||||
@@ -697,7 +697,7 @@
|
||||
alcohol_strength /= sober_str
|
||||
|
||||
var/obj/item/organ/internal/liver/L
|
||||
if(!isSynthetic())
|
||||
if(!ismachineperson(src))
|
||||
L = get_int_organ(/obj/item/organ/internal/liver)
|
||||
if(L)
|
||||
alcohol_strength *= L.alcohol_intensity
|
||||
@@ -719,7 +719,7 @@
|
||||
AdjustConfused(3 / sober_str)
|
||||
if(alcohol_strength >= blur_start) //blurry eyes
|
||||
EyeBlurry(10 / sober_str)
|
||||
if(!isSynthetic()) //stuff only for non-synthetics
|
||||
if(!ismachineperson(src)) //stuff only for non-synthetics
|
||||
if(alcohol_strength >= vomit_start) //vomiting
|
||||
if(prob(8))
|
||||
fakevomit()
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
species_exception = list(/datum/species/monkey)
|
||||
|
||||
/mob/living/carbon/human/monkey/punpun/Initialize(mapload)
|
||||
..()
|
||||
. = ..()
|
||||
name = "Pun Pun"
|
||||
real_name = name
|
||||
equip_to_slot(new /obj/item/clothing/under/punpun(src), slot_w_uniform)
|
||||
|
||||
@@ -53,7 +53,6 @@
|
||||
var/stun_mod = 1 // If a species is more/less impacated by stuns/weakens/paralysis
|
||||
var/speed_mod = 0 // this affects the race's speed. positive numbers make it move slower, negative numbers make it move faster
|
||||
var/blood_damage_type = OXY //What type of damage does this species take if it's low on blood?
|
||||
var/obj/item/mutanthands
|
||||
var/total_health = 100
|
||||
var/punchdamagelow = 0 //lowest possible punch damage
|
||||
var/punchdamagehigh = 9 //highest possible punch damage
|
||||
@@ -352,21 +351,6 @@
|
||||
if(organ.receive_damage(damage, 0, sharp, used_weapon))
|
||||
H.UpdateDamageIcon()
|
||||
|
||||
if(H.LAssailant && ishuman(H.LAssailant)) //superheros still get the comical hit markers
|
||||
var/mob/living/carbon/human/A = H.LAssailant
|
||||
if(A.mind && (A.mind in (SSticker.mode.superheroes) || SSticker.mode.supervillains || SSticker.mode.greyshirts))
|
||||
var/list/attack_bubble_recipients = list()
|
||||
var/mob/living/user
|
||||
for(var/mob/O in viewers(user, src))
|
||||
if(O.client && O.has_vision(information_only=TRUE))
|
||||
attack_bubble_recipients.Add(O.client)
|
||||
spawn(0)
|
||||
var/image/dmgIcon = image('icons/effects/hit_blips.dmi', src, "dmg[rand(1,2)]",MOB_LAYER+1)
|
||||
dmgIcon.pixel_x = (!H.lying) ? rand(-3,3) : rand(-11,12)
|
||||
dmgIcon.pixel_y = (!H.lying) ? rand(-11,9) : rand(-10,1)
|
||||
flick_overlay(dmgIcon, attack_bubble_recipients, 9)
|
||||
|
||||
|
||||
if(BURN)
|
||||
H.damageoverlaytemp = 20
|
||||
damage = damage * burn_mod
|
||||
@@ -443,6 +427,9 @@
|
||||
else
|
||||
target.LAssailant = user
|
||||
|
||||
target.lastattacker = user.real_name
|
||||
target.lastattackerckey = user.ckey
|
||||
|
||||
var/damage = rand(user.dna.species.punchdamagelow, user.dna.species.punchdamagehigh)
|
||||
damage += attack.damage
|
||||
if(!damage)
|
||||
|
||||
@@ -1,102 +0,0 @@
|
||||
#define REGENERATION_DELAY 60 // After taking damage, how long it takes for automatic regeneration to begin
|
||||
|
||||
/datum/species/zombie
|
||||
// 1spooky
|
||||
name = "High-Functioning Zombie"
|
||||
name_plural = "High-Functioning Zombies"
|
||||
icobase = 'icons/mob/human_races/r_zombie.dmi'
|
||||
deform = 'icons/mob/human_races/r_def_zombie.dmi'
|
||||
dies_at_threshold = TRUE
|
||||
language = "Zombie"
|
||||
species_traits = list(NO_BLOOD, NOZOMBIE, NOTRANSSTING, NO_BREATHE, RADIMMUNE, NO_SCAN)
|
||||
var/static/list/spooks = list('sound/hallucinations/growl1.ogg','sound/hallucinations/growl2.ogg','sound/hallucinations/growl3.ogg','sound/hallucinations/veryfar_noise.ogg','sound/hallucinations/wail.ogg')
|
||||
warning_low_pressure = -1
|
||||
hazard_low_pressure = -1
|
||||
hazard_high_pressure = 999999999
|
||||
warning_high_pressure = 999999999
|
||||
cold_level_1 = -1
|
||||
cold_level_2 = -1
|
||||
cold_level_3 = -1
|
||||
tox_mod = 0
|
||||
flesh_color = "#00FF00" // for green examine text
|
||||
bodyflags = HAS_SKIN_COLOR
|
||||
dietflags = DIET_CARN
|
||||
has_organ = list(
|
||||
"heart" = /obj/item/organ/internal/heart,
|
||||
"lungs" = /obj/item/organ/internal/lungs,
|
||||
"liver" = /obj/item/organ/internal/liver,
|
||||
"kidneys" = /obj/item/organ/internal/kidneys,
|
||||
"brain" = /obj/item/organ/internal/brain,
|
||||
"appendix" = /obj/item/organ/internal/appendix,
|
||||
"eyes" = /obj/item/organ/internal/eyes,
|
||||
"ears" = /obj/item/organ/internal/ears)
|
||||
|
||||
|
||||
/datum/species/zombie/infectious
|
||||
name = "Infectious Zombie"
|
||||
mutanthands = /obj/item/zombie_hand
|
||||
icobase = 'icons/mob/human_races/r_zombie.dmi'
|
||||
deform = 'icons/mob/human_races/r_def_zombie.dmi'
|
||||
brute_mod = 0.8 // 120 damage to KO a zombie, which kills it
|
||||
burn_mod = 0.8
|
||||
clone_mod = 0.8
|
||||
brain_mod = 0.8
|
||||
stamina_mod = 0.8
|
||||
speed_mod = 1.6
|
||||
default_language = "Zombie"
|
||||
var/heal_rate = 1
|
||||
var/regen_cooldown = 0
|
||||
|
||||
/datum/species/zombie/infectious/spec_stun(mob/living/carbon/human/H, amount)
|
||||
. = min(20, amount)
|
||||
|
||||
/datum/species/zombie/infectious/apply_damage(damage = 0, damagetype = BRUTE, def_zone = null, blocked = 0, sharp = 0, obj/used_weapon = null)
|
||||
. = ..()
|
||||
if(damage)
|
||||
regen_cooldown = world.time + REGENERATION_DELAY
|
||||
|
||||
/datum/species/zombie/infectious/handle_life(mob/living/carbon/human/H)
|
||||
. = ..()
|
||||
H.a_intent = INTENT_HARM // THE SUFFERING MUST FLOW
|
||||
|
||||
//Zombies never actually die, they just fall down until they regenerate enough to rise back up.
|
||||
//They must be restrained, beheaded or gibbed to stop being a threat.
|
||||
if(regen_cooldown < world.time)
|
||||
var/heal_amt = heal_rate
|
||||
if(H.InCritical())
|
||||
heal_amt *= 2
|
||||
H.heal_overall_damage(heal_amt,heal_amt)
|
||||
H.adjustToxLoss(-heal_amt)
|
||||
if(!H.InCritical() && prob(4))
|
||||
playsound(H, pick(spooks), 50, TRUE, 10)
|
||||
|
||||
//Congrats you somehow died so hard you stopped being a zombie
|
||||
/datum/species/zombie/infectious/handle_death(gibbed, mob/living/carbon/C)
|
||||
. = ..()
|
||||
var/obj/item/organ/internal/zombie_infection/infection
|
||||
infection = C.get_organ_slot("zombie_infection")
|
||||
if(infection)
|
||||
qdel(infection)
|
||||
|
||||
/datum/species/zombie/infectious/on_species_gain(mob/living/carbon/human/H, datum/species/old_species)
|
||||
. = ..()
|
||||
// Deal with the source of this zombie corruption
|
||||
// Infection organ needs to be handled separately from mutant_organs
|
||||
// because it persists through species transitions
|
||||
if(mutanthands)
|
||||
H.drop_l_hand()
|
||||
H.drop_r_hand()
|
||||
H.put_in_hands(new mutanthands())
|
||||
H.put_in_hands(new mutanthands())
|
||||
var/obj/item/organ/internal/zombie_infection/infection
|
||||
infection = H.get_organ_slot("zombie_infection")
|
||||
if(!infection)
|
||||
infection = new()
|
||||
infection.insert(H)
|
||||
|
||||
/datum/species/zombie/infectious/on_species_loss(mob/living/carbon/human/C, datum/species/old_species)
|
||||
QDEL_NULL(C.r_hand)
|
||||
QDEL_NULL(C.l_hand)
|
||||
return ..()
|
||||
|
||||
#undef REGENERATION_DELAY
|
||||
@@ -376,7 +376,7 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
|
||||
|
||||
//base icons
|
||||
var/icon/hair_standing = new /icon('icons/mob/human_face.dmi',"bald_s")
|
||||
if(head_organ.h_style && !(head && (head.flags & BLOCKHEADHAIR) && !(isSynthetic())))
|
||||
if(head_organ.h_style && !(head && (head.flags & BLOCKHEADHAIR) && !(ismachineperson(src))))
|
||||
var/datum/sprite_accessory/hair/hair_style = GLOB.hair_styles_full_list[head_organ.h_style]
|
||||
if(hair_style && hair_style.species_allowed)
|
||||
if((head_organ.dna.species.name in hair_style.species_allowed) || (head_organ.dna.species.bodyflags & ALL_RPARTS)) //If the head's species is in the list of allowed species for the hairstyle, or the head's species is one flagged to have bodies comprised wholly of cybernetics...
|
||||
|
||||
@@ -11,6 +11,10 @@
|
||||
if(stat != DEAD)
|
||||
handle_organs()
|
||||
|
||||
//stuff in the stomach
|
||||
if(LAZYLEN(stomach_contents))
|
||||
handle_stomach(times_fired)
|
||||
|
||||
. = ..()
|
||||
|
||||
if(QDELETED(src))
|
||||
@@ -122,7 +126,7 @@
|
||||
var/O2_partialpressure = (breath.oxygen/breath.total_moles())*breath_pressure
|
||||
var/Toxins_partialpressure = (breath.toxins/breath.total_moles())*breath_pressure
|
||||
var/CO2_partialpressure = (breath.carbon_dioxide/breath.total_moles())*breath_pressure
|
||||
|
||||
var/SA_partialpressure = (breath.sleeping_agent/breath.total_moles())*breath_pressure
|
||||
|
||||
//OXYGEN
|
||||
if(O2_partialpressure < safe_oxy_min) //Not enough oxygen
|
||||
@@ -162,22 +166,20 @@
|
||||
//TOXINS/PLASMA
|
||||
if(Toxins_partialpressure > safe_tox_max)
|
||||
var/ratio = (breath.toxins/safe_tox_max) * 10
|
||||
adjustToxLoss(Clamp(ratio, MIN_TOXIC_GAS_DAMAGE, MAX_TOXIC_GAS_DAMAGE))
|
||||
adjustToxLoss(clamp(ratio, MIN_TOXIC_GAS_DAMAGE, MAX_TOXIC_GAS_DAMAGE))
|
||||
throw_alert("too_much_tox", /obj/screen/alert/too_much_tox)
|
||||
else
|
||||
clear_alert("too_much_tox")
|
||||
|
||||
//TRACE GASES
|
||||
if(breath.trace_gases.len)
|
||||
for(var/datum/gas/sleeping_agent/SA in breath.trace_gases)
|
||||
var/SA_partialpressure = (SA.moles/breath.total_moles())*breath_pressure
|
||||
if(SA_partialpressure > SA_para_min)
|
||||
Paralyse(3)
|
||||
if(SA_partialpressure > SA_sleep_min)
|
||||
AdjustSleeping(2, bound_lower = 0, bound_upper = 10)
|
||||
else if(SA_partialpressure > 0.01)
|
||||
if(prob(20))
|
||||
emote(pick("giggle","laugh"))
|
||||
if(breath.sleeping_agent)
|
||||
if(SA_partialpressure > SA_para_min)
|
||||
Paralyse(3)
|
||||
if(SA_partialpressure > SA_sleep_min)
|
||||
AdjustSleeping(2, bound_lower = 0, bound_upper = 10)
|
||||
else if(SA_partialpressure > 0.01)
|
||||
if(prob(20))
|
||||
emote(pick("giggle","laugh"))
|
||||
|
||||
//BREATH TEMPERATURE
|
||||
handle_breath_temperature(breath)
|
||||
@@ -245,7 +247,7 @@
|
||||
adjustToxLoss(3)
|
||||
updatehealth("handle mutations and radiation(75-100)")
|
||||
|
||||
radiation = Clamp(radiation, 0, 100)
|
||||
radiation = clamp(radiation, 0, 100)
|
||||
|
||||
|
||||
/mob/living/carbon/handle_chemicals_in_body()
|
||||
@@ -256,14 +258,15 @@
|
||||
if(times_fired % 20==2) //dry off a bit once every 20 ticks or so
|
||||
wetlevel = max(wetlevel - 1,0)
|
||||
|
||||
/mob/living/carbon/handle_stomach(times_fired)
|
||||
for(var/mob/living/M in stomach_contents)
|
||||
/mob/living/carbon/proc/handle_stomach(times_fired)
|
||||
for(var/thing in stomach_contents)
|
||||
var/mob/living/M = thing
|
||||
if(M.loc != src)
|
||||
stomach_contents.Remove(M)
|
||||
LAZYREMOVE(stomach_contents, M)
|
||||
continue
|
||||
if(stat != DEAD)
|
||||
if(M.stat == DEAD)
|
||||
stomach_contents.Remove(M)
|
||||
LAZYREMOVE(stomach_contents, M)
|
||||
qdel(M)
|
||||
continue
|
||||
if(times_fired % 3 == 1)
|
||||
@@ -478,7 +481,7 @@
|
||||
P.reagents.remove_any(applied_amount * 0.5)
|
||||
else
|
||||
if(!P.reagents || P.reagents.total_volume <= 0)
|
||||
processing_patches -= P
|
||||
LAZYREMOVE(processing_patches, P)
|
||||
qdel(P)
|
||||
|
||||
/mob/living/carbon/proc/handle_germs()
|
||||
|
||||
@@ -58,9 +58,6 @@
|
||||
|
||||
handle_fire()
|
||||
|
||||
//stuff in the stomach
|
||||
handle_stomach(times_fired)
|
||||
|
||||
update_gravity(mob_has_gravity())
|
||||
|
||||
if(pulling)
|
||||
@@ -117,9 +114,6 @@
|
||||
/mob/living/proc/handle_environment(datum/gas_mixture/environment)
|
||||
return
|
||||
|
||||
/mob/living/proc/handle_stomach(times_fired)
|
||||
return
|
||||
|
||||
/mob/living/proc/update_pulling()
|
||||
if(incapacitated())
|
||||
stop_pulling()
|
||||
|
||||
@@ -682,9 +682,6 @@
|
||||
*/////////////////////
|
||||
/mob/living/proc/resist_grab()
|
||||
var/resisting = 0
|
||||
for(var/obj/O in requests)
|
||||
qdel(O)
|
||||
resisting++
|
||||
for(var/X in grabbed_by)
|
||||
var/obj/item/grab/G = X
|
||||
resisting++
|
||||
@@ -740,7 +737,8 @@
|
||||
clear_alert("weightless")
|
||||
else
|
||||
throw_alert("weightless", /obj/screen/alert/weightless)
|
||||
float(!has_gravity)
|
||||
if(!flying)
|
||||
float(!has_gravity)
|
||||
|
||||
/mob/living/proc/float(on)
|
||||
if(throwing)
|
||||
@@ -825,8 +823,7 @@
|
||||
spawn_dust()
|
||||
gib()
|
||||
|
||||
/mob/living/do_attack_animation(atom/A, visual_effect_icon, obj/item/used_item, no_effect, end_pixel_y)
|
||||
end_pixel_y = get_standard_pixel_y_offset(lying)
|
||||
/mob/living/do_attack_animation(atom/A, visual_effect_icon, obj/item/used_item, no_effect)
|
||||
if(!used_item)
|
||||
used_item = get_active_hand()
|
||||
..()
|
||||
|
||||
@@ -79,9 +79,9 @@
|
||||
|
||||
/obj/item/proc/get_volume_by_throwforce_and_or_w_class()
|
||||
if(throwforce && w_class)
|
||||
return Clamp((throwforce + w_class) * 5, 30, 100)// Add the item's throwforce to its weight class and multiply by 5, then clamp the value between 30 and 100
|
||||
return clamp((throwforce + w_class) * 5, 30, 100)// Add the item's throwforce to its weight class and multiply by 5, then clamp the value between 30 and 100
|
||||
else if(w_class)
|
||||
return Clamp(w_class * 8, 20, 100) // Multiply the item's weight class by 8, then clamp the value between 20 and 100
|
||||
return clamp(w_class * 8, 20, 100) // Multiply the item's weight class by 8, then clamp the value between 20 and 100
|
||||
else
|
||||
return 0
|
||||
|
||||
@@ -175,7 +175,7 @@
|
||||
return
|
||||
|
||||
/mob/living/proc/adjust_fire_stacks(add_fire_stacks) //Adjusting the amount of fire_stacks we have on person
|
||||
fire_stacks = Clamp(fire_stacks + add_fire_stacks, -20, 20)
|
||||
fire_stacks = clamp(fire_stacks + add_fire_stacks, -20, 20)
|
||||
if(on_fire && fire_stacks <= 0)
|
||||
ExtinguishMob()
|
||||
|
||||
@@ -260,8 +260,6 @@
|
||||
add_attack_logs(user, src, "Grabbed passively", ATKLOG_ALL)
|
||||
|
||||
var/obj/item/grab/G = new /obj/item/grab(user, src)
|
||||
if(buckled)
|
||||
to_chat(user, "<span class='notice'>You cannot grab [src]; [p_they()] [p_are()] buckled in!</span>")
|
||||
if(!G) //the grab will delete itself in New if src is anchored
|
||||
return 0
|
||||
user.put_in_active_hand(G)
|
||||
|
||||
@@ -61,7 +61,7 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
return default_language
|
||||
|
||||
/mob/living/proc/handle_speech_problems(list/message_pieces, var/verb)
|
||||
var/robot = isSynthetic()
|
||||
var/robot = ismachineperson(src)
|
||||
for(var/datum/multilingual_say_piece/S in message_pieces)
|
||||
if(S.speaking && S.speaking.flags & NO_STUTTER)
|
||||
continue
|
||||
@@ -269,12 +269,12 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
M.hear_say(message_pieces, verb, italics, src, speech_sound, sound_vol, sound_frequency)
|
||||
if(M.client)
|
||||
speech_bubble_recipients.Add(M.client)
|
||||
spawn(0)
|
||||
if(loc && !isturf(loc))
|
||||
var/atom/A = loc //Non-turf, let it handle the speech bubble
|
||||
A.speech_bubble("hR[speech_bubble_test]", A, speech_bubble_recipients)
|
||||
else //Turf, leave speech bubbles to the mob
|
||||
speech_bubble("h[speech_bubble_test]", src, speech_bubble_recipients)
|
||||
|
||||
if(loc && !isturf(loc))
|
||||
var/atom/A = loc //Non-turf, let it handle the speech bubble
|
||||
A.speech_bubble("[A.bubble_icon][speech_bubble_test]", A, speech_bubble_recipients)
|
||||
else //Turf, leave speech bubbles to the mob
|
||||
speech_bubble("[bubble_icon][speech_bubble_test]", src, speech_bubble_recipients)
|
||||
|
||||
for(var/obj/O in listening_obj)
|
||||
spawn(0)
|
||||
@@ -336,7 +336,8 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
var/datum/multilingual_say_piece/S = message_pieces // Yay BYOND's hilarious typecasting
|
||||
S.speaking.broadcast(src, S.message)
|
||||
return 1
|
||||
|
||||
// Log it here since it skips the default way say handles it
|
||||
create_log(SAY_LOG, "(whisper) '[message]'")
|
||||
whisper_say(message_pieces)
|
||||
|
||||
// for weird circumstances where you're inside an atom that is also you, like pai's
|
||||
@@ -461,10 +462,7 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
if(M.client)
|
||||
speech_bubble_recipients.Add(M.client)
|
||||
|
||||
spawn(0)
|
||||
var/image/I = image('icons/mob/talk.dmi', src, "h[speech_bubble_test]", MOB_LAYER + 1)
|
||||
I.appearance_flags = APPEARANCE_UI_IGNORE_ALPHA
|
||||
flick_overlay(I, speech_bubble_recipients, 30)
|
||||
speech_bubble("[bubble_icon][speech_bubble_test]", src, speech_bubble_recipients)
|
||||
|
||||
if(watching.len)
|
||||
var/rendered = "<span class='game say'><span class='name'>[name]</span> [not_heard].</span>"
|
||||
@@ -473,7 +471,7 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
|
||||
return 1
|
||||
|
||||
/mob/living/speech_bubble(var/bubble_state = "",var/bubble_loc = src, var/list/bubble_recipients = list())
|
||||
var/image/I = image('icons/mob/talk.dmi', bubble_loc, bubble_state, MOB_LAYER + 1)
|
||||
/mob/living/speech_bubble(bubble_state = "", bubble_loc = src, list/bubble_recipients = list())
|
||||
var/image/I = image('icons/mob/talk.dmi', bubble_loc, bubble_state, FLY_LAYER)
|
||||
I.appearance_flags = APPEARANCE_UI_IGNORE_ALPHA
|
||||
flick_overlay(I, bubble_recipients, 30)
|
||||
INVOKE_ASYNC(GLOBAL_PROC, /.proc/flick_overlay, I, bubble_recipients, 30)
|
||||
|
||||
@@ -243,7 +243,8 @@ GLOBAL_LIST_INIT(ai_verbs_default, list(
|
||||
|
||||
/mob/living/silicon/ai/proc/show_borg_info()
|
||||
stat(null, text("Connected cyborgs: [connected_robots.len]"))
|
||||
for(var/mob/living/silicon/robot/R in connected_robots)
|
||||
for(var/thing in connected_robots)
|
||||
var/mob/living/silicon/robot/R = thing
|
||||
var/robot_status = "Nominal"
|
||||
if(R.stat || !R.client)
|
||||
robot_status = "OFFLINE"
|
||||
@@ -251,8 +252,9 @@ GLOBAL_LIST_INIT(ai_verbs_default, list(
|
||||
robot_status = "DEPOWERED"
|
||||
// Name, Health, Battery, Module, Area, and Status! Everything an AI wants to know about its borgies!
|
||||
var/area/A = get_area(R)
|
||||
var/area_name = A ? sanitize(A.name) : "Unknown"
|
||||
stat(null, text("[R.name] | S.Integrity: [R.health]% | Cell: [R.cell ? "[R.cell.charge] / [R.cell.maxcharge]" : "Empty"] | \
|
||||
Module: [R.designation] | Loc: [sanitize(A.name)] | Status: [robot_status]"))
|
||||
Module: [R.designation] | Loc: [area_name] | Status: [robot_status]"))
|
||||
|
||||
/mob/living/silicon/ai/rename_character(oldname, newname)
|
||||
if(!..(oldname, newname))
|
||||
|
||||
@@ -253,7 +253,7 @@ proc/robot_healthscan(mob/user, mob/living/M)
|
||||
to_chat(user, "<span class='warning'>You can't analyze non-robotic things!</span>")
|
||||
return
|
||||
|
||||
|
||||
|
||||
switch(scan_type)
|
||||
if("robot")
|
||||
var/BU = M.getFireLoss() > 50 ? "<b>[M.getFireLoss()]</b>" : M.getFireLoss()
|
||||
@@ -269,7 +269,7 @@ proc/robot_healthscan(mob/user, mob/living/M)
|
||||
to_chat(user, "<span class='notice'>Localized Damage:</span>")
|
||||
if(!LAZYLEN(damaged) && !LAZYLEN(missing))
|
||||
to_chat(user, "<span class='notice'>\t Components are OK.</span>")
|
||||
else
|
||||
else
|
||||
if(LAZYLEN(damaged))
|
||||
for(var/datum/robot_component/org in damaged)
|
||||
user.show_message(text("<span class='notice'>\t []: [][] - [] - [] - []</span>", \
|
||||
@@ -282,7 +282,7 @@ proc/robot_healthscan(mob/user, mob/living/M)
|
||||
if(LAZYLEN(missing))
|
||||
for(var/datum/robot_component/org in missing)
|
||||
user.show_message("<span class='warning'>\t [capitalize(org.name)]: MISSING</span>")
|
||||
|
||||
|
||||
if(H.emagged && prob(5))
|
||||
to_chat(user, "<span class='warning'>\t ERROR: INTERNAL SYSTEMS COMPROMISED</span>")
|
||||
|
||||
@@ -313,7 +313,7 @@ proc/robot_healthscan(mob/user, mob/living/M)
|
||||
if(!organ_found)
|
||||
to_chat(user, "<span class='warning'>No prosthetics located.</span>")
|
||||
|
||||
if(H.isSynthetic())
|
||||
if(ismachineperson(H))
|
||||
to_chat(user, "<span class='notice'>Internal Fluid Level:[H.blood_volume]/[H.max_blood]</span>")
|
||||
if(H.bleed_rate)
|
||||
to_chat(user, "<span class='warning'>Warning:External component leak detected!</span>")
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
icon_state = "repairbot"
|
||||
maxHealth = 35
|
||||
health = 35
|
||||
bubble_icon = "machine"
|
||||
universal_speak = 0
|
||||
universal_understand = 1
|
||||
gender = NEUTER
|
||||
@@ -13,6 +14,7 @@
|
||||
braintype = "Robot"
|
||||
lawupdate = 0
|
||||
density = 0
|
||||
has_camera = FALSE
|
||||
req_one_access = list(ACCESS_ENGINE, ACCESS_ROBOTICS)
|
||||
ventcrawler = 2
|
||||
magpulse = 1
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
..()
|
||||
can_hold = typecacheof(can_hold)
|
||||
|
||||
/obj/item/gripper/verb/drop_item()
|
||||
/obj/item/gripper/verb/drop_item_gripped()
|
||||
set name = "Drop Gripped Item"
|
||||
set desc = "Release an item from your magnetic gripper."
|
||||
set category = "Drone"
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
if(is_component_functioning("power cell") && cell.charge)
|
||||
if(cell.charge <= 100)
|
||||
uneq_all()
|
||||
var/amt = Clamp((lamp_intensity - 2) * 2,1,cell.charge) //Always try to use at least one charge per tick, but allow it to completely drain the cell.
|
||||
var/amt = clamp((lamp_intensity - 2) * 2,1,cell.charge) //Always try to use at least one charge per tick, but allow it to completely drain the cell.
|
||||
cell.use(amt) //Usage table: 1/tick if off/lowest setting, 4 = 4/tick, 6 = 8/tick, 8 = 12/tick, 10 = 16/tick
|
||||
else
|
||||
uneq_all()
|
||||
|
||||
@@ -9,6 +9,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
icon_state = "robot"
|
||||
maxHealth = 100
|
||||
health = 100
|
||||
bubble_icon = "robot"
|
||||
universal_understand = 1
|
||||
deathgasp_on_death = TRUE
|
||||
|
||||
@@ -16,8 +17,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
var/custom_name = ""
|
||||
var/custom_sprite = 0 //Due to all the sprites involved, a var for our custom borgs may be best
|
||||
|
||||
//Hud stuff
|
||||
|
||||
//Hud stuff
|
||||
var/obj/screen/inv1 = null
|
||||
var/obj/screen/inv2 = null
|
||||
var/obj/screen/inv3 = null
|
||||
@@ -27,7 +27,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
var/shown_robot_modules = 0 //Used to determine whether they have the module menu shown or not
|
||||
var/obj/screen/robot_modules_background
|
||||
|
||||
//3 Modules can be activated at any one time.
|
||||
//3 Modules can be activated at any one time.
|
||||
var/obj/item/robot_module/module = null
|
||||
var/module_active = null
|
||||
var/module_state_1 = null
|
||||
@@ -57,6 +57,9 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
var/is_emaggable = TRUE
|
||||
var/eye_protection = 0
|
||||
var/ear_protection = 0
|
||||
var/damage_protection = 0
|
||||
var/emp_protection = FALSE
|
||||
var/xeno_disarm_chance = 85
|
||||
|
||||
var/list/force_modules = list()
|
||||
var/allow_rename = TRUE
|
||||
@@ -82,11 +85,11 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
var/lockcharge //Used when locking down a borg to preserve cell charge
|
||||
var/speed = 0 //Cause sec borgs gotta go fast //No they dont!
|
||||
var/scrambledcodes = 0 // Used to determine if a borg shows up on the robotics console. Setting to one hides them.
|
||||
var/has_camera = TRUE
|
||||
var/pdahide = 0 //Used to hide the borg from the messenger list
|
||||
var/tracking_entities = 0 //The number of known entities currently accessing the internal camera
|
||||
var/braintype = "Cyborg"
|
||||
var/base_icon = ""
|
||||
var/crisis = 0
|
||||
var/modules_break = TRUE
|
||||
|
||||
var/lamp_max = 10 //Maximum brightness of a borg lamp. Set as a var for easy adjusting.
|
||||
@@ -97,6 +100,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
|
||||
hud_possible = list(SPECIALROLE_HUD, DIAG_STAT_HUD, DIAG_HUD, DIAG_BATT_HUD)
|
||||
|
||||
var/default_cell_type = /obj/item/stock_parts/cell/high
|
||||
var/magpulse = 0
|
||||
var/ionpulse = 0 // Jetpack-like effect.
|
||||
var/ionpulse_on = 0 // Jetpack-like effect.
|
||||
@@ -132,7 +136,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
|
||||
init()
|
||||
|
||||
if(!scrambledcodes && !camera)
|
||||
if(has_camera && !camera)
|
||||
camera = new /obj/machinery/camera(src)
|
||||
camera.c_tag = real_name
|
||||
camera.network = list("SS13","Robots")
|
||||
@@ -144,7 +148,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
mmi.icon_state = "boris"
|
||||
|
||||
if(!cell) // Make sure a new cell gets created *before* executing initialize_components(). The cell component needs an existing cell for it to get set up properly
|
||||
cell = new /obj/item/stock_parts/cell/high(src)
|
||||
cell = new default_cell_type(src)
|
||||
|
||||
initialize_components()
|
||||
//if(!unfinished)
|
||||
@@ -288,12 +292,9 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
/mob/living/silicon/robot/proc/pick_module()
|
||||
if(module)
|
||||
return
|
||||
var/list/modules = list("Standard", "Engineering", "Medical", "Miner", "Janitor", "Service", "Security")
|
||||
var/list/modules = list("Generalist", "Engineering", "Medical", "Miner", "Janitor", "Service", "Security")
|
||||
if(islist(force_modules) && force_modules.len)
|
||||
modules = force_modules.Copy()
|
||||
if(GLOB.security_level == (SEC_LEVEL_GAMMA || SEC_LEVEL_EPSILON) || crisis)
|
||||
to_chat(src, "<span class='warning'>Crisis mode active. The combat module is now available.</span>")
|
||||
modules += "Combat"
|
||||
if(mmi != null && mmi.alien)
|
||||
modules = list("Hunter")
|
||||
modtype = input("Please, select a module!", "Robot", null, null) as null|anything in modules
|
||||
@@ -306,9 +307,9 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
return
|
||||
|
||||
switch(modtype)
|
||||
if("Standard")
|
||||
if("Generalist")
|
||||
module = new /obj/item/robot_module/standard(src)
|
||||
module.channels = list("Service" = 1)
|
||||
module.channels = list("Engineering" = 1, "Medical" = 1, "Security" = 1, "Service" = 1)
|
||||
module_sprites["Basic"] = "robot_old"
|
||||
module_sprites["Android"] = "droid"
|
||||
module_sprites["Default"] = "Standard"
|
||||
@@ -337,6 +338,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
module_sprites["Standard"] = "Standard-Mine"
|
||||
module_sprites["Noble-DIG"] = "Noble-DIG"
|
||||
module_sprites["Cricket"] = "Cricket-MINE"
|
||||
module_sprites["Lavaland"] = "lavaland"
|
||||
|
||||
if("Medical")
|
||||
module = new /obj/item/robot_module/medical(src)
|
||||
@@ -353,6 +355,17 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
status_flags &= ~CANPUSH
|
||||
|
||||
if("Security")
|
||||
if(!weapons_unlock)
|
||||
var/count_secborgs = 0
|
||||
for(var/mob/living/silicon/robot/R in GLOB.alive_mob_list)
|
||||
if(R && R.stat != DEAD && R.module && istype(R.module, /obj/item/robot_module/security))
|
||||
count_secborgs++
|
||||
var/max_secborgs = 2
|
||||
if(GLOB.security_level == SEC_LEVEL_GREEN)
|
||||
max_secborgs = 1
|
||||
if(count_secborgs >= max_secborgs)
|
||||
to_chat(src, "<span class='warning'>There are too many Security cyborgs active. Please choose another module.</span>")
|
||||
return
|
||||
module = new /obj/item/robot_module/security(src)
|
||||
module.channels = list("Security" = 1)
|
||||
module_sprites["Basic"] = "secborg"
|
||||
@@ -387,10 +400,16 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
module_sprites["Noble-CLN"] = "Noble-CLN"
|
||||
module_sprites["Cricket"] = "Cricket-JANI"
|
||||
|
||||
if("Combat")
|
||||
module = new /obj/item/robot_module/combat(src)
|
||||
if("Destroyer") // Rolling Borg
|
||||
module = new /obj/item/robot_module/destroyer(src)
|
||||
module.channels = list("Security" = 1)
|
||||
icon_state = "droidcombat"
|
||||
status_flags &= ~CANPUSH
|
||||
|
||||
if("Combat") // Gamma ERT
|
||||
module = new /obj/item/robot_module/combat(src)
|
||||
icon_state = "ertgamma"
|
||||
status_flags &= ~CANPUSH
|
||||
|
||||
if("Hunter")
|
||||
module = new /obj/item/robot_module/alien/hunter(src)
|
||||
@@ -442,6 +461,8 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
ionpulse = FALSE
|
||||
magpulse = FALSE
|
||||
add_language("Robot Talk", 1)
|
||||
if("lava" in weather_immunities) // Remove the lava-immunity effect given by a printable upgrade
|
||||
weather_immunities -= "lava"
|
||||
|
||||
status_flags |= CANPUSH
|
||||
|
||||
@@ -916,7 +937,6 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
return 0
|
||||
|
||||
/mob/living/silicon/robot/update_icons()
|
||||
|
||||
overlays.Cut()
|
||||
if(stat != DEAD && !(paralysis || stunned || IsWeakened() || low_power_mode)) //Not dead, not stunned.
|
||||
if(custom_panel in custom_eye_names)
|
||||
@@ -925,36 +945,24 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
overlays += "eyes-[icon_state]"
|
||||
else
|
||||
overlays -= "eyes"
|
||||
|
||||
if(opened)
|
||||
var/panelprefix = "ov"
|
||||
if(custom_sprite) //Custom borgs also have custom panels, heh
|
||||
panelprefix = "[ckey]"
|
||||
|
||||
if(custom_panel in custom_panel_names) //For default borgs with different panels
|
||||
panelprefix = custom_panel
|
||||
|
||||
if(wiresexposed)
|
||||
overlays += "[panelprefix]-openpanel +w"
|
||||
else if(cell)
|
||||
overlays += "[panelprefix]-openpanel +c"
|
||||
else
|
||||
overlays += "[panelprefix]-openpanel -c"
|
||||
|
||||
var/combat = list("Combat")
|
||||
if(modtype in combat)
|
||||
if(base_icon == "")
|
||||
base_icon = icon_state
|
||||
if(module_active && istype(module_active,/obj/item/borg/combat/mobility))
|
||||
icon_state = "[base_icon]-roll"
|
||||
else
|
||||
icon_state = base_icon
|
||||
if(module)
|
||||
for(var/obj/item/borg/combat/shield/S in module.modules)
|
||||
if(activated(S))
|
||||
overlays += "[base_icon]-shield"
|
||||
borg_icons()
|
||||
update_fire()
|
||||
|
||||
/mob/living/silicon/robot/proc/borg_icons() // Exists so that robot/destroyer can override it
|
||||
return
|
||||
|
||||
/mob/living/silicon/robot/proc/installed_modules()
|
||||
if(weapon_lock)
|
||||
to_chat(src, "<span class='warning'>Weapon lock active, unable to use modules! Count:[weaponlock_time]</span>")
|
||||
@@ -1309,56 +1317,52 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
..()
|
||||
update_module_icon()
|
||||
|
||||
/mob/living/silicon/robot/emp_act(severity)
|
||||
if(emp_protection)
|
||||
return
|
||||
..()
|
||||
switch(severity)
|
||||
if(1)
|
||||
disable_component("comms", 160)
|
||||
if(2)
|
||||
disable_component("comms", 60)
|
||||
|
||||
/mob/living/silicon/robot/deathsquad
|
||||
base_icon = "nano_bloodhound"
|
||||
icon_state = "nano_bloodhound"
|
||||
designation = "SpecOps"
|
||||
lawupdate = 0
|
||||
scrambledcodes = 1
|
||||
has_camera = FALSE
|
||||
req_one_access = list(ACCESS_CENT_SPECOPS)
|
||||
ionpulse = 1
|
||||
magpulse = 1
|
||||
pdahide = 1
|
||||
eye_protection = 2 // Immunity to flashes and the visual part of flashbangs
|
||||
ear_protection = 1 // Immunity to the audio part of flashbangs
|
||||
damage_protection = 10 // Reduce all incoming damage by this number
|
||||
xeno_disarm_chance = 20
|
||||
allow_rename = FALSE
|
||||
modtype = "Commando"
|
||||
faction = list("nanotrasen")
|
||||
is_emaggable = FALSE
|
||||
|
||||
/mob/living/silicon/robot/deathsquad/New(loc)
|
||||
..()
|
||||
cell = new /obj/item/stock_parts/cell/hyper(src)
|
||||
default_cell_type = /obj/item/stock_parts/cell/bluespace
|
||||
|
||||
/mob/living/silicon/robot/deathsquad/init()
|
||||
laws = new /datum/ai_laws/deathsquad
|
||||
module = new /obj/item/robot_module/deathsquad(src)
|
||||
|
||||
aiCamera = new/obj/item/camera/siliconcam/robot_camera(src)
|
||||
radio = new /obj/item/radio/borg/deathsquad(src)
|
||||
radio.recalculateChannels()
|
||||
|
||||
playsound(loc, 'sound/mecha/nominalsyndi.ogg', 75, 0)
|
||||
|
||||
/mob/living/silicon/robot/combat
|
||||
base_icon = "droidcombat"
|
||||
icon_state = "droidcombat"
|
||||
modtype = "Combat"
|
||||
designation = "Combat"
|
||||
/mob/living/silicon/robot/deathsquad/bullet_act(var/obj/item/projectile/P)
|
||||
if(istype(P) && P.is_reflectable && P.starting)
|
||||
visible_message("<span class='danger'>The [P.name] gets reflected by [src]!</span>", "<span class='userdanger'>The [P.name] gets reflected by [src]!</span>")
|
||||
P.reflect_back(src)
|
||||
return -1
|
||||
return ..(P)
|
||||
|
||||
/mob/living/silicon/robot/combat/init()
|
||||
..()
|
||||
module = new /obj/item/robot_module/combat(src)
|
||||
module.channels = list("Security" = 1)
|
||||
//languages
|
||||
module.add_languages(src)
|
||||
//subsystems
|
||||
module.add_subsystems_and_actions(src)
|
||||
|
||||
status_flags &= ~CANPUSH
|
||||
|
||||
radio.config(module.channels)
|
||||
notify_ai(2)
|
||||
|
||||
/mob/living/silicon/robot/ert
|
||||
designation = "ERT"
|
||||
@@ -1366,11 +1370,12 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
scrambledcodes = 1
|
||||
req_one_access = list(ACCESS_CENT_SPECOPS)
|
||||
ionpulse = 1
|
||||
|
||||
force_modules = list("Engineering", "Medical", "Security")
|
||||
static_radio_channels = 1
|
||||
allow_rename = FALSE
|
||||
weapons_unlock = TRUE
|
||||
default_cell_type = /obj/item/stock_parts/cell/super
|
||||
var/eprefix = "Amber"
|
||||
|
||||
|
||||
/mob/living/silicon/robot/ert/init()
|
||||
@@ -1379,11 +1384,10 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
radio.recalculateChannels()
|
||||
aiCamera = new/obj/item/camera/siliconcam/robot_camera(src)
|
||||
|
||||
/mob/living/silicon/robot/ert/New(loc, cyborg_unlock)
|
||||
/mob/living/silicon/robot/ert/New(loc)
|
||||
..(loc)
|
||||
cell = new /obj/item/stock_parts/cell/hyper(src)
|
||||
var/rnum = rand(1,1000)
|
||||
var/borgname = "ERT [rnum]"
|
||||
var/borgname = "[eprefix] ERT [rnum]"
|
||||
name = borgname
|
||||
custom_name = borgname
|
||||
real_name = name
|
||||
@@ -1392,22 +1396,64 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
|
||||
mind.original = src
|
||||
mind.assigned_role = SPECIAL_ROLE_ERT
|
||||
mind.special_role = SPECIAL_ROLE_ERT
|
||||
if(cyborg_unlock)
|
||||
crisis = 1
|
||||
if(!(mind in SSticker.minds))
|
||||
SSticker.minds += mind
|
||||
SSticker.mode.ert += mind
|
||||
|
||||
/mob/living/silicon/robot/ert/gamma
|
||||
crisis = 1
|
||||
|
||||
/mob/living/silicon/robot/emp_act(severity)
|
||||
/mob/living/silicon/robot/ert/red
|
||||
eprefix = "Red"
|
||||
default_cell_type = /obj/item/stock_parts/cell/hyper
|
||||
|
||||
/mob/living/silicon/robot/ert/gamma
|
||||
default_cell_type = /obj/item/stock_parts/cell/bluespace
|
||||
force_modules = list("Combat", "Engineering", "Medical")
|
||||
damage_protection = 5 // Reduce all incoming damage by this number
|
||||
eprefix = "Gamma"
|
||||
magpulse = 1
|
||||
xeno_disarm_chance = 40
|
||||
|
||||
|
||||
/mob/living/silicon/robot/destroyer
|
||||
// admin-only borg, the seraph / special ops officer of borgs
|
||||
base_icon = "droidcombat"
|
||||
icon_state = "droidcombat"
|
||||
modtype = "Destroyer"
|
||||
designation = "Destroyer"
|
||||
lawupdate = 0
|
||||
scrambledcodes = 1
|
||||
has_camera = FALSE
|
||||
req_one_access = list(ACCESS_CENT_SPECOPS)
|
||||
ionpulse = 1
|
||||
magpulse = 1
|
||||
pdahide = 1
|
||||
eye_protection = 2 // Immunity to flashes and the visual part of flashbangs
|
||||
ear_protection = 1 // Immunity to the audio part of flashbangs
|
||||
emp_protection = TRUE // Immunity to EMP, due to heavy shielding
|
||||
damage_protection = 20 // Reduce all incoming damage by this number. Very high in the case of /destroyer borgs, since it is an admin-only borg.
|
||||
xeno_disarm_chance = 10
|
||||
default_cell_type = /obj/item/stock_parts/cell/bluespace
|
||||
|
||||
/mob/living/silicon/robot/destroyer/init()
|
||||
..()
|
||||
switch(severity)
|
||||
if(1)
|
||||
disable_component("comms", 160)
|
||||
if(2)
|
||||
disable_component("comms", 60)
|
||||
module = new /obj/item/robot_module/destroyer(src)
|
||||
module.add_languages(src)
|
||||
module.add_subsystems_and_actions(src)
|
||||
status_flags &= ~CANPUSH
|
||||
if(radio)
|
||||
qdel(radio)
|
||||
radio = new /obj/item/radio/borg/ert/specops(src)
|
||||
radio.recalculateChannels()
|
||||
|
||||
/mob/living/silicon/robot/destroyer/borg_icons()
|
||||
if(base_icon == "")
|
||||
base_icon = icon_state
|
||||
if(module_active && istype(module_active,/obj/item/borg/destroyer/mobility))
|
||||
icon_state = "[base_icon]-roll"
|
||||
else
|
||||
icon_state = base_icon
|
||||
overlays += "[base_icon]-shield"
|
||||
|
||||
|
||||
/mob/living/silicon/robot/extinguish_light()
|
||||
update_headlamp(1, 150)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user