mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2025-12-28 19:11:37 +00:00
Merge resolution.
This commit is contained in:
@@ -5,7 +5,7 @@ world/IsBanned(key,address,computer_id)
|
||||
return ..()
|
||||
|
||||
//Guest Checking
|
||||
if(!guests_allowed && IsGuestKey(key))
|
||||
if(!config.guests_allowed && IsGuestKey(key))
|
||||
log_access("Failed Login: [key] - Guests not allowed")
|
||||
message_admins("\blue Failed Login: [key] - Guests not allowed")
|
||||
return list("reason"="guest", "desc"="\nReason: Guests not allowed. Please sign in with a byond account.")
|
||||
|
||||
@@ -5,7 +5,7 @@ var/global/floorIsLava = 0
|
||||
|
||||
////////////////////////////////
|
||||
/proc/message_admins(var/msg)
|
||||
msg = "<span class=\"admin\"><span class=\"prefix\">ADMIN LOG:</span> <span class=\"message\">[msg]</span></span>"
|
||||
msg = "<span class=\"log_message\"><span class=\"prefix\">ADMIN LOG:</span> <span class=\"message\">[msg]</span></span>"
|
||||
log_adminwarn(msg)
|
||||
for(var/client/C in admins)
|
||||
if(R_ADMIN & C.holder.rights)
|
||||
@@ -13,7 +13,7 @@ var/global/floorIsLava = 0
|
||||
|
||||
/proc/msg_admin_attack(var/text) //Toggleable Attack Messages
|
||||
log_attack(text)
|
||||
var/rendered = "<span class=\"admin\"><span class=\"prefix\">ATTACK:</span> <span class=\"message\">[text]</span></span>"
|
||||
var/rendered = "<span class=\"log_message\"><span class=\"prefix\">ATTACK:</span> <span class=\"message\">[text]</span></span>"
|
||||
for(var/client/C in admins)
|
||||
if(R_ADMIN & C.holder.rights)
|
||||
if(C.prefs.toggles & CHAT_ATTACKLOGS)
|
||||
@@ -169,17 +169,29 @@ var/global/floorIsLava = 0
|
||||
<A href='?src=\ref[src];simplemake=shade;mob=\ref[M]'>Shade</A>
|
||||
<br>
|
||||
"}
|
||||
|
||||
if (M.client)
|
||||
body += {"<br><br>
|
||||
body += {"<br><br>
|
||||
<b>Other actions:</b>
|
||||
<br>
|
||||
<A href='?src=\ref[src];forcespeech=\ref[M]'>Forcesay</A> |
|
||||
<A href='?src=\ref[src];forcespeech=\ref[M]'>Forcesay</A>
|
||||
"}
|
||||
if (M.client)
|
||||
body += {" |
|
||||
<A href='?src=\ref[src];tdome1=\ref[M]'>Thunderdome 1</A> |
|
||||
<A href='?src=\ref[src];tdome2=\ref[M]'>Thunderdome 2</A> |
|
||||
<A href='?src=\ref[src];tdomeadmin=\ref[M]'>Thunderdome Admin</A> |
|
||||
<A href='?src=\ref[src];tdomeobserve=\ref[M]'>Thunderdome Observer</A> |
|
||||
"}
|
||||
// language toggles
|
||||
body += "<br><br><b>Languages:</b><br>"
|
||||
var/f = 1
|
||||
for(var/k in all_languages)
|
||||
var/datum/language/L = all_languages[k]
|
||||
if(!f) body += " | "
|
||||
else f = 0
|
||||
if(L in M.languages)
|
||||
body += "<a href='?src=\ref[src];toglang=\ref[M];lang=[html_encode(k)]' style='color:#006600'>[k]</a>"
|
||||
else
|
||||
body += "<a href='?src=\ref[src];toglang=\ref[M];lang=[html_encode(k)]' style='color:#ff0000'>[k]</a>"
|
||||
|
||||
body += {"<br>
|
||||
</body></html>
|
||||
@@ -723,8 +735,8 @@ var/global/floorIsLava = 0
|
||||
set category = "Server"
|
||||
set desc="Globally Toggles OOC"
|
||||
set name="Toggle OOC"
|
||||
ooc_allowed = !( ooc_allowed )
|
||||
if (ooc_allowed)
|
||||
config.ooc_allowed = !(config.ooc_allowed)
|
||||
if (config.ooc_allowed)
|
||||
world << "<B>The OOC channel has been globally enabled!</B>"
|
||||
else
|
||||
world << "<B>The OOC channel has been globally disabled!</B>"
|
||||
@@ -737,8 +749,8 @@ var/global/floorIsLava = 0
|
||||
set category = "Server"
|
||||
set desc="Globally Toggles DSAY"
|
||||
set name="Toggle DSAY"
|
||||
dsay_allowed = !( dsay_allowed )
|
||||
if (dsay_allowed)
|
||||
config.dsay_allowed = !(config.dsay_allowed)
|
||||
if (config.dsay_allowed)
|
||||
world << "<B>Deadchat has been globally enabled!</B>"
|
||||
else
|
||||
world << "<B>Deadchat has been globally disabled!</B>"
|
||||
@@ -748,11 +760,10 @@ var/global/floorIsLava = 0
|
||||
|
||||
/datum/admins/proc/toggleoocdead()
|
||||
set category = "Server"
|
||||
set desc="Toggle dis bitch"
|
||||
set desc="Toggle Dead OOC."
|
||||
set name="Toggle Dead OOC"
|
||||
dooc_allowed = !( dooc_allowed )
|
||||
|
||||
log_admin("[key_name(usr)] toggled OOC.")
|
||||
config.dooc_allowed = !( config.dooc_allowed )
|
||||
log_admin("[key_name(usr)] toggled Dead OOC.")
|
||||
message_admins("[key_name_admin(usr)] toggled Dead OOC.", 1)
|
||||
feedback_add_details("admin_verb","TDOOC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -760,9 +771,9 @@ var/global/floorIsLava = 0
|
||||
set category = "Server"
|
||||
set desc="Toggle traitor scaling"
|
||||
set name="Toggle Traitor Scaling"
|
||||
traitor_scaling = !traitor_scaling
|
||||
log_admin("[key_name(usr)] toggled Traitor Scaling to [traitor_scaling].")
|
||||
message_admins("[key_name_admin(usr)] toggled Traitor Scaling [traitor_scaling ? "on" : "off"].", 1)
|
||||
config.traitor_scaling = !config.traitor_scaling
|
||||
log_admin("[key_name(usr)] toggled Traitor Scaling to [config.traitor_scaling].")
|
||||
message_admins("[key_name_admin(usr)] toggled Traitor Scaling [config.traitor_scaling ? "on" : "off"].", 1)
|
||||
feedback_add_details("admin_verb","TTS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/datum/admins/proc/startnow()
|
||||
@@ -786,8 +797,8 @@ var/global/floorIsLava = 0
|
||||
set category = "Server"
|
||||
set desc="People can't enter"
|
||||
set name="Toggle Entering"
|
||||
enter_allowed = !( enter_allowed )
|
||||
if (!( enter_allowed ))
|
||||
config.enter_allowed = !(config.enter_allowed)
|
||||
if (!(config.enter_allowed))
|
||||
world << "<B>New players may no longer enter the game.</B>"
|
||||
else
|
||||
world << "<B>New players may now enter the game.</B>"
|
||||
@@ -813,13 +824,13 @@ var/global/floorIsLava = 0
|
||||
set category = "Server"
|
||||
set desc="Respawn basically"
|
||||
set name="Toggle Respawn"
|
||||
abandon_allowed = !( abandon_allowed )
|
||||
if (abandon_allowed)
|
||||
config.abandon_allowed = !(config.abandon_allowed)
|
||||
if(config.abandon_allowed)
|
||||
world << "<B>You may now respawn.</B>"
|
||||
else
|
||||
world << "<B>You may no longer respawn :(</B>"
|
||||
message_admins("\blue [key_name_admin(usr)] toggled respawn to [abandon_allowed ? "On" : "Off"].", 1)
|
||||
log_admin("[key_name(usr)] toggled respawn to [abandon_allowed ? "On" : "Off"].")
|
||||
message_admins("\blue [key_name_admin(usr)] toggled respawn to [config.abandon_allowed ? "On" : "Off"].", 1)
|
||||
log_admin("[key_name(usr)] toggled respawn to [config.abandon_allowed ? "On" : "Off"].")
|
||||
world.update_status()
|
||||
feedback_add_details("admin_verb","TR") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -827,18 +838,18 @@ var/global/floorIsLava = 0
|
||||
set category = "Server"
|
||||
set desc="Toggle alien mobs"
|
||||
set name="Toggle Aliens"
|
||||
aliens_allowed = !aliens_allowed
|
||||
log_admin("[key_name(usr)] toggled Aliens to [aliens_allowed].")
|
||||
message_admins("[key_name_admin(usr)] toggled Aliens [aliens_allowed ? "on" : "off"].", 1)
|
||||
config.aliens_allowed = !config.aliens_allowed
|
||||
log_admin("[key_name(usr)] toggled Aliens to [config.aliens_allowed].")
|
||||
message_admins("[key_name_admin(usr)] toggled Aliens [config.aliens_allowed ? "on" : "off"].", 1)
|
||||
feedback_add_details("admin_verb","TA") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/datum/admins/proc/toggle_space_ninja()
|
||||
set category = "Server"
|
||||
set desc="Toggle space ninjas spawning."
|
||||
set name="Toggle Space Ninjas"
|
||||
toggle_space_ninja = !toggle_space_ninja
|
||||
log_admin("[key_name(usr)] toggled Space Ninjas to [toggle_space_ninja].")
|
||||
message_admins("[key_name_admin(usr)] toggled Space Ninjas [toggle_space_ninja ? "on" : "off"].", 1)
|
||||
config.ninjas_allowed = !config.ninjas_allowed
|
||||
log_admin("[key_name(usr)] toggled Space Ninjas to [config.ninjas_allowed].")
|
||||
message_admins("[key_name_admin(usr)] toggled Space Ninjas [config.ninjas_allowed ? "on" : "off"].", 1)
|
||||
feedback_add_details("admin_verb","TSN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/datum/admins/proc/delay()
|
||||
@@ -973,7 +984,7 @@ var/global/floorIsLava = 0
|
||||
if(3)
|
||||
var/count = 0
|
||||
for(var/mob/living/carbon/monkey/Monkey in world)
|
||||
if(Monkey.z == 1)
|
||||
if(Monkey.z in station_levels)
|
||||
count++
|
||||
return "Kill all [count] of the monkeys on the station"
|
||||
if(4)
|
||||
@@ -1036,26 +1047,26 @@ var/global/floorIsLava = 0
|
||||
set category = "Debug"
|
||||
set desc="Reduces view range when wearing welding helmets"
|
||||
set name="Toggle tinted welding helmes"
|
||||
tinted_weldhelh = !( tinted_weldhelh )
|
||||
if (tinted_weldhelh)
|
||||
world << "<B>The tinted_weldhelh has been enabled!</B>"
|
||||
config.welder_vision = !( config.welder_vision )
|
||||
if (config.welder_vision)
|
||||
world << "<B>Reduced welder vision has been enabled!</B>"
|
||||
else
|
||||
world << "<B>The tinted_weldhelh has been disabled!</B>"
|
||||
log_admin("[key_name(usr)] toggled tinted_weldhelh.")
|
||||
message_admins("[key_name_admin(usr)] toggled tinted_weldhelh.", 1)
|
||||
world << "<B>Reduced welder vision has been disabled!</B>"
|
||||
log_admin("[key_name(usr)] toggled welder vision.")
|
||||
message_admins("[key_name_admin(usr)] toggled welder vision.", 1)
|
||||
feedback_add_details("admin_verb","TTWH") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/datum/admins/proc/toggleguests()
|
||||
set category = "Server"
|
||||
set desc="Guests can't enter"
|
||||
set name="Toggle guests"
|
||||
guests_allowed = !( guests_allowed )
|
||||
if (!( guests_allowed ))
|
||||
config.guests_allowed = !(config.guests_allowed)
|
||||
if (!(config.guests_allowed))
|
||||
world << "<B>Guests may no longer enter the game.</B>"
|
||||
else
|
||||
world << "<B>Guests may now enter the game.</B>"
|
||||
log_admin("[key_name(usr)] toggled guests game entering [guests_allowed?"":"dis"]allowed.")
|
||||
message_admins("\blue [key_name_admin(usr)] toggled guests game entering [guests_allowed?"":"dis"]allowed.", 1)
|
||||
log_admin("[key_name(usr)] toggled guests game entering [config.guests_allowed?"":"dis"]allowed.")
|
||||
message_admins("\blue [key_name_admin(usr)] toggled guests game entering [config.guests_allowed?"":"dis"]allowed.", 1)
|
||||
feedback_add_details("admin_verb","TGU") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/datum/admins/proc/output_ai_laws()
|
||||
|
||||
@@ -76,7 +76,8 @@ var/list/admin_verbs_admin = list(
|
||||
/client/proc/response_team, // Response Teams admin verb
|
||||
/client/proc/toggle_antagHUD_use,
|
||||
/client/proc/toggle_antagHUD_restrictions,
|
||||
/client/proc/allow_character_respawn /* Allows a ghost to respawn */
|
||||
/client/proc/allow_character_respawn, /* Allows a ghost to respawn */
|
||||
/client/proc/event_manager_panel
|
||||
)
|
||||
var/list/admin_verbs_ban = list(
|
||||
/client/proc/unban_panel,
|
||||
@@ -101,7 +102,6 @@ var/list/admin_verbs_fun = list(
|
||||
/client/proc/cmd_admin_add_random_ai_law,
|
||||
/client/proc/make_sound,
|
||||
/client/proc/toggle_random_events,
|
||||
/client/proc/set_ooc,
|
||||
/client/proc/editappear
|
||||
)
|
||||
var/list/admin_verbs_spawn = list(
|
||||
@@ -175,7 +175,6 @@ var/list/admin_verbs_rejuv = list(
|
||||
|
||||
//verbs which can be hidden - needs work
|
||||
var/list/admin_verbs_hideable = list(
|
||||
/client/proc/set_ooc,
|
||||
/client/proc/deadmin_self,
|
||||
// /client/proc/deadchat,
|
||||
/client/proc/toggleprayers,
|
||||
@@ -387,7 +386,8 @@ var/list/admin_verbs_mentor = list(
|
||||
else
|
||||
//ghostize
|
||||
var/mob/body = mob
|
||||
body.ghostize(1)
|
||||
var/mob/dead/observer/ghost = body.ghostize(1)
|
||||
ghost.admin_ghosted = 1
|
||||
if(body && !body.key)
|
||||
body.key = "@[key]" //Haaaaaaaack. But the people have spoken. If it breaks; blame adminbus
|
||||
feedback_add_details("admin_verb","O") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
@@ -475,10 +475,13 @@ var/list/admin_verbs_mentor = list(
|
||||
set category = "Fun"
|
||||
set name = "OOC Text Color"
|
||||
if(!holder) return
|
||||
var/new_ooccolor = input(src, "Please select your OOC colour.", "OOC colour") as color|null
|
||||
if(new_ooccolor)
|
||||
prefs.ooccolor = new_ooccolor
|
||||
prefs.save_preferences()
|
||||
var/response = alert(src, "Please choose a distinct color that is easy to read and doesn't mix with all the other chat and radio frequency colors.", "Change own OOC color", "Pick new color", "Reset to default", "Cancel")
|
||||
if(response == "Pick new color")
|
||||
prefs.ooccolor = input(src, "Please select your OOC colour.", "OOC colour") as color
|
||||
else if(response == "Reset to default")
|
||||
prefs.ooccolor = initial(prefs.ooccolor)
|
||||
prefs.save_preferences()
|
||||
|
||||
feedback_add_details("admin_verb","OC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
return
|
||||
|
||||
|
||||
@@ -411,14 +411,14 @@
|
||||
|
||||
dat += "<a href='?src=\ref[src];delay_round_end=1'>[ticker.delay_end ? "End Round Normally" : "Delay Round End"]</a><br>"
|
||||
if(ticker.mode.syndicates.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Syndicates</B></td><td></td></tr>"
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Mercenaries</B></td><td></td></tr>"
|
||||
for(var/datum/mind/N in ticker.mode.syndicates)
|
||||
var/mob/M = N.current
|
||||
if(M)
|
||||
dat += "<tr><td><a href='?src=\ref[src];adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(logged out)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?src=\ref[usr];priv_msg=\ref[M]'>PM</A></td></tr>"
|
||||
else
|
||||
dat += "<tr><td><i>Nuclear Operative not found!</i></td></tr>"
|
||||
dat += "<tr><td><i>Mercenary not found!</i></td></tr>"
|
||||
dat += "</table><br><table><tr><td><B>Nuclear Disk(s)</B></td></tr>"
|
||||
for(var/obj/item/weapon/disk/nuclear/N in world)
|
||||
dat += "<tr><td>[N.name], "
|
||||
|
||||
@@ -582,9 +582,9 @@
|
||||
|
||||
//Nuke Operative
|
||||
if(jobban_isbanned(M, "operative") || isbanned_dept)
|
||||
jobs += "<td width='20%'><a href='?src=\ref[src];jobban3=operative;jobban4=\ref[M]'><font color=red>[replacetext("Nuke Operative", " ", " ")]</font></a></td>"
|
||||
jobs += "<td width='20%'><a href='?src=\ref[src];jobban3=operative;jobban4=\ref[M]'><font color=red>[replacetext("Mercenary", " ", " ")]</font></a></td>"
|
||||
else
|
||||
jobs += "<td width='20%'><a href='?src=\ref[src];jobban3=operative;jobban4=\ref[M]'>[replacetext("Nuke Operative", " ", " ")]</a></td>"
|
||||
jobs += "<td width='20%'><a href='?src=\ref[src];jobban3=operative;jobban4=\ref[M]'>[replacetext("Mercenary", " ", " ")]</a></td>"
|
||||
|
||||
//Revolutionary
|
||||
if(jobban_isbanned(M, "revolutionary") || isbanned_dept)
|
||||
@@ -643,6 +643,12 @@
|
||||
else
|
||||
jobs += "<td width='20%'><a href='?src=\ref[src];jobban3=Dionaea;jobban4=\ref[M]'>Dionaea</a></td>"
|
||||
|
||||
if(jobban_isbanned(M, "Borer"))
|
||||
jobs += "<td width='20%'><a href='?src=\ref[src];jobban3=Borer;jobban4=\ref[M]'><font color=red>Borer</font></a></td>"
|
||||
else
|
||||
jobs += "<td width='20%'><a href='?src=\ref[src];jobban3=Borer;jobban4=\ref[M]'>Borer</a></td>"
|
||||
|
||||
|
||||
jobs += "</tr></table>"
|
||||
|
||||
|
||||
@@ -1283,11 +1289,11 @@
|
||||
foo += text("<B>Is an AI</B> | ")
|
||||
else
|
||||
foo += text("<A HREF='?src=\ref[];makeai=\ref[]'>Make AI</A> | ", src, M)
|
||||
if(M.z != 2)
|
||||
if(isNotAdminLevel(M.z))
|
||||
foo += text("<A HREF='?src=\ref[];sendtoprison=\ref[]'>Prison</A> | ", src, M)
|
||||
foo += text("<A HREF='?src=\ref[];sendtomaze=\ref[]'>Maze</A> | ", src, M)
|
||||
else
|
||||
foo += text("<B>On Z = 2</B> | ")
|
||||
foo += text("<B>On Z = [M.z]</B> | ")
|
||||
else
|
||||
foo += text("<B>Hasn't Entered Game</B> | ")
|
||||
foo += text("<A HREF='?src=\ref[];revive=\ref[]'>Heal/Revive</A> | ", src, M)
|
||||
@@ -1476,68 +1482,96 @@
|
||||
usr << "The person you are trying to contact is not wearing a headset"
|
||||
return
|
||||
|
||||
var/input = input(src.owner, "Please enter a message to reply to [key_name(H)] via their headset.","Outgoing message from The Syndicate", "")
|
||||
var/input = input(src.owner, "Please enter a message to reply to [key_name(H)] via their headset.","Outgoing message from a shadowy figure...", "")
|
||||
if(!input) return
|
||||
|
||||
src.owner << "You sent [input] to [H] via a secure channel."
|
||||
log_admin("[src.owner] replied to [key_name(H)]'s Syndicate message with the message [input].")
|
||||
log_admin("[src.owner] replied to [key_name(H)]'s illegal message with the message [input].")
|
||||
H << "You hear something crackle in your headset for a moment before a voice speaks. \"Please stand by for a message from your benefactor. Message as follows, agent. <b>\"[input]\"</b> Message ends.\""
|
||||
|
||||
else if(href_list["CentcommFaxView"])
|
||||
var/info = locate(href_list["CentcommFaxView"])
|
||||
else if(href_list["AdminFaxView"])
|
||||
var/obj/item/fax = locate(href_list["AdminFaxView"])
|
||||
if (istype(fax, /obj/item/weapon/paper))
|
||||
var/obj/item/weapon/paper/P = fax
|
||||
P.show_content(usr)
|
||||
else if (istype(fax, /obj/item/weapon/photo))
|
||||
var/obj/item/weapon/photo/H = fax
|
||||
H.show(usr)
|
||||
else if (istype(fax, /obj/item/weapon/paper_bundle))
|
||||
//having multiple people turning pages on a paper_bundle can cause issues
|
||||
//open a browse window listing the contents instead
|
||||
var/data = ""
|
||||
var/obj/item/weapon/paper_bundle/B = fax
|
||||
|
||||
usr << browse("<HTML><HEAD><TITLE>Centcomm Fax Message</TITLE></HEAD><BODY>[info]</BODY></HTML>", "window=Centcomm Fax Message")
|
||||
for (var/page = 1, page <= B.amount, page++)
|
||||
var/obj/pageobj = B.contents[page]
|
||||
data += "<A href='?src=\ref[src];AdminFaxViewPage=[page];paper_bundle=\ref[B]'>Page [page] - [pageobj.name]</A><BR>"
|
||||
|
||||
usr << browse(data, "window=[B.name]")
|
||||
else
|
||||
usr << "\red The faxed item is not viewable. This is probably a bug, and should be reported on the tracker: [fax.type]"
|
||||
|
||||
else if (href_list["AdminFaxViewPage"])
|
||||
var/page = text2num(href_list["AdminFaxViewPage"])
|
||||
var/obj/item/weapon/paper_bundle/bundle = locate(href_list["paper_bundle"])
|
||||
|
||||
if (!bundle) return
|
||||
|
||||
if (istype(bundle.contents[page], /obj/item/weapon/paper))
|
||||
var/obj/item/weapon/paper/P = bundle.contents[page]
|
||||
P.show_content(src.owner, 1)
|
||||
else if (istype(bundle.contents[page], /obj/item/weapon/photo))
|
||||
var/obj/item/weapon/photo/H = bundle.contents[page]
|
||||
H.show(src.owner)
|
||||
return
|
||||
|
||||
else if(href_list["CentcommFaxReply"])
|
||||
var/mob/living/carbon/human/H = locate(href_list["CentcommFaxReply"])
|
||||
var/obj/machinery/faxmachine/fax = locate(href_list["originfax"])
|
||||
var/mob/sender = locate(href_list["CentcommFaxReply"])
|
||||
var/obj/machinery/photocopier/faxmachine/fax = locate(href_list["originfax"])
|
||||
|
||||
var/input = input(src.owner, "Please enter a message to reply to [key_name(H)] via secure connection. NOTE: BBCode does not work, but HTML tags do! Use <br> for line breaks.", "Outgoing message from Centcomm", "") as message|null
|
||||
var/input = input(src.owner, "Please enter a message to reply to [key_name(sender)] via secure connection. NOTE: BBCode does not work, but HTML tags do! Use <br> for line breaks.", "Outgoing message from Centcomm", "") as message|null
|
||||
if(!input) return
|
||||
|
||||
var/customname = input(src.owner, "Pick a title for the report", "Title") as text|null
|
||||
|
||||
for(var/obj/machinery/faxmachine/F in machines)
|
||||
if(F == fax)
|
||||
if(! (F.stat & (BROKEN|NOPOWER) ) )
|
||||
// Create the reply message
|
||||
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper( null ) //hopefully the null loc won't cause trouble for us
|
||||
P.name = "[command_name()]- [customname]"
|
||||
P.info = input
|
||||
P.update_icon()
|
||||
|
||||
// animate! it's alive!
|
||||
flick("faxreceive", F)
|
||||
// Stamps
|
||||
var/image/stampoverlay = image('icons/obj/bureaucracy.dmi')
|
||||
stampoverlay.icon_state = "paper_stamp-cent"
|
||||
if(!P.stamped)
|
||||
P.stamped = new
|
||||
P.stamped += /obj/item/weapon/stamp
|
||||
P.overlays += stampoverlay
|
||||
P.stamps += "<HR><i>This paper has been stamped by the Central Command Quantum Relay.</i>"
|
||||
|
||||
// give the sprite some time to flick
|
||||
spawn(20)
|
||||
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper( F.loc )
|
||||
P.name = "[command_name()]- [customname]"
|
||||
P.info = input
|
||||
P.update_icon()
|
||||
if(fax.recievefax(P))
|
||||
src.owner << "\blue Message reply to transmitted successfully."
|
||||
log_admin("[key_name(src.owner)] replied to a fax message from [key_name(sender)]: [input]")
|
||||
message_admins("[key_name_admin(src.owner)] replied to a fax message from [key_name_admin(sender)]", 1)
|
||||
else
|
||||
src.owner << "\red Message reply failed."
|
||||
|
||||
playsound(F.loc, "sound/items/polaroid1.ogg", 50, 1)
|
||||
|
||||
// Stamps
|
||||
var/image/stampoverlay = image('icons/obj/bureaucracy.dmi')
|
||||
stampoverlay.icon_state = "paper_stamp-cent"
|
||||
if(!P.stamped)
|
||||
P.stamped = new
|
||||
P.stamped += /obj/item/weapon/stamp
|
||||
P.overlays += stampoverlay
|
||||
P.stamps += "<HR><i>This paper has been stamped by the Central Command Quantum Relay.</i>"
|
||||
|
||||
src.owner << "Message reply to transmitted successfully."
|
||||
log_admin("[key_name(src.owner)] replied to a fax message from [key_name(H)]: [input]")
|
||||
message_admins("[key_name_admin(src.owner)] replied to a fax message from [key_name_admin(H)]", 1)
|
||||
return
|
||||
src.owner << "/red Unable to locate fax!"
|
||||
spawn(100)
|
||||
del(P)
|
||||
return
|
||||
|
||||
else if(href_list["SolGovFaxReply"])
|
||||
//TODO
|
||||
/*
|
||||
var/mob/living/carbon/human/H = locate(href_list["SolGovFaxReply"])
|
||||
var/obj/machinery/faxmachine/fax = locate(href_list["originfax"])
|
||||
var/obj/machinery/photocopier/faxmachine/fax = locate(href_list["originfax"])
|
||||
|
||||
var/input = input(src.owner, "Please enter a message to reply to [key_name(H)] via secure connection. NOTE: BBCode does not work, but HTML tags do! Use <br> for line breaks.", "Outgoing message from Centcomm", "") as message|null
|
||||
if(!input) return
|
||||
|
||||
var/customname = input(src.owner, "Pick a title for the report", "Title") as text|null
|
||||
|
||||
for(var/obj/machinery/faxmachine/F in machines)
|
||||
for(var/obj/machinery/photocopier/faxmachine/F in machines)
|
||||
if(F == fax)
|
||||
if(! (F.stat & (BROKEN|NOPOWER) ) )
|
||||
|
||||
@@ -1567,6 +1601,7 @@
|
||||
message_admins("[key_name_admin(src.owner)] replied to a fax message from [key_name_admin(H)]", 1)
|
||||
return
|
||||
src.owner << "/red Unable to locate fax!"
|
||||
*/
|
||||
|
||||
|
||||
|
||||
@@ -1737,7 +1772,7 @@
|
||||
else
|
||||
var/atom/O = new path(target)
|
||||
if(O)
|
||||
O.dir = obj_dir
|
||||
O.set_dir(obj_dir)
|
||||
if(obj_name)
|
||||
O.name = obj_name
|
||||
if(istype(O,/mob))
|
||||
@@ -2084,18 +2119,18 @@
|
||||
if("togglebombcap")
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","BC")
|
||||
switch(MAX_EXPLOSION_RANGE)
|
||||
if(14) MAX_EXPLOSION_RANGE = 16
|
||||
if(16) MAX_EXPLOSION_RANGE = 20
|
||||
if(20) MAX_EXPLOSION_RANGE = 28
|
||||
if(28) MAX_EXPLOSION_RANGE = 56
|
||||
if(56) MAX_EXPLOSION_RANGE = 128
|
||||
if(128) MAX_EXPLOSION_RANGE = 14
|
||||
var/range_dev = MAX_EXPLOSION_RANGE *0.25
|
||||
var/range_high = MAX_EXPLOSION_RANGE *0.5
|
||||
var/range_low = MAX_EXPLOSION_RANGE
|
||||
switch(max_explosion_range)
|
||||
if(14) max_explosion_range = 16
|
||||
if(16) max_explosion_range = 20
|
||||
if(20) max_explosion_range = 28
|
||||
if(28) max_explosion_range = 56
|
||||
if(56) max_explosion_range = 128
|
||||
if(128) max_explosion_range = 14
|
||||
var/range_dev = max_explosion_range *0.25
|
||||
var/range_high = max_explosion_range *0.5
|
||||
var/range_low = max_explosion_range
|
||||
message_admins("\red <b> [key_name_admin(usr)] changed the bomb cap to [range_dev], [range_high], [range_low]</b>", 1)
|
||||
log_admin("[key_name_admin(usr)] changed the bomb cap to [MAX_EXPLOSION_RANGE]")
|
||||
log_admin("[key_name_admin(usr)] changed the bomb cap to [max_explosion_range]")
|
||||
|
||||
if("flicklights")
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
@@ -2199,7 +2234,7 @@
|
||||
if("aliens")
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","AL")
|
||||
if(aliens_allowed)
|
||||
if(config.aliens_allowed)
|
||||
new /datum/event/alien_infestation
|
||||
message_admins("[key_name_admin(usr)] has spawned aliens", 1)
|
||||
if("spiders")
|
||||
@@ -2219,7 +2254,7 @@
|
||||
if("spaceninja")
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","SN")
|
||||
if(toggle_space_ninja)
|
||||
if(config.ninjas_allowed)
|
||||
if(space_ninja_arrival())//If the ninja is actually spawned. They may not be depending on a few factors.
|
||||
message_admins("[key_name_admin(usr)] has sent in a space ninja", 1)
|
||||
if("carp")
|
||||
@@ -2295,7 +2330,7 @@
|
||||
message_admins("[key_name_admin(usr)] made the floor LAVA! It'll last [length] seconds and it will deal [damage] damage to everyone.", 1)
|
||||
|
||||
for(var/turf/simulated/floor/F in world)
|
||||
if(F.z == 1)
|
||||
if(F.z in config.station_levels)
|
||||
F.name = "lava"
|
||||
F.desc = "The floor is LAVA!"
|
||||
F.overlays += "lava"
|
||||
@@ -2320,7 +2355,7 @@
|
||||
sleep(10)
|
||||
|
||||
for(var/turf/simulated/floor/F in world) // Reset everything.
|
||||
if(F.z == 1)
|
||||
if(F.z in config.station_levels)
|
||||
F.name = initial(F.name)
|
||||
F.desc = initial(F.desc)
|
||||
F.overlays.Cut()
|
||||
@@ -2368,7 +2403,7 @@
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","EgL")
|
||||
for(var/obj/machinery/door/airlock/W in world)
|
||||
if(W.z == 1 && !istype(get_area(W), /area/bridge) && !istype(get_area(W), /area/crew_quarters) && !istype(get_area(W), /area/security/prison))
|
||||
if(W.z in config.station_levels && !istype(get_area(W), /area/bridge) && !istype(get_area(W), /area/crew_quarters) && !istype(get_area(W), /area/security/prison))
|
||||
W.req_access = list()
|
||||
message_admins("[key_name_admin(usr)] activated Egalitarian Station mode")
|
||||
command_announcement.Announce("Centcomm airlock control override activated. Please take this time to get acquainted with your coworkers.", new_sound = 'sound/AI/commandreport.ogg')
|
||||
@@ -2561,20 +2596,10 @@
|
||||
if(src.admincaster_feed_message.body =="" || src.admincaster_feed_message.body =="\[REDACTED\]" || src.admincaster_feed_channel.channel_name == "" )
|
||||
src.admincaster_screen = 6
|
||||
else
|
||||
var/datum/feed_message/newMsg = new /datum/feed_message
|
||||
newMsg.author = src.admincaster_signature
|
||||
newMsg.body = src.admincaster_feed_message.body
|
||||
newMsg.is_admin_message = 1
|
||||
feedback_inc("newscaster_stories",1)
|
||||
for(var/datum/feed_channel/FC in news_network.network_channels)
|
||||
if(FC.channel_name == src.admincaster_feed_channel.channel_name)
|
||||
FC.messages += newMsg //Adding message to the network's appropriate feed_channel
|
||||
break
|
||||
news_network.SubmitArticle(src.admincaster_feed_message.body, src.admincaster_signature, src.admincaster_feed_channel.channel_name, null, 1)
|
||||
src.admincaster_screen=4
|
||||
|
||||
for(var/obj/machinery/newscaster/NEWSCASTER in allCasters)
|
||||
NEWSCASTER.newsAlert(src.admincaster_feed_channel.channel_name)
|
||||
|
||||
log_admin("[key_name_admin(usr)] submitted a feed story to channel: [src.admincaster_feed_channel.channel_name]!")
|
||||
src.access_news_network()
|
||||
|
||||
@@ -2735,6 +2760,24 @@
|
||||
if(href_list["vsc"] == "default")
|
||||
vsc.SetDefault(usr)
|
||||
|
||||
else if(href_list["toglang"])
|
||||
if(check_rights(R_SPAWN))
|
||||
var/mob/M = locate(href_list["toglang"])
|
||||
if(!istype(M))
|
||||
usr << "[M] is illegal type, must be /mob!"
|
||||
return
|
||||
var/lang2toggle = href_list["lang"]
|
||||
var/datum/language/L = all_languages[lang2toggle]
|
||||
|
||||
if(L in M.languages)
|
||||
if(!M.remove_language(lang2toggle))
|
||||
usr << "Failed to remove language '[lang2toggle]' from \the [M]!"
|
||||
else
|
||||
if(!M.add_language(lang2toggle))
|
||||
usr << "Failed to add language '[lang2toggle]' from \the [M]!"
|
||||
|
||||
show_player_panel(M)
|
||||
|
||||
// player info stuff
|
||||
|
||||
if(href_list["add_player_info"])
|
||||
|
||||
@@ -1,9 +1,18 @@
|
||||
|
||||
#define AHELP_ADMIN 1
|
||||
#define AHELP_MENTOR 2
|
||||
#define AHELP_DEV 3
|
||||
|
||||
//This is a list of words which are ignored by the parser when comparing message contents for names. MUST BE IN LOWER CASE!
|
||||
var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","alien","as")
|
||||
|
||||
/client/verb/adminhelp()
|
||||
var/list/adminhelp_categories = list("Mentor - Gameplay/Roleplay question" = AHELP_MENTOR,\
|
||||
"Admin - Rule/Gameplay issue" = AHELP_ADMIN,\
|
||||
"Dev - Bug report" = AHELP_DEV)
|
||||
|
||||
/client/proc/adminhelp_admin(message)
|
||||
adminhelp("Admin - Rule/Gameplay issue", message)
|
||||
|
||||
/client/verb/adminhelp(selected_type in adminhelp_categories, msg as text)
|
||||
set category = "Admin"
|
||||
set name = "Adminhelp"
|
||||
|
||||
@@ -16,7 +25,6 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","
|
||||
src << "<font color='red'>Error: Admin-PM: You cannot send adminhelps (Muted).</font>"
|
||||
return
|
||||
|
||||
|
||||
adminhelped = 1 //Determines if they get the message to reply by clicking the name.
|
||||
|
||||
/**src.verbs -= /client/verb/adminhelp
|
||||
@@ -25,26 +33,23 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","
|
||||
src.verbs += /client/verb/adminhelp // 2 minute cool-down for adminhelps
|
||||
src.verbs += /client/verb/adminhelp // 2 minute cool-down for adminhelps//Go to hell
|
||||
**/
|
||||
var/msg
|
||||
var/list/type = list ("Gameplay/Roleplay question", "Rule/Gameplay issue", "Bug report")
|
||||
var/selected_type = input("Pick a category.", "Admin Help", null, null) as null|anything in type
|
||||
if(selected_type)
|
||||
msg = input("Please enter your message:", "Admin Help", null, null) as text
|
||||
|
||||
if(!msg || alert("The following message will be sent to staff that administers\n the '[selected_type]' category:\n\n[msg]\n", "Admin Help", "Ok", "Cancel") == "Cancel")
|
||||
return
|
||||
|
||||
var/selected_upper = uppertext(selected_type)
|
||||
|
||||
if(src.handle_spam_prevention(msg,MUTE_ADMINHELP))
|
||||
return
|
||||
|
||||
|
||||
//clean the input msg
|
||||
if(!msg) return
|
||||
if(!msg)
|
||||
return
|
||||
msg = sanitize(copytext(msg,1,MAX_MESSAGE_LEN))
|
||||
if(!msg) return
|
||||
if(!msg)
|
||||
return
|
||||
var/original_msg = msg
|
||||
|
||||
|
||||
|
||||
//explode the input msg into a list
|
||||
var/list/msglist = text2list(msg, " ")
|
||||
|
||||
@@ -98,14 +103,15 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","
|
||||
continue
|
||||
msg += "[original_word] "
|
||||
|
||||
if(!mob) return //this doesn't happen
|
||||
|
||||
var/ref_mob = "\ref[mob]"
|
||||
var/mentor_msg = "\blue <b><font color=red>[selected_upper]: </font>[get_options_bar(mob, 0, 0, 1, 0)][ai_found ? " (<A HREF='?_src_=holder;adminchecklaws=[ref_mob]'>CL</A>)" : ""]:</b> [msg]"
|
||||
var/dev_msg = "\blue <b><font color=red>[selected_upper]: </font>[get_options_bar(mob, 3, 0, 1, 0)][ai_found ? " (<A HREF='?_src_=holder;adminchecklaws=[ref_mob]'>CL</A>)" : ""]:</b> [msg]"
|
||||
msg = "\blue <b><font color=red>[selected_upper]: </font>[get_options_bar(mob, 2, 1, 1)][ai_found ? " (<A HREF='?_src_=holder;adminchecklaws=[ref_mob]'>CL</A>)" : ""]:</b> [msg]"
|
||||
|
||||
if(!mob) //this doesn't happen
|
||||
return
|
||||
|
||||
var/ai_cl
|
||||
if(ai_found)
|
||||
ai_cl = " (<A HREF='?_src_=holder;adminchecklaws=\ref[mob]'>CL</A>)"
|
||||
var/mentor_msg = "\blue <b><font color=red>[selected_upper]: </font>[get_options_bar(mob, 0, 0, 1, 0)][ai_cl]:</b> [msg]"
|
||||
var/dev_msg = "\blue <b><font color=red>[selected_upper]: </font>[get_options_bar(mob, 3, 0, 1, 0)][ai_cl]:</b> [msg]"
|
||||
msg = "\blue <b><font color=red>[selected_upper]: </font>[get_options_bar(mob, 2, 1, 1)][ai_cl]:</b> [msg]"
|
||||
|
||||
var/admin_number_afk = 0
|
||||
|
||||
@@ -127,8 +133,8 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","
|
||||
if(X.is_afk())
|
||||
admin_number_afk++
|
||||
|
||||
switch(selected_type)
|
||||
if("Gameplay/Roleplay question")
|
||||
switch(adminhelp_categories[selected_type])
|
||||
if(AHELP_MENTOR)
|
||||
if(mentorholders.len)
|
||||
for(var/client/X in mentorholders) // Mentors get a message without buttons and no character name
|
||||
if(X.prefs.toggles & SOUND_ADMINHELP)
|
||||
@@ -139,13 +145,13 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","
|
||||
if(X.prefs.toggles & SOUND_ADMINHELP)
|
||||
X << 'sound/effects/adminhelp.ogg'
|
||||
X << msg
|
||||
if("Rule/Gameplay issue")
|
||||
if(AHELP_ADMIN)
|
||||
if(adminholders.len)
|
||||
for(var/client/X in adminholders) // Admins of course get everything in their helps
|
||||
if(X.prefs.toggles & SOUND_ADMINHELP)
|
||||
X << 'sound/effects/adminhelp.ogg'
|
||||
X << msg
|
||||
if("Bug report")
|
||||
if(AHELP_DEV)
|
||||
if(debugholders.len)
|
||||
for(var/client/X in debugholders)
|
||||
if(R_ADMIN | R_MOD & X.holder.rights) // Admins get every button & special highlights in theirs
|
||||
@@ -158,10 +164,6 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","
|
||||
X << 'sound/effects/adminhelp.ogg'
|
||||
X << dev_msg
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*for(var/client/X in admins)
|
||||
if((R_ADMIN|R_MOD|R_MENTOR) & X.holder.rights)
|
||||
if(X.is_afk())
|
||||
@@ -179,11 +181,12 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","
|
||||
var/admin_number_present = admins.len - admin_number_afk
|
||||
log_admin("HELP: [key_name(src)]: [original_msg] - heard by [admin_number_present] non-AFK admins.")
|
||||
if(admin_number_present <= 0)
|
||||
if(!admin_number_afk)
|
||||
send2adminirc("[selected_upper] from [key_name(src)]: [html_decode(original_msg)] - !!No admins online!!")
|
||||
else
|
||||
send2adminirc("[selected_upper] from [key_name(src)]: [html_decode(original_msg)] - !!All admins AFK ([admin_number_afk])!!")
|
||||
send2adminirc("[selected_upper] from [key_name(src)]: [html_decode(original_msg)] - !![admin_number_afk ? "All admins AFK ([admin_number_afk])" : "No admins online"]!!")
|
||||
else
|
||||
send2adminirc("[selected_upper] from [key_name(src)]: [html_decode(original_msg)]")
|
||||
feedback_add_details("admin_verb","AH") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
return
|
||||
|
||||
#undef AHELP_ADMIN
|
||||
#undef AHELP_MENTOR
|
||||
#undef AHELP_DEV
|
||||
@@ -64,20 +64,11 @@
|
||||
msg = sanitize(copytext(msg,1,MAX_MESSAGE_LEN))
|
||||
if(!msg) return
|
||||
|
||||
var/recieve_color = "purple"
|
||||
var/send_pm_type = " "
|
||||
var/recieve_pm_type = "Player"
|
||||
|
||||
|
||||
if(holder)
|
||||
//mod PMs are maroon
|
||||
//PMs sent from admins and mods display their rank
|
||||
if(holder)
|
||||
if( holder.rights & R_ADMIN )
|
||||
recieve_color = "red"
|
||||
else
|
||||
recieve_color = "maroon"
|
||||
send_pm_type = holder.rank + " "
|
||||
if(!C.holder && holder && holder.fakekey)
|
||||
recieve_pm_type = "Admin"
|
||||
else
|
||||
@@ -87,10 +78,10 @@
|
||||
src << "<font color='red'>Error: Admin-PM: Non-admin to non-admin PM communication is forbidden.</font>"
|
||||
return
|
||||
|
||||
var/recieve_message = ""
|
||||
var/recieve_message
|
||||
|
||||
if(holder && !C.holder)
|
||||
recieve_message = "<font color='[recieve_color]' size='3'><b>-- Click the [recieve_pm_type]'s name to reply --</b></font>\n"
|
||||
recieve_message = "<span class='pm'><span class='howto'><b>-- Click the [recieve_pm_type]'s name to reply --</b></span></span>\n"
|
||||
if(C.adminhelped)
|
||||
C << recieve_message
|
||||
C.adminhelped = 0
|
||||
@@ -100,17 +91,15 @@
|
||||
spawn(0) //so we don't hold the caller proc up
|
||||
var/sender = src
|
||||
var/sendername = key
|
||||
var/reply = input(C, msg,"[recieve_pm_type] PM from-[sendername]", "") as text|null //show message and await a reply
|
||||
var/reply = input(C, msg,"[recieve_pm_type] PM from [sendername]", "") as text|null //show message and await a reply
|
||||
if(C && reply)
|
||||
if(sender)
|
||||
C.cmd_admin_pm(sender,reply) //sender is still about, let's reply to them
|
||||
else
|
||||
adminhelp(reply) //sender has left, adminhelp instead
|
||||
adminhelp_admin(reply) //sender has left, adminhelp instead
|
||||
return
|
||||
|
||||
recieve_message = "<font color='[recieve_color]'>[recieve_pm_type] PM from-<b>[get_options_bar(src, C.holder ? 1 : 0, C.holder ? 1 : 0, 1)]</b>: [msg]</font>"
|
||||
C << recieve_message
|
||||
src << "<font color='blue'>[send_pm_type]PM to-<b>[get_options_bar(C, holder ? 1 : 0, holder ? 1 : 0, 1)]</b>: [msg]</font>"
|
||||
src << "<span class='pm'><span class='out'>" + create_text_tag("pm_out_alt", "PM", src) + " to <span class='name'>[get_options_bar(C, holder ? 1 : 0, holder ? 1 : 0, 1)]</span>: <span class='message'>[msg]</span></span></span>"
|
||||
C << "<span class='pm'><span class='in'>" + create_text_tag("pm_in", "", C) + " <b>\[[recieve_pm_type] PM\]</b> <span class='name'>[get_options_bar(src, C.holder ? 1 : 0, C.holder ? 1 : 0, 1)]</span>: <span class='message'>[msg]</span></span></span>"
|
||||
|
||||
//play the recieving admin the adminhelp sound (if they have them enabled)
|
||||
//non-admins shouldn't be able to disable this
|
||||
@@ -124,8 +113,8 @@
|
||||
//check client/X is an admin and isn't the sender or recipient
|
||||
if(X == C || X == src)
|
||||
continue
|
||||
if(X.key!=key && X.key!=C.key && (X.holder.rights & R_ADMIN) || (X.holder.rights & (R_MOD|R_MENTOR)) )
|
||||
X << "<B><font color='blue'>PM: [key_name(src, X, 0)]->[key_name(C, X, 0)]:</B> \blue [msg]</font>" //inform X
|
||||
if(X.key != key && X.key != C.key && (X.holder.rights & R_ADMIN|R_MOD|R_MENTOR))
|
||||
X << "<span class='pm'><span class='other'>" + create_text_tag("pm_other", "PM:", X) + " <span class='name'>[key_name(src, X, 0)]</span> to <span class='name'>[key_name(C, X, 0)]</span>: <span class='message'>[msg]</span></span></span>"
|
||||
|
||||
/client/proc/cmd_admin_irc_pm()
|
||||
if(prefs.muted & MUTE_ADMINHELP)
|
||||
@@ -146,12 +135,11 @@
|
||||
|
||||
send2adminirc("PlayerPM from [key_name(src)]: [html_decode(msg)]")
|
||||
|
||||
src << "<font color='blue'>IRC PM to-<b>IRC-Admins</b>: [msg]</font>"
|
||||
src << "<span class='pm'><span class='out'>" + create_text_tag("pm_out_alt", "", src) + " to <span class='name'Admin IRC</span>: <span class='message'>[msg]</span></span></span>"
|
||||
|
||||
log_admin("PM: [key_name(src)]->IRC: [msg]")
|
||||
for(var/client/X in admins)
|
||||
if(X == src)
|
||||
continue
|
||||
if((X.holder.rights & R_ADMIN) || (X.holder.rights & R_MOD))
|
||||
X << "<B><font color='blue'>PM: [key_name(src, X, 0)]->IRC-Admins:</B> \blue [msg]</font>"
|
||||
|
||||
if(X.holder.rights & R_ADMIN|R_MOD)
|
||||
X << "<span class='pm'><span class='other'>" + create_text_tag("pm_other", "PM:", X) + " <span class='name'>[key_name(src, X, 0)]</span> to <span class='name'>Admin IRC</span>: <span class='message'>[msg]</span></span></span>"
|
||||
|
||||
@@ -9,15 +9,10 @@
|
||||
|
||||
log_admin("[key_name(src)] : [msg]")
|
||||
|
||||
var/color = "adminsay"
|
||||
if(ishost(usr))
|
||||
color = "headminsay"
|
||||
|
||||
if(check_rights(R_ADMIN,0))
|
||||
msg = "<span class='[color]'><span class='prefix'>ADMIN:</span> <EM>[key_name(usr, 1)]</EM> (<a href='?_src_=holder;adminplayerobservejump=\ref[mob]'>JMP</A>): <span class='message'>[msg]</span></span>"
|
||||
for(var/client/C in admins)
|
||||
if(R_ADMIN & C.holder.rights)
|
||||
C << msg
|
||||
C << "<span class='admin_channel'>" + create_text_tag("admin", "ADMIN:", C) + " <span class='name'>[key_name(usr, 1)]</span>(<a href='?_src_=holder;adminplayerobservejump=\ref[mob]'>JMP</A>): <span class='message'>[msg]</span></span>"
|
||||
|
||||
feedback_add_details("admin_verb","M") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -33,15 +28,11 @@
|
||||
|
||||
if (!msg)
|
||||
return
|
||||
var/color = "mod"
|
||||
if (check_rights(R_ADMIN,0))
|
||||
color = "adminmod"
|
||||
|
||||
var/channel = "MOD:"
|
||||
if(config.mods_are_mentors)
|
||||
channel = "MENTOR:"
|
||||
var/sender_name = src.key
|
||||
if(check_rights(R_ADMIN, 0))
|
||||
sender_name = "<span class='admin'>[sender_name]</span>"
|
||||
for(var/client/C in admins)
|
||||
if((R_ADMIN|R_MOD) & C.holder.rights)
|
||||
C << "<span class='[color]'><span class='prefix'>[channel]</span> <EM>[key_name(src,1)]</EM> (<A HREF='?src=\ref[C.holder];adminplayerobservejump=\ref[mob]'>JMP</A>): <span class='message'>[msg]</span></span>"
|
||||
else // Mentors get same message without fancy coloring of name if special_role.
|
||||
C << "<span class='[color]'><span class='prefix'>[channel]</span> <EM>[key_name(src,1,1,0)]</EM> (<A HREF='?src=\ref[C.holder];adminplayerobservejump=\ref[mob]'>JMP</A>): <span class='message'>[msg]</span></span>"
|
||||
C << "<span class='mod_channel'>" + create_text_tag("mod", "MOD:", C) + " <span class='name'>[sender_name]</span>(<A HREF='?src=\ref[C.holder];adminplayerobservejump=\ref[mob]'>JMP</A>): <span class='message'>[msg]</span></span>"
|
||||
|
||||
feedback_add_details("admin_verb","MS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
src << "Only administrators may use this command."
|
||||
return
|
||||
feedback_add_details("admin_verb","CP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
|
||||
if(alert("WARNING: This command should not be run on a live server. Do you want to continue?", "Check Piping", "No", "Yes") == "No")
|
||||
return
|
||||
|
||||
@@ -30,11 +30,12 @@
|
||||
next_turf:
|
||||
for(var/turf/T in world)
|
||||
for(var/dir in cardinal)
|
||||
var/check = 0
|
||||
var/list/connect_types = list(1 = 0, 2 = 0, 3 = 0)
|
||||
for(var/obj/machinery/atmospherics/pipe in T)
|
||||
if(dir & pipe.initialize_directions)
|
||||
check++
|
||||
if(check > 1)
|
||||
for(var/connect_type in pipe.connect_types)
|
||||
connect_types[connect_type] += 1
|
||||
if(connect_types[1] > 1 || connect_types[2] > 1 || connect_types[3] > 1)
|
||||
usr << "Overlapping pipe ([pipe.name]) located at [T.x],[T.y],[T.z] ([get_area(T)])"
|
||||
continue next_turf
|
||||
usr << "Done"
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
var/override
|
||||
switch(parameter)
|
||||
if(1)
|
||||
override = input(src,"mode = ?","Enter Parameter",null) as anything in list("nuclear emergency","no override")
|
||||
override = input(src,"mode = ?","Enter Parameter",null) as anything in list("mercenary","no override")
|
||||
if(0)
|
||||
override = input(src,"mode = ?","Enter Parameter",null) as anything in list("blob","nuclear emergency","AI malfunction","no override")
|
||||
override = input(src,"mode = ?","Enter Parameter",null) as anything in list("blob","mercenary","AI malfunction","no override")
|
||||
ticker.station_explosion_cinematic(parameter,override)
|
||||
return
|
||||
@@ -35,16 +35,6 @@
|
||||
if (!msg)
|
||||
return
|
||||
|
||||
var/rendered = "<span class='game deadsay'><span class='prefix'>DEAD:</span> <span class='name'>[stafftype]([src.holder.fakekey ? pick("BADMIN", "hornigranny", "TLF", "scaredforshadows", "KSI", "Silnazi", "HerpEs", "BJ69", "SpoofedEdd", "Uhangay", "Wario90900", "Regarity", "MissPhareon", "LastFish", "unMportant", "Deurpyn", "Fatbeaver") : src.key])</span> says, <span class='message'>\"[msg]\"</span></span>"
|
||||
|
||||
for (var/mob/M in player_list)
|
||||
if (istype(M, /mob/new_player))
|
||||
continue
|
||||
|
||||
if(M.client && M.client.holder && (M.client.prefs.toggles & CHAT_DEAD)) // show the message to admins who have deadchat toggled on
|
||||
M.show_message(rendered, 2)
|
||||
|
||||
else if(M.stat == DEAD && (M.client.prefs.toggles & CHAT_DEAD)) // show the message to regular ghosts who have deadchat toggled on
|
||||
M.show_message(rendered, 2)
|
||||
say_dead_direct("<span class='name'>[stafftype]([src.holder.fakekey ? src.holder.fakekey : src.key])</span> says, <span class='message'>\"[msg]\"</span>")
|
||||
|
||||
feedback_add_details("admin_verb","D") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -367,9 +367,9 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
set category = "Server"
|
||||
set name = "Toggle Aliens"
|
||||
|
||||
aliens_allowed = !aliens_allowed
|
||||
log_admin("[key_name(src)] has turned aliens [aliens_allowed ? "on" : "off"].")
|
||||
message_admins("[key_name_admin(src)] has turned aliens [aliens_allowed ? "on" : "off"].", 0)
|
||||
config.aliens_allowed = !config.aliens_allowed
|
||||
log_admin("[key_name(src)] has turned aliens [config.aliens_allowed ? "on" : "off"].")
|
||||
message_admins("[key_name_admin(src)] has turned aliens [config.aliens_allowed ? "on" : "off"].", 0)
|
||||
feedback_add_details("admin_verb","TAL") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/cmd_admin_grantfullaccess(var/mob/M in mob_list)
|
||||
@@ -958,7 +958,7 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
|
||||
for(var/obj/machinery/power/smes/SMES in world)
|
||||
if(SMES.anchored)
|
||||
SMES.chargemode = 1
|
||||
SMES.input_attempt = 1
|
||||
|
||||
/client/proc/setup_supermatter_engine()
|
||||
set category = "Debug"
|
||||
@@ -1007,7 +1007,7 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
Pump.air2.gas["nitrogen"] = 3750 //The contents of 2 canisters.
|
||||
Pump.air2.temperature = 50
|
||||
Pump.air2.update_values()
|
||||
Pump.on=1
|
||||
Pump.use_power=1
|
||||
Pump.target_pressure = 4500
|
||||
Pump.update_icon()
|
||||
|
||||
@@ -1018,16 +1018,16 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
|
||||
else if(istype(M,/obj/machinery/power/smes)) //This is the SMES inside the engine room. We don't need much power.
|
||||
var/obj/machinery/power/smes/SMES = M
|
||||
SMES.chargemode = 1
|
||||
SMES.chargelevel = 200000
|
||||
SMES.output = 75000
|
||||
SMES.input_attempt = 1
|
||||
SMES.input_level = 200000
|
||||
SMES.output_level = 75000
|
||||
|
||||
else if(istype(M.loc.loc,/area/engine/engine_smes)) //Set every SMES to charge and spit out 300,000 power between the 4 of them.
|
||||
if(istype(M,/obj/machinery/power/smes))
|
||||
var/obj/machinery/power/smes/SMES = M
|
||||
SMES.chargemode = 1
|
||||
SMES.chargelevel = 200000
|
||||
SMES.output = 75000
|
||||
SMES.input_attempt = 1
|
||||
SMES.input_level = 200000
|
||||
SMES.output_level = 75000
|
||||
|
||||
if(!found_the_pump && response == "Setup Completely")
|
||||
src << "\red Unable to locate air supply to fill up with coolant, adding some coolant around the supermatter"
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
var/inactive_on_main_station = 0
|
||||
for(var/zone/zone in air_master.zones)
|
||||
var/turf/simulated/turf = locate() in zone.contents
|
||||
if(turf && turf.z == 1)
|
||||
if(turf && turf.z in config.station_levels)
|
||||
if(zone.needs_update)
|
||||
active_on_main_station++
|
||||
else
|
||||
|
||||
@@ -161,9 +161,6 @@ var/list/debug_verbs = list (
|
||||
,/client/proc/testZAScolors
|
||||
,/client/proc/testZAScolors_remove
|
||||
,/client/proc/setup_supermatter_engine
|
||||
,/client/proc/view_power_update_stats_area
|
||||
,/client/proc/view_power_update_stats_machines
|
||||
,/client/proc/toggle_power_update_profiling
|
||||
,/client/proc/atmos_toggle_debug
|
||||
)
|
||||
|
||||
|
||||
@@ -275,7 +275,7 @@ var/list/forbidden_varedit_object_types = list(
|
||||
/client/proc/modify_variables(var/atom/O, var/param_var_name = null, var/autodetect_class = 0)
|
||||
if(!check_rights(R_VAREDIT)) return
|
||||
|
||||
var/list/locked = list("vars", "key", "ckey", "client", "firemut", "ishulk", "telekinesis", "xray", "virus", "cuffed", "ka", "last_eaten", "icon", "icon_state", "mutantrace")
|
||||
var/list/locked = list("vars", "key", "ckey", "client", "firemut", "ishulk", "telekinesis", "xray", "virus", "cuffed", "ka", "last_eaten", "icon", "icon_state")
|
||||
|
||||
for(var/p in forbidden_varedit_object_types)
|
||||
if( istype(O,p) )
|
||||
|
||||
@@ -264,7 +264,7 @@ client/proc/one_click_antag()
|
||||
|
||||
if(nuke_spawn)
|
||||
var/obj/item/weapon/paper/P = new
|
||||
P.info = "Sadly, the Syndicate could not get you a nuclear bomb. We have, however, acquired the arming code for the station's onboard nuke. The nuclear authorization code is: <b>[nuke_code]</b>"
|
||||
P.info = "Sadly, your employers could not get you a nuclear bomb. They have, however, acquired the arming code for the station's onboard nuke. The nuclear authorization code is: <b>[nuke_code]</b>"
|
||||
P.name = "nuclear bomb code and instructions"
|
||||
P.loc = nuke_spawn.loc
|
||||
|
||||
@@ -327,7 +327,7 @@ client/proc/one_click_antag()
|
||||
//Generates a list of commandos from active ghosts. Then the user picks which characters to respawn as the commandos.
|
||||
for(var/mob/dead/observer/G in player_list)
|
||||
spawn(0)
|
||||
switch(alert(G,"Do you wish to be considered for an elite syndicate strike team being sent in?","Please answer in 30 seconds!","Yes","No"))
|
||||
switch(alert(G,"Do you wish to be considered for an elite mercenary strike team being sent in?","Please answer in 30 seconds!","Yes","No"))
|
||||
if("Yes")
|
||||
if((world.time-time_passed)>300)//If more than 30 game seconds passed.
|
||||
return
|
||||
@@ -369,7 +369,7 @@ client/proc/one_click_antag()
|
||||
//So they don't forget their code or mission.
|
||||
|
||||
|
||||
new_syndicate_commando << "\blue You are an Elite Syndicate. [!syndicate_leader_selected?"commando":"<B>LEADER</B>"] in the service of the Syndicate. \nYour current mission is: \red<B> [input]</B>"
|
||||
new_syndicate_commando << "\blue You are an Elite Mercenary. [!syndicate_leader_selected?"commando":"<B>LEADER</B>"] in the service of criminal elements hostile to NanoTrasen. \nYour current mission is: \red<B> [input]</B>"
|
||||
|
||||
numagents--
|
||||
if(numagents >= 6)
|
||||
@@ -424,7 +424,7 @@ client/proc/one_click_antag()
|
||||
//Creates mind stuff.
|
||||
new_syndicate_commando.mind_initialize()
|
||||
new_syndicate_commando.mind.assigned_role = "MODE"
|
||||
new_syndicate_commando.mind.special_role = "Syndicate Commando"
|
||||
new_syndicate_commando.mind.special_role = "Mercenary"
|
||||
|
||||
//Adds them to current traitor list. Which is really the extra antagonist list.
|
||||
ticker.mode.traitors += new_syndicate_commando.mind
|
||||
@@ -511,7 +511,6 @@ client/proc/one_click_antag()
|
||||
new_vox.age = rand(12,20)
|
||||
|
||||
new_vox.dna.ready_dna(new_vox) // Creates DNA.
|
||||
new_vox.dna.mutantrace = "vox"
|
||||
new_vox.mind_initialize()
|
||||
new_vox.mind.assigned_role = "MODE"
|
||||
new_vox.mind.special_role = "Vox Raider"
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
|
||||
/proc/Syndicate_announce(var/text , var/mob/Sender)
|
||||
var/msg = copytext(sanitize(text), 1, MAX_MESSAGE_LEN)
|
||||
msg = "\blue <b><font color=crimson>SYNDICATE:</font>[key_name(Sender, 1)] (<A HREF='?_src_=holder;adminplayeropts=\ref[Sender]'>PP</A>) (<A HREF='?_src_=vars;Vars=\ref[Sender]'>VV</A>) (<A HREF='?_src_=holder;subtlemessage=\ref[Sender]'>SM</A>) (<A HREF='?_src_=holder;adminplayerobservejump=\ref[Sender]'>JMP</A>) (<A HREF='?_src_=holder;secretsadmin=check_antagonist'>CA</A>) (<A HREF='?_src_=holder;BlueSpaceArtillery=\ref[Sender]'>BSA</A>) (<A HREF='?_src_=holder;SyndicateReply=\ref[Sender]'>RPLY</A>):</b> [msg]"
|
||||
msg = "\blue <b><font color=crimson>ILLEGAL:</font>[key_name(Sender, 1)] (<A HREF='?_src_=holder;adminplayeropts=\ref[Sender]'>PP</A>) (<A HREF='?_src_=vars;Vars=\ref[Sender]'>VV</A>) (<A HREF='?_src_=holder;subtlemessage=\ref[Sender]'>SM</A>) (<A HREF='?_src_=holder;adminplayerobservejump=\ref[Sender]'>JMP</A>) (<A HREF='?_src_=holder;secretsadmin=check_antagonist'>CA</A>) (<A HREF='?_src_=holder;BlueSpaceArtillery=\ref[Sender]'>BSA</A>) (<A HREF='?_src_=holder;SyndicateReply=\ref[Sender]'>RPLY</A>):</b> [msg]"
|
||||
for(var/client/C in admins)
|
||||
if(R_ADMIN & C.holder.rights)
|
||||
C << msg
|
||||
|
||||
@@ -453,15 +453,13 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
new_character.loc = pick(wizardstart)
|
||||
//ticker.mode.learn_basic_spells(new_character)
|
||||
ticker.mode.equip_wizard(new_character)
|
||||
if("Syndicate")
|
||||
if("Mercenary")
|
||||
var/obj/effect/landmark/synd_spawn = locate("landmark*Syndicate-Spawn")
|
||||
if(synd_spawn)
|
||||
new_character.loc = get_turf(synd_spawn)
|
||||
call(/datum/game_mode/proc/equip_syndicate)(new_character)
|
||||
if("Ninja")
|
||||
new_character.equip_space_ninja()
|
||||
new_character.internal = new_character.s_store
|
||||
new_character.internals.icon_state = "internal1"
|
||||
if(ninjastart.len == 0)
|
||||
new_character << "<B>\red A proper starting location for you could not be found, please report this bug!</B>"
|
||||
new_character << "<B>\red Attempting to place at a carpspawn.</B>"
|
||||
|
||||
@@ -4,7 +4,7 @@ var/const/syndicate_commandos_possible = 6 //if more Commandos are needed in the
|
||||
var/global/sent_syndicate_strike_team = 0
|
||||
/client/proc/syndicate_strike_team()
|
||||
set category = "Fun"
|
||||
set name = "Spawn Syndicate Strike Team"
|
||||
set name = "Spawn Mercenary Strike Team"
|
||||
set desc = "Spawns a squad of commandos in the Syndicate Mothership if you want to run an admin event."
|
||||
if(!src.holder)
|
||||
src << "Only administrators may use this command."
|
||||
@@ -16,15 +16,15 @@ var/global/sent_syndicate_strike_team = 0
|
||||
// alert("Not so fast, buddy. Wait a few minutes until the game gets going. There are [(6000-world.time)/10] seconds remaining.")
|
||||
// return
|
||||
if(sent_syndicate_strike_team == 1)
|
||||
alert("The Syndicate are already sending a team, Mr. Dumbass.")
|
||||
alert("Criminal elements are already sending a team, Mr. Dumbass.")
|
||||
return
|
||||
if(alert("Do you want to send in the Syndicate Strike Team? Once enabled, this is irreversible.",,"Yes","No")=="No")
|
||||
if(alert("Do you want to send in the Mercenary Strike Team? Once enabled, this is irreversible.",,"Yes","No")=="No")
|
||||
return
|
||||
alert("This 'mode' will go on until everyone is dead or the station is destroyed. You may also admin-call the evac shuttle when appropriate. Spawned syndicates have internals cameras which are viewable through a monitor inside the Syndicate Mothership Bridge. Assigning the team's detailed task is recommended from there. While you will be able to manually pick the candidates from active ghosts, their assignment in the squad will be random.")
|
||||
alert("This 'mode' will go on until everyone is dead or the station is destroyed. You may also admin-call the evac shuttle when appropriate. Spawned mercs have internals cameras which are viewable through a monitor inside the Syndicate Mothership Bridge. Assigning the team's detailed task is recommended from there. While you will be able to manually pick the candidates from active ghosts, their assignment in the squad will be random.")
|
||||
|
||||
var/input = null
|
||||
while(!input)
|
||||
input = copytext(sanitize(input(src, "Please specify which mission the syndicate strike team shall undertake.", "Specify Mission", "")),1,MAX_MESSAGE_LEN)
|
||||
input = copytext(sanitize(input(src, "Please specify which mission the strike team shall undertake.", "Specify Mission", "")),1,MAX_MESSAGE_LEN)
|
||||
if(!input)
|
||||
if(alert("Error, no mission set. Do you want to exit the setup process?",,"Yes","No")=="Yes")
|
||||
return
|
||||
@@ -81,7 +81,7 @@ var/global/sent_syndicate_strike_team = 0
|
||||
new_syndicate_commando.mind.store_memory("<B>Nuke Code:</B> \red [nuke_code].")
|
||||
new_syndicate_commando.mind.store_memory("<B>Mission:</B> \red [input].")
|
||||
|
||||
new_syndicate_commando << "\blue You are an Elite Syndicate. [!syndicate_leader_selected?"commando":"<B>LEADER</B>"] in the service of the Syndicate. \nYour current mission is: \red<B>[input]</B>"
|
||||
new_syndicate_commando << "\blue You are an Elite Mercenary. [!syndicate_leader_selected?"commando":"<B>LEADER</B>"] in the service of criminal elements hostile to NanoTrasen. \nYour current mission is: \red<B>[input]</B>"
|
||||
|
||||
syndicate_commando_number--
|
||||
|
||||
@@ -98,8 +98,8 @@ var/global/sent_syndicate_strike_team = 0
|
||||
new /obj/effect/spawner/newbomb/timer/syndicate(L.loc)
|
||||
del(L)
|
||||
|
||||
message_admins("\blue [key_name_admin(usr)] has spawned a Syndicate strike squad.", 1)
|
||||
log_admin("[key_name(usr)] used Spawn Syndicate Squad.")
|
||||
message_admins("\blue [key_name_admin(usr)] has spawned a mercenary strike squad.", 1)
|
||||
log_admin("[key_name(usr)] used Spawn Mercenary Squad.")
|
||||
feedback_add_details("admin_verb","SDTHS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/create_syndicate_death_commando(obj/spawn_location, syndicate_leader_selected = 0)
|
||||
@@ -121,7 +121,7 @@ var/global/sent_syndicate_strike_team = 0
|
||||
//Creates mind stuff.
|
||||
new_syndicate_commando.mind_initialize()
|
||||
new_syndicate_commando.mind.assigned_role = "MODE"
|
||||
new_syndicate_commando.mind.special_role = "Syndicate Commando"
|
||||
new_syndicate_commando.mind.special_role = "Mercenary"
|
||||
ticker.mode.traitors |= new_syndicate_commando.mind //Adds them to current traitor list. Which is really the extra antagonist list.
|
||||
new_syndicate_commando.equip_syndicate_commando(syndicate_leader_selected)
|
||||
del(spawn_location)
|
||||
@@ -171,7 +171,7 @@ var/global/sent_syndicate_strike_team = 0
|
||||
W.icon_state = "id"
|
||||
W.access = get_all_accesses()//They get full station access because obviously the syndicate has HAAAX, and can make special IDs for their most elite members.
|
||||
W.access += list(access_cent_general, access_cent_specops, access_cent_living, access_cent_storage, access_syndicate)//Let's add their forged CentCom access and syndicate access.
|
||||
W.assignment = "Syndicate Commando"
|
||||
W.assignment = "Mercenary"
|
||||
W.registered_name = real_name
|
||||
equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
|
||||
@@ -117,14 +117,13 @@
|
||||
return
|
||||
|
||||
|
||||
examine()
|
||||
set src in view()
|
||||
..()
|
||||
if((in_range(src, usr) || loc == usr))
|
||||
examine(mob/user)
|
||||
..(user)
|
||||
if((in_range(src, user) || loc == user))
|
||||
if(secured)
|
||||
usr << "\The [src] is ready!"
|
||||
user << "\The [src] is ready!"
|
||||
else
|
||||
usr << "\The [src] can be attached!"
|
||||
user << "\The [src] can be attached!"
|
||||
return
|
||||
|
||||
|
||||
|
||||
@@ -11,9 +11,9 @@
|
||||
var/obj/item/device/assembly_holder/bombassembly = null //The first part of the bomb is an assembly holder, holding an igniter+some device
|
||||
var/obj/item/weapon/tank/bombtank = null //the second part of the bomb is a phoron tank
|
||||
|
||||
/obj/item/device/onetankbomb/examine()
|
||||
..()
|
||||
bombtank.examine()
|
||||
/obj/item/device/onetankbomb/examine(mob/user)
|
||||
..(user)
|
||||
user.examinate(bombtank)
|
||||
|
||||
/obj/item/device/onetankbomb/update_icon()
|
||||
if(bombtank)
|
||||
|
||||
@@ -84,14 +84,13 @@
|
||||
src.overlays += O
|
||||
*/
|
||||
|
||||
examine()
|
||||
set src in view()
|
||||
..()
|
||||
if ((in_range(src, usr) || src.loc == usr))
|
||||
examine(mob/user)
|
||||
..(user)
|
||||
if ((in_range(src, user) || src.loc == user))
|
||||
if (src.secured)
|
||||
usr << "\The [src] is ready!"
|
||||
user << "\The [src] is ready!"
|
||||
else
|
||||
usr << "\The [src] can be attached!"
|
||||
user << "\The [src] can be attached!"
|
||||
return
|
||||
|
||||
|
||||
@@ -212,11 +211,11 @@
|
||||
return 1
|
||||
|
||||
|
||||
/obj/item/device/assembly_holder/hear_talk(mob/living/M as mob, msg)
|
||||
/obj/item/device/assembly_holder/hear_talk(mob/living/M as mob, msg, verb, datum/language/speaking)
|
||||
if(a_right)
|
||||
a_right.hear_talk(M,msg)
|
||||
a_right.hear_talk(M,msg,verb,speaking)
|
||||
if(a_left)
|
||||
a_left.hear_talk(M,msg)
|
||||
a_left.hear_talk(M,msg,verb,speaking)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
var/obj/effect/beam/i_beam/I = new /obj/effect/beam/i_beam((holder ? holder.loc : loc) )
|
||||
I.master = src
|
||||
I.density = 1
|
||||
I.dir = dir
|
||||
I.set_dir(dir)
|
||||
step(I, I.dir)
|
||||
if(I)
|
||||
I.density = 0
|
||||
@@ -85,14 +85,14 @@
|
||||
Move()
|
||||
var/t = dir
|
||||
..()
|
||||
dir = t
|
||||
set_dir(t)
|
||||
del(first)
|
||||
return
|
||||
|
||||
|
||||
holder_movement()
|
||||
if(!holder) return 0
|
||||
// dir = holder.dir
|
||||
// set_dir(holder.dir)
|
||||
del(first)
|
||||
return 1
|
||||
|
||||
@@ -151,7 +151,7 @@
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
dir = turn(dir, 90)
|
||||
set_dir(turn(dir, 90))
|
||||
return
|
||||
|
||||
|
||||
@@ -213,7 +213,7 @@
|
||||
var/obj/effect/beam/i_beam/I = new /obj/effect/beam/i_beam(loc)
|
||||
I.master = master
|
||||
I.density = 1
|
||||
I.dir = dir
|
||||
I.set_dir(dir)
|
||||
//world << "created new beam \ref[I] at [I.x] [I.y] [I.z]"
|
||||
step(I, I.dir)
|
||||
|
||||
|
||||
@@ -7,10 +7,10 @@
|
||||
var/armed = 0
|
||||
|
||||
|
||||
examine()
|
||||
..()
|
||||
examine(mob/user)
|
||||
..(user)
|
||||
if(armed)
|
||||
usr << "It looks like it's armed."
|
||||
user << "It looks like it's armed."
|
||||
|
||||
update_icon()
|
||||
if(armed)
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
var/frequency = 1457
|
||||
var/delay = 0
|
||||
var/airlock_wire = null
|
||||
var/datum/wires/connected = null
|
||||
var/datum/radio_frequency/radio_connection
|
||||
var/deadman = 0
|
||||
|
||||
@@ -118,9 +119,8 @@
|
||||
|
||||
|
||||
pulse(var/radio = 0)
|
||||
if(istype(src.loc, /obj/machinery/door/airlock) && src.airlock_wire && src.wires)
|
||||
var/obj/machinery/door/airlock/A = src.loc
|
||||
A.pulse(src.airlock_wire)
|
||||
if(src.connected && src.wires)
|
||||
connected.Pulse(src)
|
||||
else if(holder)
|
||||
holder.process_activation(src, 1, 0)
|
||||
else
|
||||
|
||||
@@ -23,14 +23,14 @@
|
||||
var/corpseidjob = null // Needs to be in quotes, such as "Clown" or "Chef." This just determines what the ID reads as, not their access
|
||||
var/corpseidaccess = null //This is for access. See access.dm for which jobs give what access. Again, put in quotes. Use "Captain" if you want it to be all access.
|
||||
var/corpseidicon = null //For setting it to be a gold, silver, centcomm etc ID
|
||||
var/mutantrace = "human"
|
||||
var/species = "Human"
|
||||
|
||||
/obj/effect/landmark/corpse/initialize()
|
||||
createCorpse()
|
||||
|
||||
/obj/effect/landmark/corpse/proc/createCorpse() //Creates a mob and checks for gear in each slot before attempting to equip it.
|
||||
var/mob/living/carbon/human/M = new /mob/living/carbon/human (src.loc)
|
||||
M.dna.mutantrace = mutantrace
|
||||
M.set_species(species)
|
||||
M.real_name = src.name
|
||||
M.death(1) //Kills the new mob
|
||||
if(src.corpseuniform)
|
||||
@@ -106,12 +106,12 @@
|
||||
/obj/effect/landmark/corpse/syndicatecommando
|
||||
name = "Syndicate Commando"
|
||||
corpseuniform = /obj/item/clothing/under/syndicate
|
||||
corpsesuit = /obj/item/clothing/suit/space/rig/syndi
|
||||
corpsesuit = /obj/item/clothing/suit/space/void/merc
|
||||
corpseshoes = /obj/item/clothing/shoes/swat
|
||||
corpsegloves = /obj/item/clothing/gloves/swat
|
||||
corpseradio = /obj/item/device/radio/headset
|
||||
corpsemask = /obj/item/clothing/mask/gas/syndicate
|
||||
corpsehelmet = /obj/item/clothing/head/helmet/space/rig/syndi
|
||||
corpsehelmet = /obj/item/clothing/head/helmet/space/void/merc
|
||||
corpseback = /obj/item/weapon/tank/jetpack/oxygen
|
||||
corpsepocket1 = /obj/item/weapon/tank/emergency_oxygen
|
||||
corpseid = 1
|
||||
@@ -139,7 +139,7 @@
|
||||
name = "Doctor"
|
||||
corpseradio = /obj/item/device/radio/headset/headset_med
|
||||
corpseuniform = /obj/item/clothing/under/rank/medical
|
||||
corpsesuit = /obj/item/clothing/suit/storage/labcoat
|
||||
corpsesuit = /obj/item/clothing/suit/storage/toggle/labcoat
|
||||
corpseback = /obj/item/weapon/storage/backpack/medic
|
||||
corpsepocket1 = /obj/item/device/flashlight/pen
|
||||
corpseshoes = /obj/item/clothing/shoes/black
|
||||
@@ -161,9 +161,9 @@
|
||||
corpseidaccess = "Station Engineer"
|
||||
|
||||
/obj/effect/landmark/corpse/engineer/rig
|
||||
corpsesuit = /obj/item/clothing/suit/space/rig/engineering
|
||||
corpsesuit = /obj/item/clothing/suit/space/void/engineering
|
||||
corpsemask = /obj/item/clothing/mask/breath
|
||||
corpsehelmet = /obj/item/clothing/head/helmet/space/rig/engineering
|
||||
corpsehelmet = /obj/item/clothing/head/helmet/space/void/engineering
|
||||
|
||||
/obj/effect/landmark/corpse/clown
|
||||
name = "Clown"
|
||||
@@ -181,7 +181,7 @@
|
||||
name = "Scientist"
|
||||
corpseradio = /obj/item/device/radio/headset/headset_sci
|
||||
corpseuniform = /obj/item/clothing/under/rank/scientist
|
||||
corpsesuit = /obj/item/clothing/suit/storage/labcoat/science
|
||||
corpsesuit = /obj/item/clothing/suit/storage/toggle/labcoat/science
|
||||
corpseback = /obj/item/weapon/storage/backpack
|
||||
corpseshoes = /obj/item/clothing/shoes/white
|
||||
corpseid = 1
|
||||
@@ -199,9 +199,9 @@
|
||||
corpseidaccess = "Shaft Miner"
|
||||
|
||||
/obj/effect/landmark/corpse/miner/rig
|
||||
corpsesuit = /obj/item/clothing/suit/space/rig/mining
|
||||
corpsesuit = /obj/item/clothing/suit/space/void/mining
|
||||
corpsemask = /obj/item/clothing/mask/breath
|
||||
corpsehelmet = /obj/item/clothing/head/helmet/space/rig/mining
|
||||
corpsehelmet = /obj/item/clothing/head/helmet/space/void/mining
|
||||
|
||||
|
||||
/////////////////Officers//////////////////////
|
||||
|
||||
@@ -120,13 +120,13 @@ obj/machinery/gateway/centerstation/process()
|
||||
if(!awaygate) return
|
||||
if(awaygate.calibrated)
|
||||
M.loc = get_step(awaygate.loc, SOUTH)
|
||||
M.dir = SOUTH
|
||||
M.set_dir(SOUTH)
|
||||
return
|
||||
else
|
||||
var/obj/effect/landmark/dest = pick(awaydestinations)
|
||||
if(dest)
|
||||
M.loc = dest.loc
|
||||
M.dir = SOUTH
|
||||
M.set_dir(SOUTH)
|
||||
use_power(5000)
|
||||
return
|
||||
|
||||
@@ -222,7 +222,7 @@ obj/machinery/gateway/centerstation/process()
|
||||
M << "\black The station gate has detected your exile implant and is blocking your entry."
|
||||
return
|
||||
M.loc = get_step(stationgate.loc, SOUTH)
|
||||
M.dir = SOUTH
|
||||
M.set_dir(SOUTH)
|
||||
|
||||
|
||||
/obj/machinery/gateway/centeraway/attackby(obj/item/device/W as obj, mob/user as mob)
|
||||
|
||||
@@ -110,7 +110,7 @@
|
||||
if(byond_version < MIN_CLIENT_VERSION) //Out of date client.
|
||||
return null
|
||||
|
||||
if(!guests_allowed && IsGuestKey(key))
|
||||
if(!config.guests_allowed && IsGuestKey(key))
|
||||
alert(src,"This server doesn't allow guest accounts to play. Please go to http://www.byond.com/ and register for a key.","Guest","OK")
|
||||
del(src)
|
||||
return
|
||||
@@ -299,5 +299,6 @@
|
||||
'icons/spideros_icons/sos_12.png',
|
||||
'icons/spideros_icons/sos_13.png',
|
||||
'icons/spideros_icons/sos_14.png',
|
||||
'html/images/ntlogo.png'
|
||||
'html/images/ntlogo.png',
|
||||
'html/images/talisman.png'
|
||||
)
|
||||
|
||||
@@ -11,17 +11,16 @@ var/global/list/special_roles = list( //keep synced with the defines BE_* in set
|
||||
"malf AI" = IS_MODE_COMPILED("malfunction"), // 4
|
||||
"revolutionary" = IS_MODE_COMPILED("revolution"), // 5
|
||||
"alien candidate" = 1, //always show // 6
|
||||
"pAI candidate" = 1, // -- TLE // 7
|
||||
"positronic brain" = 1, // 7
|
||||
"cultist" = IS_MODE_COMPILED("cult"), // 8
|
||||
"infested monkey" = IS_MODE_COMPILED("monkey"), // 9
|
||||
"ninja" = "true", // 10
|
||||
"vox raider" = IS_MODE_COMPILED("heist"), // 11
|
||||
"diona" = 1, // 12
|
||||
"mutineer" = IS_MODE_COMPILED("mutiny"), // 13
|
||||
"pAI candidate" = 1, // -- TLE // 14
|
||||
)
|
||||
|
||||
var/const/MAX_SAVE_SLOTS = 10
|
||||
|
||||
//used for alternate_option
|
||||
#define GET_RANDOM_JOB 0
|
||||
#define BE_ASSISTANT 1
|
||||
@@ -41,7 +40,7 @@ datum/preferences
|
||||
|
||||
//game-preferences
|
||||
var/lastchangelog = "" //Saved changlog filesize to detect if there was a change
|
||||
var/ooccolor = "#b82e00"
|
||||
var/ooccolor = "#010000" //Whatever this is set to acts as 'reset' color and is thus unusable as an actual custom color
|
||||
var/be_special = 0 //Special role selection
|
||||
var/UI_style = "Midnight"
|
||||
var/toggles = TOGGLES_DEFAULT
|
||||
@@ -74,6 +73,7 @@ datum/preferences
|
||||
var/g_eyes = 0 //Eye color
|
||||
var/b_eyes = 0 //Eye color
|
||||
var/species = "Human" //Species datum to use.
|
||||
var/species_preview //Used for the species selection window.
|
||||
var/language = "None" //Secondary language
|
||||
var/list/gear //Custom/fluff item loadout.
|
||||
|
||||
@@ -114,6 +114,7 @@ datum/preferences
|
||||
var/list/player_alt_titles = new() // the default name of a job like "Medical Doctor"
|
||||
|
||||
var/list/flavor_texts = list()
|
||||
var/list/flavour_texts_robot = list()
|
||||
|
||||
var/med_record = ""
|
||||
var/sec_record = ""
|
||||
@@ -138,7 +139,7 @@ datum/preferences
|
||||
if(load_character())
|
||||
return
|
||||
gender = pick(MALE, FEMALE)
|
||||
real_name = random_name(gender)
|
||||
real_name = random_name(gender,species)
|
||||
|
||||
gear = list()
|
||||
|
||||
@@ -302,7 +303,7 @@ datum/preferences
|
||||
dat += "<br><table><tr><td><b>Body</b> "
|
||||
dat += "(<a href='?_src_=prefs;preference=all;task=random'>®</A>)"
|
||||
dat += "<br>"
|
||||
dat += "Species: <a href='byond://?src=\ref[user];preference=species;task=input'>[species]</a><br>"
|
||||
dat += "Species: <a href='?src=\ref[user];preference=species;task=change'>[species]</a><br>"
|
||||
dat += "Secondary Language:<br><a href='byond://?src=\ref[user];preference=language;task=input'>[language]</a><br>"
|
||||
dat += "Blood Type: <a href='byond://?src=\ref[user];preference=b_type;task=input'>[b_type]</a><br>"
|
||||
dat += "Skin Tone: <a href='?_src_=prefs;preference=s_tone;task=input'>[-s_tone + 35]/220<br></a>"
|
||||
@@ -397,6 +398,7 @@ datum/preferences
|
||||
dat += "\t<a href=\"byond://?src=\ref[user];preference=skills\"><b>Set Skills</b> (<i>[GetSkillClass(used_skillpoints)][used_skillpoints > 0 ? " [used_skillpoints]" : "0"])</i></a><br>"
|
||||
|
||||
dat += "<a href='byond://?src=\ref[user];preference=flavor_text;task=open'><b>Set Flavor Text</b></a><br>"
|
||||
dat += "<a href='byond://?src=\ref[user];preference=flavour_text_robot;task=open'><b>Set Robot Flavour Text</b></a><br>"
|
||||
|
||||
dat += "<a href='byond://?src=\ref[user];preference=pAI'><b>pAI Configuration</b></a><br>"
|
||||
dat += "<br>"
|
||||
@@ -430,11 +432,8 @@ datum/preferences
|
||||
var/n = 0
|
||||
for (var/i in special_roles)
|
||||
if(special_roles[i]) //if mode is available on the server
|
||||
if(jobban_isbanned(user, i))
|
||||
dat += "<b>Be [i]:</b> <font color=red><b> \[BANNED]</b></font><br>"
|
||||
else if(i == "pai candidate")
|
||||
if(jobban_isbanned(user, "pAI"))
|
||||
dat += "<b>Be [i]:</b> <font color=red><b> \[BANNED]</b></font><br>"
|
||||
if(jobban_isbanned(user, i) || (i == "positronic brain" && jobban_isbanned(user, "AI") && jobban_isbanned(user, "Cyborg")) || (i == "pAI candidate" && jobban_isbanned(user, "pAI")))
|
||||
dat += "<b>Be [i]:<b> <font color=red><b> \[BANNED]</b></font><br>"
|
||||
else
|
||||
dat += "<b>Be [i]:</b> <a href='?_src_=prefs;preference=be_special;num=[n]'><b>[src.be_special&(1<<n) ? "Yes" : "No"]</b></a><br>"
|
||||
n++
|
||||
@@ -509,6 +508,8 @@ datum/preferences
|
||||
HTML += " <font color=green>\[Yes]</font>"
|
||||
else
|
||||
HTML += " <font color=red>\[No]</font>"
|
||||
if(job.alt_titles) //Blatantly cloned from a few lines down.
|
||||
HTML += "</a></td></tr><tr bgcolor='[lastJob.selection_color]'><td width='60%' align='center'><a> </a></td><td><a href=\"byond://?src=\ref[user];preference=job;task=alt_title;job=\ref[job]\">\[[GetPlayerAltTitle(job)]\]</a></td></tr>"
|
||||
HTML += "</a></td></tr>"
|
||||
continue
|
||||
|
||||
@@ -588,6 +589,70 @@ datum/preferences
|
||||
user << browse(HTML, "window=records;size=350x300")
|
||||
return
|
||||
|
||||
/datum/preferences/proc/SetSpecies(mob/user)
|
||||
if(!species_preview || !(species_preview in all_species))
|
||||
species_preview = "Human"
|
||||
var/datum/species/current_species = all_species[species_preview]
|
||||
var/dat = "<body>"
|
||||
dat += "<center><h2>[current_species.name] \[<a href='?src=\ref[user];preference=species;task=change'>change</a>\]</h2></center><hr/>"
|
||||
dat += "<table padding='8px'>"
|
||||
dat += "<tr>"
|
||||
dat += "<td width = 400>[current_species.blurb]</td>"
|
||||
dat += "<td width = 200 align='center'>"
|
||||
if("preview" in icon_states(current_species.icobase))
|
||||
usr << browse_rsc(icon(current_species.icobase,"preview"), "species_preview_[current_species.name].png")
|
||||
dat += "<img src='species_preview_[current_species.name].png' width='64px' height='64px'><br/><br/>"
|
||||
dat += "<b>Language:</b> [current_species.language]<br/>"
|
||||
dat += "<small>"
|
||||
if(current_species.flags & CAN_JOIN)
|
||||
dat += "</br><b>Often present on human stations.</b>"
|
||||
if(current_species.flags & IS_WHITELISTED)
|
||||
dat += "</br><b>Whitelist restricted.</b>"
|
||||
if(current_species.flags & NO_BLOOD)
|
||||
dat += "</br><b>Does not have blood.</b>"
|
||||
if(current_species.flags & NO_BREATHE)
|
||||
dat += "</br><b>Does not breathe.</b>"
|
||||
if(current_species.flags & NO_SCAN)
|
||||
dat += "</br><b>Does not have DNA.</b>"
|
||||
if(current_species.flags & NO_PAIN)
|
||||
dat += "</br><b>Does not feel pain.</b>"
|
||||
if(current_species.flags & NO_SLIP)
|
||||
dat += "</br><b>Has excellent traction.</b>"
|
||||
if(current_species.flags & NO_POISON)
|
||||
dat += "</br><b>Immune to most poisons.</b>"
|
||||
if(current_species.flags & HAS_SKIN_TONE)
|
||||
dat += "</br><b>Has a variety of skin tones.</b>"
|
||||
if(current_species.flags & HAS_SKIN_COLOR)
|
||||
dat += "</br><b>Has a variety of skin colours.</b>"
|
||||
if(current_species.flags & HAS_EYE_COLOR)
|
||||
dat += "</br><b>Has a variety of eye colours.</b>"
|
||||
if(current_species.flags & IS_PLANT)
|
||||
dat += "</br><b>Has a plantlike physiology.</b>"
|
||||
if(current_species.flags & IS_SYNTHETIC)
|
||||
dat += "</br><b>Is machine-based.</b>"
|
||||
dat += "</small></td>"
|
||||
dat += "</tr>"
|
||||
dat += "</table><center><hr/>"
|
||||
|
||||
var/restricted = 0
|
||||
if(config.usealienwhitelist) //If we're using the whitelist, make sure to check it!
|
||||
if(!(current_species.flags & CAN_JOIN))
|
||||
restricted = 2
|
||||
else if((current_species.flags & IS_WHITELISTED) && !is_alien_whitelisted(user,current_species))
|
||||
restricted = 1
|
||||
|
||||
if(restricted)
|
||||
if(restricted == 1)
|
||||
dat += "<font color='red'><b>You cannot play as this species.</br><small>If you wish to be whitelisted, you can make an application post on <a href='?src=\ref[user];preference=open_whitelist_forum'>the forums</a>.</small></b></font></br>"
|
||||
else if(restricted == 2)
|
||||
dat += "<font color='red'><b>You cannot play as this species.</br><small>This species is not available for play as a station race..</small></b></font></br>"
|
||||
if(!restricted || check_rights(R_ADMIN, 0))
|
||||
dat += "\[<a href='?src=\ref[user];preference=species;task=input;newspecies=[species_preview]'>select</a>\]"
|
||||
dat += "</center></body>"
|
||||
|
||||
user << browse(null, "window=preferences")
|
||||
user << browse(dat, "window=species;size=700x400")
|
||||
|
||||
/datum/preferences/proc/SetAntagoptions(mob/user)
|
||||
if(uplinklocation == "" || !uplinklocation)
|
||||
uplinklocation = "PDA"
|
||||
@@ -652,6 +717,25 @@ datum/preferences
|
||||
user << browse(HTML, "window=flavor_text;size=430x300")
|
||||
return
|
||||
|
||||
/datum/preferences/proc/SetFlavourTextRobot(mob/user)
|
||||
var/HTML = "<body>"
|
||||
HTML += "<tt><center>"
|
||||
HTML += "<b>Set Robot Flavour Text</b> <hr />"
|
||||
HTML += "<br></center>"
|
||||
HTML += "<a href ='byond://?src=\ref[user];preference=flavour_text_robot;task=Default'>Default:</a> "
|
||||
HTML += TextPreview(flavour_texts_robot["Default"])
|
||||
HTML += "<hr />"
|
||||
for(var/module in robot_module_types)
|
||||
HTML += "<a href='byond://?src=\ref[user];preference=flavour_text_robot;task=[module]'>[module]:</a> "
|
||||
HTML += TextPreview(flavour_texts_robot[module])
|
||||
HTML += "<br>"
|
||||
HTML += "<hr />"
|
||||
HTML +="<a href='?src=\ref[user];preference=flavour_text_robot;task=done'>\[Done\]</a>"
|
||||
HTML += "<tt>"
|
||||
user << browse(null, "window=preferences")
|
||||
user << browse(HTML, "window=flavour_text_robot;size=430x300")
|
||||
return
|
||||
|
||||
/datum/preferences/proc/GetPlayerAltTitle(datum/job/job)
|
||||
return player_alt_titles.Find(job.title) > 0 \
|
||||
? player_alt_titles[job.title] \
|
||||
@@ -788,6 +872,14 @@ datum/preferences
|
||||
if(!user) return
|
||||
|
||||
if(!istype(user, /mob/new_player)) return
|
||||
|
||||
if(href_list["preference"] == "open_whitelist_forum")
|
||||
if(config.forumurl)
|
||||
user << link(config.forumurl)
|
||||
else
|
||||
user << "<span class='danger'>The forum URL is not set in the server configuration.</span>"
|
||||
return
|
||||
|
||||
if(href_list["preference"] == "job")
|
||||
switch(href_list["task"])
|
||||
if("close")
|
||||
@@ -918,6 +1010,30 @@ datum/preferences
|
||||
SetFlavorText(user)
|
||||
return
|
||||
|
||||
else if(href_list["preference"] == "flavour_text_robot")
|
||||
switch(href_list["task"])
|
||||
if("open")
|
||||
SetFlavourTextRobot(user)
|
||||
return
|
||||
if("done")
|
||||
user << browse(null, "window=flavour_text_robot")
|
||||
ShowChoices(user)
|
||||
return
|
||||
if("Default")
|
||||
var/msg = input(usr,"Set the default flavour text for your robot. It will be used for any module without individual setting.","Flavour Text",html_decode(flavour_texts_robot["Default"])) as message
|
||||
if(msg != null)
|
||||
msg = copytext(msg, 1, MAX_MESSAGE_LEN)
|
||||
msg = html_encode(msg)
|
||||
flavour_texts_robot[href_list["task"]] = msg
|
||||
else
|
||||
var/msg = input(usr,"Set the flavour text for your robot with [href_list["task"]] module. If you leave this empty, default flavour text will be used for this module.","Flavour Text",html_decode(flavour_texts_robot[href_list["task"]])) as message
|
||||
if(msg != null)
|
||||
msg = copytext(msg, 1, MAX_MESSAGE_LEN)
|
||||
msg = html_encode(msg)
|
||||
flavour_texts_robot[href_list["task"]] = msg
|
||||
SetFlavourTextRobot(user)
|
||||
return
|
||||
|
||||
else if(href_list["preference"] == "pAI")
|
||||
paiController.recruitWindow(user, 0)
|
||||
return 1
|
||||
@@ -1035,10 +1151,18 @@ datum/preferences
|
||||
break
|
||||
|
||||
switch(href_list["task"])
|
||||
if("change")
|
||||
if(href_list["preference"] == "species")
|
||||
// Actual whitelist checks are handled elsewhere, this is just for accessing the preview window.
|
||||
var/choice = input("Which species would you like to look at?") as null|anything in playable_species
|
||||
if(!choice) return
|
||||
species_preview = choice
|
||||
SetSpecies(user)
|
||||
|
||||
if("random")
|
||||
switch(href_list["preference"])
|
||||
if("name")
|
||||
real_name = random_name(gender)
|
||||
real_name = random_name(gender,species)
|
||||
if("age")
|
||||
age = rand(AGE_MIN, AGE_MAX)
|
||||
if("hair")
|
||||
@@ -1090,24 +1214,11 @@ datum/preferences
|
||||
var/new_age = input(user, "Choose your character's age:\n([AGE_MIN]-[AGE_MAX])", "Character Preference") as num|null
|
||||
if(new_age)
|
||||
age = max(min( round(text2num(new_age)), AGE_MAX),AGE_MIN)
|
||||
|
||||
if("species")
|
||||
|
||||
var/list/new_species = list("Human")
|
||||
user << browse(null, "window=species")
|
||||
var/prev_species = species
|
||||
var/whitelisted = 0
|
||||
|
||||
if(config.usealienwhitelist) //If we're using the whitelist, make sure to check it!
|
||||
for(var/S in whitelisted_species)
|
||||
if(is_alien_whitelisted(user,S))
|
||||
new_species += S
|
||||
whitelisted = 1
|
||||
if(!whitelisted)
|
||||
alert(user, "You cannot change your species as you need to be whitelisted. If you wish to be whitelisted contact an admin in-game, on the forums, or on IRC.")
|
||||
else //Not using the whitelist? Aliens for everyone!
|
||||
new_species = whitelisted_species
|
||||
|
||||
species = input("Please select a species", "Character Generation", null) in new_species
|
||||
|
||||
species = href_list["newspecies"]
|
||||
if(prev_species != species)
|
||||
//grab one of the valid hair styles for the newly chosen species
|
||||
var/list/valid_hairstyles = list()
|
||||
@@ -1510,7 +1621,7 @@ datum/preferences
|
||||
|
||||
/datum/preferences/proc/copy_to(mob/living/carbon/human/character, safety = 0)
|
||||
if(be_random_name)
|
||||
real_name = random_name(gender)
|
||||
real_name = random_name(gender,species)
|
||||
|
||||
if(config.humans_need_surnames)
|
||||
var/firstspace = findtext(real_name, " ")
|
||||
@@ -1577,8 +1688,8 @@ datum/preferences
|
||||
|
||||
for(var/name in organ_data)
|
||||
|
||||
var/status = organ_data[name]
|
||||
var/datum/organ/external/O = character.organs_by_name[name]
|
||||
var/status = organ_data[name]
|
||||
var/datum/organ/external/O = character.organs_by_name[name]
|
||||
if(O)
|
||||
if(status == "amputated")
|
||||
O.amputated = 1
|
||||
@@ -1586,7 +1697,7 @@ datum/preferences
|
||||
O.destspawn = 1
|
||||
else if(status == "cyborg")
|
||||
O.status |= ORGAN_ROBOT
|
||||
else
|
||||
else
|
||||
var/datum/organ/internal/I = character.internal_organs_by_name[name]
|
||||
if(I)
|
||||
if(status == "assisted")
|
||||
@@ -1620,7 +1731,7 @@ datum/preferences
|
||||
if(S)
|
||||
dat += "<b>Select a character slot to load</b><hr>"
|
||||
var/name
|
||||
for(var/i=1, i<=MAX_SAVE_SLOTS, i++)
|
||||
for(var/i=1, i<= config.character_slots, i++)
|
||||
S.cd = "/character[i]"
|
||||
S["real_name"] >> name
|
||||
if(!name) name = "Character[i]"
|
||||
@@ -1634,4 +1745,4 @@ datum/preferences
|
||||
user << browse(dat, "window=saves;size=300x390")
|
||||
|
||||
/datum/preferences/proc/close_load_dialog(mob/user)
|
||||
user << browse(null, "window=saves")
|
||||
user << browse(null, "window=saves")
|
||||
@@ -1,18 +1,46 @@
|
||||
var/global/list/gear_datums = list()
|
||||
|
||||
/hook/startup/proc/populate_gear_list()
|
||||
var/list/sort_categories = list(
|
||||
"[slot_head]" = list(),
|
||||
"ears" = list(),
|
||||
"[slot_glasses]" = list(),
|
||||
"[slot_wear_mask]" = list(),
|
||||
"[slot_w_uniform]" = list(),
|
||||
"[slot_tie]" = list(),
|
||||
"[slot_wear_suit]" = list(),
|
||||
"[slot_gloves]" = list(),
|
||||
"[slot_shoes]" = list(),
|
||||
"utility" = list(),
|
||||
"misc" = list(),
|
||||
"unknown" = list(),
|
||||
)
|
||||
|
||||
//create a list of gear datums to sort
|
||||
for(var/type in typesof(/datum/gear)-/datum/gear)
|
||||
var/datum/gear/G = new type()
|
||||
gear_datums[G.display_name] = G
|
||||
|
||||
var/category = (G.sort_category in sort_categories)? G.sort_category : "unknown"
|
||||
sort_categories[category][G.display_name] = G
|
||||
|
||||
for (var/category in sort_categories)
|
||||
gear_datums.Add(sortAssoc(sort_categories[category]))
|
||||
|
||||
return 1
|
||||
|
||||
/datum/gear
|
||||
var/display_name //Name/index.
|
||||
var/display_name //Name/index. Must be unique.
|
||||
var/path //Path to item.
|
||||
var/cost //Number of points used.
|
||||
var/slot //Slot to equip to.
|
||||
var/list/allowed_roles //Roles that can spawn with this item.
|
||||
var/whitelisted //Term to check the whitelist for..
|
||||
var/sort_category
|
||||
|
||||
/datum/gear/New()
|
||||
..()
|
||||
if (!sort_category)
|
||||
sort_category = "[slot]"
|
||||
|
||||
// This is sorted both by slot and alphabetically! Don't fuck it up!
|
||||
// Headslot items
|
||||
@@ -23,6 +51,12 @@ var/global/list/gear_datums = list()
|
||||
cost = 2
|
||||
slot = slot_head
|
||||
|
||||
/datum/gear/obandana
|
||||
display_name = "bandana, orange"
|
||||
path = /obj/item/clothing/head/orangebandana
|
||||
cost = 2
|
||||
slot = slot_head
|
||||
|
||||
/datum/gear/bandana
|
||||
display_name = "bandana, pirate-red"
|
||||
path = /obj/item/clothing/head/bandana
|
||||
@@ -171,6 +205,13 @@ var/global/list/gear_datums = list()
|
||||
cost = 2
|
||||
slot = slot_head
|
||||
|
||||
// Wig by Earthcrusher, blame him.
|
||||
/datum/gear/philosopher_wig
|
||||
display_name = "natural philosopher's wig"
|
||||
path = /obj/item/clothing/head/philosopher_wig
|
||||
cost = 3
|
||||
slot = slot_head
|
||||
|
||||
/datum/gear/ushanka
|
||||
display_name = "ushanka"
|
||||
path = /obj/item/clothing/head/ushanka
|
||||
@@ -260,7 +301,7 @@ var/global/list/gear_datums = list()
|
||||
cost = 2
|
||||
|
||||
/datum/gear/skirt_red
|
||||
display_name = " plaid skirt, red"
|
||||
display_name = "plaid skirt, red"
|
||||
path = /obj/item/clothing/under/dress/plaid_red
|
||||
slot = slot_w_uniform
|
||||
cost = 2
|
||||
@@ -277,6 +318,18 @@ var/global/list/gear_datums = list()
|
||||
slot = slot_w_uniform
|
||||
cost = 3
|
||||
|
||||
/datum/gear/sundress_white
|
||||
display_name = "sundress, white"
|
||||
path = /obj/item/clothing/under/sundress_white
|
||||
slot = slot_w_uniform
|
||||
cost = 3
|
||||
|
||||
/datum/gear/cheongsam
|
||||
display_name = "cheongsam, white"
|
||||
path = /obj/item/clothing/under/cheongsam
|
||||
slot = slot_w_uniform
|
||||
cost = 3
|
||||
|
||||
/datum/gear/uniform_captain
|
||||
display_name = "uniform, captain's dress"
|
||||
path = /obj/item/clothing/under/dress/dress_cap
|
||||
@@ -317,74 +370,88 @@ var/global/list/gear_datums = list()
|
||||
/datum/gear/armband_cargo
|
||||
display_name = "armband, cargo"
|
||||
path = /obj/item/clothing/tie/armband/cargo
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband_emt
|
||||
display_name = "armband, EMT"
|
||||
path = /obj/item/clothing/tie/armband/medgreen
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
|
||||
/datum/gear/armband_engineering
|
||||
display_name = "armband, engineering"
|
||||
path = /obj/item/clothing/tie/armband/engine
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband_hydroponics
|
||||
display_name = "armband, hydroponics"
|
||||
path = /obj/item/clothing/tie/armband/hydro
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband_medical
|
||||
display_name = "armband, medical"
|
||||
path = /obj/item/clothing/tie/armband/med
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband
|
||||
display_name = "armband, red"
|
||||
path = /obj/item/clothing/tie/armband
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband_science
|
||||
display_name = "armband, science"
|
||||
path = /obj/item/clothing/tie/armband/science
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armpit
|
||||
display_name = "shoulder holster"
|
||||
path = /obj/item/clothing/tie/holster/armpit
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
allowed_roles = list("Captain", "Head of Personnel", "Security Officer", "Head of Security")
|
||||
allowed_roles = list("Captain", "Head of Personnel", "Security Officer", "Warden", "Head of Security")
|
||||
|
||||
/datum/gear/tie_blue
|
||||
display_name = "tie, blue"
|
||||
path = /obj/item/clothing/tie/blue
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/tie_red
|
||||
display_name = "tie, red"
|
||||
path = /obj/item/clothing/tie/red
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/tie_horrible
|
||||
display_name = "tie, socially disgraceful"
|
||||
path = /obj/item/clothing/tie/horrible
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/brown_vest
|
||||
display_name = "webbing, engineering"
|
||||
path = /obj/item/clothing/tie/storage/brown_vest
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
allowed_roles = list("Station Engineer","Atmospheric Technician","Chief Engineer")
|
||||
|
||||
/datum/gear/black_vest
|
||||
display_name = "webbing, security"
|
||||
path = /obj/item/clothing/tie/storage/black_vest
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
allowed_roles = list("Security Officer","Head of Security","Warden")
|
||||
|
||||
/datum/gear/webbing
|
||||
display_name = "webbing, simple"
|
||||
path = /obj/item/clothing/tie/storage/webbing
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
|
||||
// Suit slot
|
||||
@@ -396,11 +463,41 @@ var/global/list/gear_datums = list()
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/bomber
|
||||
display_name = "bomberjacker"
|
||||
path = /obj/item/clothing/suit/bomber
|
||||
display_name = "bomber jacket"
|
||||
path = /obj/item/clothing/suit/storage/bomber
|
||||
cost = 4
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/leather_jacket
|
||||
display_name = "leather jacket, black"
|
||||
path = /obj/item/clothing/suit/storage/leather_jacket
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/leather_jacket_nt
|
||||
display_name = "leather jacket, NanoTrasen, black"
|
||||
path = /obj/item/clothing/suit/storage/leather_jacket/nanotrasen
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/brown_jacket
|
||||
display_name = "leather jacket, brown"
|
||||
path = /obj/item/clothing/suit/storage/toggle/brown_jacket
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/brown_jacket_nt
|
||||
display_name = "leather jacket, NanoTrasen, brown"
|
||||
path = /obj/item/clothing/suit/storage/toggle/brown_jacket/nanotrasen
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/hoodie
|
||||
display_name = "hoodie, grey"
|
||||
path = /obj/item/clothing/suit/hoodie
|
||||
cost = 2
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/unathi_mantle
|
||||
display_name = "hide mantle (Unathi)"
|
||||
path = /obj/item/clothing/suit/unathi/mantle
|
||||
@@ -410,7 +507,7 @@ var/global/list/gear_datums = list()
|
||||
|
||||
/datum/gear/labcoat
|
||||
display_name = "labcoat"
|
||||
path = /obj/item/clothing/suit/storage/labcoat
|
||||
path = /obj/item/clothing/suit/storage/toggle/labcoat
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
@@ -420,22 +517,34 @@ var/global/list/gear_datums = list()
|
||||
cost = 2
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/gponcho
|
||||
display_name = "poncho, blue"
|
||||
path = /obj/item/clothing/suit/poncho/blue
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/gponcho
|
||||
display_name = "poncho, green"
|
||||
path = /obj/item/clothing/suit/poncho/green
|
||||
cost = 4
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/rponcho
|
||||
display_name = "poncho, purple"
|
||||
path = /obj/item/clothing/suit/poncho/purple
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/rponcho
|
||||
display_name = "poncho, red"
|
||||
path = /obj/item/clothing/suit/poncho/red
|
||||
cost = 4
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/poncho
|
||||
display_name = "poncho, tan"
|
||||
path = /obj/item/clothing/suit/poncho
|
||||
cost = 4
|
||||
cost = 3
|
||||
slot = slot_wear_suit
|
||||
|
||||
/datum/gear/unathi_robe
|
||||
@@ -594,16 +703,54 @@ var/global/list/gear_datums = list()
|
||||
cost = 1
|
||||
slot = slot_shoes
|
||||
|
||||
// "Useful" items
|
||||
// "Useful" items - I'm guessing things that might be used at work?
|
||||
|
||||
/datum/gear/briefcase
|
||||
display_name = "briefcase"
|
||||
path = /obj/item/weapon/storage/briefcase
|
||||
sort_category = "utility"
|
||||
cost = 2
|
||||
|
||||
/datum/gear/matchbook
|
||||
display_name = "matchbook"
|
||||
path = /obj/item/weapon/storage/box/matches
|
||||
/datum/gear/clipboard
|
||||
display_name = "clipboard"
|
||||
path = /obj/item/weapon/clipboard
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_blue
|
||||
display_name = "folder, blue"
|
||||
path = /obj/item/weapon/folder/blue
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_grey
|
||||
display_name = "folder, grey"
|
||||
path = /obj/item/weapon/folder
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_red
|
||||
display_name = "folder, red"
|
||||
path = /obj/item/weapon/folder/red
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_white
|
||||
display_name = "folder, white"
|
||||
path = /obj/item/weapon/folder/white
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_yellow
|
||||
display_name = "folder, yellow"
|
||||
path = /obj/item/weapon/folder/yellow
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/paicard
|
||||
display_name = "personal AI device"
|
||||
path = /obj/item/device/paicard
|
||||
sort_category = "utility"
|
||||
cost = 2
|
||||
|
||||
// The rest of the trash.
|
||||
@@ -611,49 +758,94 @@ var/global/list/gear_datums = list()
|
||||
/datum/gear/ashtray
|
||||
display_name = "ashtray, plastic"
|
||||
path = /obj/item/ashtray/plastic
|
||||
sort_category = "misc"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/cane
|
||||
display_name = "cane"
|
||||
path = /obj/item/weapon/cane
|
||||
sort_category = "misc"
|
||||
cost = 2
|
||||
|
||||
/datum/gear/clipboard
|
||||
display_name = "clipboard"
|
||||
path = /obj/item/weapon/clipboard
|
||||
cost = 1
|
||||
|
||||
/datum/gear/dice
|
||||
display_name = "d20"
|
||||
path = /obj/item/weapon/dice/d20
|
||||
sort_category = "misc"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/cards
|
||||
display_name = "deck of cards"
|
||||
path = /obj/item/weapon/deck
|
||||
sort_category = "misc"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/blipstick
|
||||
display_name = "lipstick, black"
|
||||
path = /obj/item/weapon/lipstick/black
|
||||
sort_category = "misc"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/jlipstick
|
||||
display_name = "lipstick, jade"
|
||||
path = /obj/item/weapon/lipstick/jade
|
||||
sort_category = "misc"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/plipstick
|
||||
display_name = "lipstick, purple"
|
||||
path = /obj/item/weapon/lipstick/purple
|
||||
sort_category = "misc"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/rlipstick
|
||||
display_name = "lipstick, red"
|
||||
path = /obj/item/weapon/lipstick
|
||||
sort_category = "misc"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/matchbook
|
||||
display_name = "matchbook"
|
||||
path = /obj/item/weapon/storage/box/matches
|
||||
sort_category = "misc"
|
||||
cost = 2
|
||||
|
||||
/datum/gear/comb
|
||||
display_name = "purple comb"
|
||||
path = /obj/item/weapon/fluff/cado_keppel_1
|
||||
path = /obj/item/weapon/haircomb
|
||||
sort_category = "misc"
|
||||
cost = 2
|
||||
|
||||
/*/datum/gear/combitool
|
||||
display_name = "combi-tool"
|
||||
path = /obj/item/weapon/combitool
|
||||
cost = 3*/
|
||||
|
||||
// Stuff worn on the ears. Items here go in the "ears" sort_category but they must not use
|
||||
// the slot_r_ear or slot_l_ear as the slot, or else players will spawn with no headset.
|
||||
/datum/gear/skrell_chain
|
||||
display_name = "skrell headtail-wear, female, chain"
|
||||
path = /obj/item/clothing/ears/skrell/chain
|
||||
cost = 2
|
||||
sort_category = "ears"
|
||||
whitelisted = "Skrell"
|
||||
|
||||
/datum/gear/skrell_plate
|
||||
display_name = "skrell headtail-wear, male, bands"
|
||||
path = /obj/item/clothing/ears/skrell/band
|
||||
cost = 2
|
||||
sort_category = "ears"
|
||||
whitelisted = "Skrell"
|
||||
|
||||
/datum/gear/skrell_cloth_male
|
||||
display_name = "skrell headtail-wear, male, cloth"
|
||||
path = /obj/item/clothing/ears/skrell/cloth_male
|
||||
cost = 2
|
||||
sort_category = "ears"
|
||||
whitelisted = "Skrell"
|
||||
|
||||
/datum/gear/skrell_cloth_female
|
||||
display_name = "skrell headtail-wear, female, cloth"
|
||||
path = /obj/item/clothing/ears/skrell/cloth_female
|
||||
cost = 2
|
||||
sort_category = "ears"
|
||||
whitelisted = "Skrell"
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
lastchangelog = sanitize_text(lastchangelog, initial(lastchangelog))
|
||||
UI_style = sanitize_inlist(UI_style, list("White", "Midnight","Orange","old"), initial(UI_style))
|
||||
be_special = sanitize_integer(be_special, 0, 65535, initial(be_special))
|
||||
default_slot = sanitize_integer(default_slot, 1, MAX_SAVE_SLOTS, initial(default_slot))
|
||||
default_slot = sanitize_integer(default_slot, 1, config.character_slots, initial(default_slot))
|
||||
toggles = sanitize_integer(toggles, 0, 65535, initial(toggles))
|
||||
UI_style_color = sanitize_hexcolor(UI_style_color, initial(UI_style_color))
|
||||
UI_style_alpha = sanitize_integer(UI_style_alpha, 0, 255, initial(UI_style_alpha))
|
||||
@@ -94,7 +94,7 @@
|
||||
if(!S) return 0
|
||||
S.cd = "/"
|
||||
if(!slot) slot = default_slot
|
||||
slot = sanitize_integer(slot, 1, MAX_SAVE_SLOTS, initial(default_slot))
|
||||
slot = sanitize_integer(slot, 1, config.character_slots, initial(default_slot))
|
||||
if(slot != default_slot)
|
||||
default_slot = slot
|
||||
S["default_slot"] << slot
|
||||
@@ -154,6 +154,11 @@
|
||||
S["flavor_texts_legs"] >> flavor_texts["legs"]
|
||||
S["flavor_texts_feet"] >> flavor_texts["feet"]
|
||||
|
||||
//Flavour text for robots.
|
||||
S["flavour_texts_robot_Default"] >> flavour_texts_robot["Default"]
|
||||
for(var/module in robot_module_types)
|
||||
S["flavour_texts_robot_[module]"] >> flavour_texts_robot[module]
|
||||
|
||||
//Miscellaneous
|
||||
S["med_record"] >> med_record
|
||||
S["sec_record"] >> sec_record
|
||||
@@ -184,7 +189,7 @@
|
||||
metadata = sanitize_text(metadata, initial(metadata))
|
||||
real_name = reject_bad_name(real_name)
|
||||
|
||||
if(isnull(species) || !(species in whitelisted_species))
|
||||
if(isnull(species) || !(species in playable_species))
|
||||
species = "Human"
|
||||
|
||||
if(isnull(language)) language = "None"
|
||||
@@ -298,6 +303,11 @@
|
||||
S["flavor_texts_legs"] << flavor_texts["legs"]
|
||||
S["flavor_texts_feet"] << flavor_texts["feet"]
|
||||
|
||||
//Flavour text for robots.
|
||||
S["flavour_texts_robot_Default"] << flavour_texts_robot["Default"]
|
||||
for(var/module in robot_module_types)
|
||||
S["flavour_texts_robot_[module]"] << flavour_texts_robot[module]
|
||||
|
||||
//Miscellaneous
|
||||
S["med_record"] << med_record
|
||||
S["sec_record"] << sec_record
|
||||
@@ -328,4 +338,4 @@
|
||||
|
||||
|
||||
#undef SAVEFILE_VERSION_MAX
|
||||
#undef SAVEFILE_VERSION_MIN
|
||||
#undef SAVEFILE_VERSION_MIN
|
||||
@@ -10,6 +10,17 @@ var/list/spawntypes = list()
|
||||
var/msg //Message to display on the arrivals computer.
|
||||
var/list/turfs //List of turfs to spawn on.
|
||||
var/display_name //Name used in preference setup.
|
||||
var/list/restrict_job = null
|
||||
var/list/disallow_job = null
|
||||
|
||||
proc/check_job_spawning(job)
|
||||
if(restrict_job && !(job in restrict_job))
|
||||
return 0
|
||||
|
||||
if(disallow_job && (job in disallow_job))
|
||||
return 0
|
||||
|
||||
return 1
|
||||
|
||||
/datum/spawnpoint/arrivals
|
||||
display_name = "Arrivals Shuttle"
|
||||
@@ -30,7 +41,17 @@ var/list/spawntypes = list()
|
||||
/datum/spawnpoint/cryo
|
||||
display_name = "Cryogenic Storage"
|
||||
msg = "has completed cryogenic revival"
|
||||
disallow_job = list("Cyborg")
|
||||
|
||||
/datum/spawnpoint/cryo/New()
|
||||
..()
|
||||
turfs = latejoin_cryo
|
||||
turfs = latejoin_cryo
|
||||
|
||||
/datum/spawnpoint/cyborg
|
||||
display_name = "Cyborg Storage"
|
||||
msg = "has been activated from storage"
|
||||
restrict_job = list("Cyborg")
|
||||
|
||||
/datum/spawnpoint/cyborg/New()
|
||||
..()
|
||||
turfs = latejoin_cyborg
|
||||
@@ -121,6 +121,16 @@
|
||||
feedback_add_details("admin_verb","TLOOC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
|
||||
/client/verb/toggle_chattags()
|
||||
set name = "Show/Hide Chat Tags"
|
||||
set category = "Preferences"
|
||||
set desc = "Toggles seeing chat tags/icons"
|
||||
prefs.toggles ^= CHAT_NOICONS
|
||||
prefs.save_preferences()
|
||||
|
||||
src << "You will [!(prefs.toggles & CHAT_NOICONS) ? "now" : "no longer"] see chat tag icons."
|
||||
feedback_add_details("admin_verb","TCTAG") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
|
||||
/client/verb/Toggle_Soundscape() //All new ambience should be added here so it works with this verb until someone better at things comes up with a fix that isn't awful
|
||||
set name = "Hear/Silence Ambience"
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
/obj/item/clothing
|
||||
name = "clothing"
|
||||
siemens_coefficient = 0.9
|
||||
var/list/species_restricted = null //Only these species can wear this kit.
|
||||
|
||||
/*
|
||||
@@ -22,9 +23,8 @@
|
||||
return 0
|
||||
|
||||
if(species_restricted && istype(M,/mob/living/carbon/human))
|
||||
|
||||
var/wearable = null
|
||||
var/exclusive = null
|
||||
var/wearable = null
|
||||
var/mob/living/carbon/human/H = M
|
||||
|
||||
if("exclude" in species_restricted)
|
||||
@@ -38,17 +38,16 @@
|
||||
if(H.species.name in species_restricted)
|
||||
wearable = 1
|
||||
|
||||
if(!wearable && (slot != 15 && slot != 16)) //Pockets.
|
||||
M << "\red Your species cannot wear [src]."
|
||||
if(!wearable && !(slot in list(slot_l_store, slot_r_store, slot_s_store)))
|
||||
H << "<span class='danger'>Your species cannot wear [src].</span>"
|
||||
return 0
|
||||
|
||||
return 1
|
||||
|
||||
/obj/item/clothing/proc/refit_for_species(var/target_species)
|
||||
//Set species_restricted list
|
||||
switch(target_species)
|
||||
if("Human", "Skrell") //humanoid bodytypes
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
else
|
||||
species_restricted = list(target_species)
|
||||
|
||||
@@ -67,9 +66,9 @@
|
||||
//Set species_restricted list
|
||||
switch(target_species)
|
||||
if("Skrell")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox")
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
if("Human")
|
||||
species_restricted = list("exclude","Skrell","Unathi","Tajara","Diona","Vox")
|
||||
species_restricted = list("exclude","Skrell","Unathi","Tajara","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
else
|
||||
species_restricted = list(target_species)
|
||||
|
||||
@@ -143,7 +142,7 @@
|
||||
desc = O.desc
|
||||
icon = O.icon
|
||||
icon_state = O.icon_state
|
||||
dir = O.dir
|
||||
set_dir(O.dir)
|
||||
|
||||
/obj/item/clothing/ears/earmuffs
|
||||
name = "earmuffs"
|
||||
@@ -196,11 +195,6 @@ BLIND // can't see anything
|
||||
species_restricted = list("exclude","Unathi","Tajara")
|
||||
sprite_sheets = list("Vox" = 'icons/mob/species/vox/gloves.dmi')
|
||||
|
||||
/obj/item/clothing/gloves/examine()
|
||||
set src in usr
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/item/clothing/gloves/update_clothing_icon()
|
||||
if (ismob(src.loc))
|
||||
var/mob/M = src.loc
|
||||
@@ -247,6 +241,79 @@ BLIND // can't see anything
|
||||
slot_flags = SLOT_HEAD
|
||||
w_class = 2.0
|
||||
|
||||
var/light_overlay = "helmet_light"
|
||||
var/light_applied
|
||||
var/brightness_on
|
||||
var/on = 0
|
||||
|
||||
/obj/item/clothing/head/New()
|
||||
..()
|
||||
if(!icon_action_button && brightness_on)
|
||||
icon_action_button = "[icon_state]"
|
||||
|
||||
/obj/item/clothing/head/attack_self(mob/user)
|
||||
if(brightness_on)
|
||||
if(!isturf(user.loc))
|
||||
user << "You cannot turn the light on while in this [user.loc]"
|
||||
return
|
||||
on = !on
|
||||
user << "You [on ? "enable" : "disable"] the helmet light."
|
||||
update_light(user)
|
||||
else
|
||||
return ..(user)
|
||||
|
||||
/obj/item/clothing/head/proc/update_light(var/mob/user = null)
|
||||
if(on && !light_applied)
|
||||
if(loc == user)
|
||||
user.SetLuminosity(user.luminosity + brightness_on)
|
||||
SetLuminosity(brightness_on)
|
||||
light_applied = 1
|
||||
else if(!on && light_applied)
|
||||
if(loc == user)
|
||||
user.SetLuminosity(user.luminosity - brightness_on)
|
||||
SetLuminosity(0)
|
||||
light_applied = 0
|
||||
update_icon(user)
|
||||
|
||||
/obj/item/clothing/head/equipped(mob/user)
|
||||
..()
|
||||
spawn(1)
|
||||
if(on && loc == user && !light_applied)
|
||||
user.SetLuminosity(user.luminosity + brightness_on)
|
||||
light_applied = 1
|
||||
|
||||
/obj/item/clothing/head/dropped(mob/user)
|
||||
..()
|
||||
spawn(1)
|
||||
if(on && loc != user && light_applied)
|
||||
user.SetLuminosity(user.luminosity - brightness_on)
|
||||
light_applied = 0
|
||||
|
||||
/obj/item/clothing/head/update_icon(var/mob/user)
|
||||
|
||||
overlays.Cut()
|
||||
if(on)
|
||||
if(!light_overlay_cache["[light_overlay]_icon"])
|
||||
light_overlay_cache["[light_overlay]_icon"] = image("icon" = 'icons/obj/light_overlays.dmi', "icon_state" = "[light_overlay]")
|
||||
if(!light_overlay_cache["[light_overlay]"])
|
||||
light_overlay_cache["[light_overlay]"] = image("icon" = 'icons/mob/light_overlays.dmi', "icon_state" = "[light_overlay]")
|
||||
overlays |= light_overlay_cache["[light_overlay]_icon"]
|
||||
if(istype(user,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.update_inv_head()
|
||||
|
||||
/obj/item/clothing/head/equipped(mob/user)
|
||||
..()
|
||||
update_light(user)
|
||||
|
||||
/obj/item/clothing/head/pickup(mob/user)
|
||||
..()
|
||||
update_light(user)
|
||||
|
||||
/obj/item/clothing/head/dropped(mob/user)
|
||||
..()
|
||||
update_light(user)
|
||||
|
||||
/obj/item/clothing/head/update_clothing_icon()
|
||||
if (ismob(src.loc))
|
||||
var/mob/M = src.loc
|
||||
@@ -283,6 +350,7 @@ BLIND // can't see anything
|
||||
|
||||
permeability_coefficient = 0.50
|
||||
slowdown = SHOES_SLOWDOWN
|
||||
force = 2
|
||||
species_restricted = list("exclude","Unathi","Tajara")
|
||||
sprite_sheets = list("Vox" = 'icons/mob/species/vox/shoes.dmi')
|
||||
|
||||
@@ -387,20 +455,19 @@ BLIND // can't see anything
|
||||
return
|
||||
return
|
||||
|
||||
/obj/item/clothing/under/examine()
|
||||
set src in view()
|
||||
..()
|
||||
/obj/item/clothing/under/examine(mob/user)
|
||||
..(user)
|
||||
switch(src.sensor_mode)
|
||||
if(0)
|
||||
usr << "Its sensors appear to be disabled."
|
||||
user << "Its sensors appear to be disabled."
|
||||
if(1)
|
||||
usr << "Its binary life sensors appear to be enabled."
|
||||
user << "Its binary life sensors appear to be enabled."
|
||||
if(2)
|
||||
usr << "Its vital tracker appears to be enabled."
|
||||
user << "Its vital tracker appears to be enabled."
|
||||
if(3)
|
||||
usr << "Its vital tracker and tracking beacon appear to be enabled."
|
||||
user << "Its vital tracker and tracking beacon appear to be enabled."
|
||||
if(hastie)
|
||||
usr << "\A [hastie] is clipped to it."
|
||||
user << "\A [hastie] is clipped to it."
|
||||
|
||||
/obj/item/clothing/under/proc/set_sensors(mob/usr as mob)
|
||||
var/mob/M = usr
|
||||
@@ -492,5 +559,4 @@ BLIND // can't see anything
|
||||
/obj/item/clothing/under/emp_act(severity)
|
||||
if (hastie)
|
||||
hastie.emp_act(severity)
|
||||
..()
|
||||
|
||||
..()
|
||||
35
code/modules/clothing/ears/skrell.dm
Normal file
35
code/modules/clothing/ears/skrell.dm
Normal file
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
Skrell tentacle wear
|
||||
*/
|
||||
|
||||
/obj/item/clothing/ears/skrell
|
||||
name = "skrell tentacle wear"
|
||||
desc = "Some stuff worn by skrell to adorn their head tentacles."
|
||||
icon = 'icons/obj/clothing/ears.dmi'
|
||||
w_class = 1
|
||||
slot_flags = SLOT_EARS
|
||||
species_restricted = list("Skrell")
|
||||
|
||||
/obj/item/clothing/ears/skrell/chain
|
||||
name = "skrell headtail chains"
|
||||
desc = "A delicate golden chain worn by female skrell to decorate their head tails."
|
||||
icon_state = "skrell_chain"
|
||||
item_state = "skrell_chain"
|
||||
|
||||
/obj/item/clothing/ears/skrell/band
|
||||
name = "skrell headtail bands"
|
||||
desc = "Golden metallic bands worn by male skrell to adorn their head tails."
|
||||
icon_state = "skrell_band"
|
||||
item_state = "skrell_band"
|
||||
|
||||
/obj/item/clothing/ears/skrell/cloth_female
|
||||
name = "skrell headtail cloth"
|
||||
desc = "A cloth shawl worn by female skrell draped around their head tails."
|
||||
icon_state = "skrell_cloth_female"
|
||||
item_state = "skrell_cloth_female"
|
||||
|
||||
/obj/item/clothing/ears/skrell/cloth_male
|
||||
name = "skrell headtail cloth"
|
||||
desc = "A cloth band worn by male skrell around their head tails."
|
||||
icon_state = "skrell_cloth_male"
|
||||
item_state = "skrell_cloth_male"
|
||||
@@ -52,6 +52,10 @@
|
||||
icon_state = "purple"
|
||||
item_state = "glasses"
|
||||
|
||||
/obj/item/clothing/glasses/science/New()
|
||||
..()
|
||||
overlay = global_hud.science
|
||||
|
||||
/obj/item/clothing/glasses/night
|
||||
name = "Night Vision Goggles"
|
||||
desc = "You can totally see in the dark now!"
|
||||
|
||||
@@ -1,114 +0,0 @@
|
||||
/*
|
||||
Dear ninja gloves
|
||||
|
||||
This isn't because I like you
|
||||
this is because your father is a bastard
|
||||
|
||||
...
|
||||
I guess you're a little cool.
|
||||
-Sayu
|
||||
*/
|
||||
|
||||
/obj/item/clothing/gloves/space_ninja
|
||||
desc = "These nano-enhanced gloves insulate from electricity and provide fire resistance."
|
||||
name = "ninja gloves"
|
||||
icon_state = "s-ninja"
|
||||
item_state = "s-ninja"
|
||||
siemens_coefficient = 0
|
||||
var/draining = 0
|
||||
var/candrain = 0
|
||||
var/mindrain = 200
|
||||
var/maxdrain = 400
|
||||
species_restricted = null
|
||||
|
||||
/*
|
||||
This runs the gamut of what ninja gloves can do
|
||||
The other option would be a dedicated ninja touch bullshit proc on everything
|
||||
which would probably more efficient, but ninjas are pretty rare.
|
||||
This was mostly introduced to keep ninja code from contaminating other code;
|
||||
with this in place it would be easier to untangle the rest of it.
|
||||
|
||||
For the drain proc, see events/ninja.dm
|
||||
*/
|
||||
/obj/item/clothing/gloves/space_ninja/Touch(var/atom/A,var/proximity)
|
||||
if(!candrain || draining) return 0
|
||||
|
||||
var/mob/living/carbon/human/H = loc
|
||||
if(!istype(H)) return 0 // what
|
||||
var/obj/item/clothing/suit/space/space_ninja/suit = H.wear_suit
|
||||
if(!istype(suit)) return 0
|
||||
if(isturf(A)) return 0
|
||||
|
||||
if(!proximity) // todo: you could add ninja stars or computer hacking here
|
||||
return 0
|
||||
|
||||
// Move an AI into and out of things
|
||||
if(istype(A,/mob/living/silicon/ai))
|
||||
if(suit.s_control)
|
||||
A.add_fingerprint(H)
|
||||
suit.transfer_ai("AICORE", "NINJASUIT", A, H)
|
||||
return 1
|
||||
else
|
||||
H << "\red <b>ERROR</b>: \black Remote access channel disabled."
|
||||
return 0
|
||||
|
||||
if(istype(A,/obj/structure/AIcore/deactivated))
|
||||
if(suit.s_control)
|
||||
A.add_fingerprint(H)
|
||||
suit.transfer_ai("INACTIVE","NINJASUIT",A, H)
|
||||
return 1
|
||||
else
|
||||
H << "\red <b>ERROR</b>: \black Remote access channel disabled."
|
||||
return 0
|
||||
if(istype(A,/obj/machinery/computer/aifixer))
|
||||
if(suit.s_control)
|
||||
A.add_fingerprint(H)
|
||||
suit.transfer_ai("AIFIXER","NINJASUIT",A, H)
|
||||
return 1
|
||||
else
|
||||
H << "\red <b>ERROR</b>: \black Remote access channel disabled."
|
||||
return 0
|
||||
|
||||
// steal energy from powered things
|
||||
if(istype(A,/mob/living/silicon/robot))
|
||||
A.add_fingerprint(H)
|
||||
drain("CYBORG",A,suit)
|
||||
return 1
|
||||
if(istype(A,/obj/machinery/power/apc))
|
||||
A.add_fingerprint(H)
|
||||
drain("APC",A,suit)
|
||||
return 1
|
||||
if(istype(A,/obj/structure/cable))
|
||||
A.add_fingerprint(H)
|
||||
drain("WIRE",A,suit)
|
||||
return 1
|
||||
if(istype(A,/obj/structure/grille))
|
||||
var/obj/structure/cable/C = locate() in A.loc
|
||||
if(C)
|
||||
drain("WIRE",C,suit)
|
||||
return 1
|
||||
if(istype(A,/obj/machinery/power/smes))
|
||||
A.add_fingerprint(H)
|
||||
drain("SMES",A,suit)
|
||||
return 1
|
||||
if(istype(A,/obj/mecha))
|
||||
A.add_fingerprint(H)
|
||||
drain("MECHA",A,suit)
|
||||
return 1
|
||||
|
||||
// download research
|
||||
if(istype(A,/obj/machinery/computer/rdconsole))
|
||||
A.add_fingerprint(H)
|
||||
drain("RESEARCH",A,suit)
|
||||
return 1
|
||||
if(istype(A,/obj/machinery/r_n_d/server))
|
||||
A.add_fingerprint(H)
|
||||
var/obj/machinery/r_n_d/server/S = A
|
||||
if(S.disabled)
|
||||
return 1
|
||||
if(S.shocked)
|
||||
S.shock(H,50)
|
||||
return 1
|
||||
drain("RESEARCH",A,suit)
|
||||
return 1
|
||||
|
||||
@@ -4,38 +4,13 @@
|
||||
icon_state = "hardhat0_yellow"
|
||||
flags = FPRINT | TABLEPASS
|
||||
item_state = "hardhat0_yellow"
|
||||
var/brightness_on = 4 //luminosity when on
|
||||
var/on = 0
|
||||
brightness_on = 4 //luminosity when on
|
||||
light_overlay = "hardhat_light"
|
||||
item_color = "yellow" //Determines used sprites: hardhat[on]_[color] and hardhat[on]_[color]2 (lying down sprite)
|
||||
armor = list(melee = 30, bullet = 5, laser = 20,energy = 10, bomb = 20, bio = 10, rad = 20)
|
||||
flags_inv = 0
|
||||
icon_action_button = "action_hardhat"
|
||||
siemens_coefficient = 0.9
|
||||
|
||||
attack_self(mob/user)
|
||||
if(!isturf(user.loc))
|
||||
user << "You cannot turn the light on while in this [user.loc]" //To prevent some lighting anomalities.
|
||||
return
|
||||
on = !on
|
||||
icon_state = "hardhat[on]_[item_color]"
|
||||
item_state = "hardhat[on]_[item_color]"
|
||||
|
||||
if(on) user.SetLuminosity(user.luminosity + brightness_on)
|
||||
else user.SetLuminosity(user.luminosity - brightness_on)
|
||||
|
||||
pickup(mob/user)
|
||||
if(on)
|
||||
user.SetLuminosity(user.luminosity + brightness_on)
|
||||
// user.UpdateLuminosity() //TODO: Carn
|
||||
SetLuminosity(0)
|
||||
|
||||
dropped(mob/user)
|
||||
if(on)
|
||||
user.SetLuminosity(user.luminosity - brightness_on)
|
||||
// user.UpdateLuminosity()
|
||||
SetLuminosity(brightness_on)
|
||||
|
||||
|
||||
/obj/item/clothing/head/hardhat/orange
|
||||
icon_state = "hardhat0_orange"
|
||||
item_state = "hardhat0_orange"
|
||||
@@ -61,5 +36,4 @@
|
||||
/obj/item/clothing/head/hardhat/dblue
|
||||
icon_state = "hardhat0_dblue"
|
||||
item_state = "hardhat0_dblue"
|
||||
item_color = "dblue"
|
||||
|
||||
item_color = "dblue"
|
||||
@@ -82,7 +82,11 @@
|
||||
icon_state = "swathelm"
|
||||
item_state = "helmet"
|
||||
flags = FPRINT|TABLEPASS|HEADCOVERSEYES
|
||||
|
||||
sprite_sheets = list(
|
||||
"Tajara" = 'icons/mob/species/tajaran/helmet.dmi',
|
||||
"Unathi" = 'icons/mob/species/unathi/helmet.dmi',
|
||||
)
|
||||
|
||||
armor = list(melee = 62, bullet = 50, laser = 50,energy = 35, bomb = 10, bio = 2, rad = 0)
|
||||
flags_inv = HIDEEARS
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
desc = "Smells nice."
|
||||
item_state = "hairflower"
|
||||
flags = FPRINT|TABLEPASS
|
||||
slot_flags = SLOT_HEAD | SLOT_EARS
|
||||
body_parts_covered = 0
|
||||
|
||||
/obj/item/clothing/head/powdered_wig
|
||||
@@ -74,7 +75,7 @@
|
||||
name = "red space-helmet replica"
|
||||
icon_state = "syndicate"
|
||||
item_state = "syndicate"
|
||||
desc = "A plastic replica of a syndicate agent's space helmet, you'll look just like a real murderous syndicate agent in this! This is a toy, it is not made for use in space!"
|
||||
desc = "A plastic replica of a bloodthirsty mercenary's space helmet, you'll look just like a real murderous criminal operative in this! This is a toy, it is not made for use in space!"
|
||||
flags = FPRINT | TABLEPASS | BLOCKHAIR
|
||||
flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE
|
||||
siemens_coefficient = 2.0
|
||||
@@ -233,7 +234,7 @@
|
||||
icon_state = "chickenhead"
|
||||
item_state = "chickensuit"
|
||||
flags = FPRINT | TABLEPASS | BLOCKHAIR
|
||||
siemens_coefficient = 2.0
|
||||
siemens_coefficient = 0.7
|
||||
body_parts_covered = HEAD|FACE|EYES
|
||||
|
||||
/obj/item/clothing/head/bearpelt
|
||||
@@ -242,7 +243,7 @@
|
||||
icon_state = "bearpelt"
|
||||
item_state = "bearpelt"
|
||||
flags = FPRINT | TABLEPASS | BLOCKHAIR
|
||||
siemens_coefficient = 2.0
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
/obj/item/clothing/head/xenos
|
||||
name = "xenos helmet"
|
||||
@@ -253,3 +254,19 @@
|
||||
flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE
|
||||
siemens_coefficient = 2.0
|
||||
body_parts_covered = HEAD|FACE|EYES
|
||||
|
||||
/obj/item/clothing/head/philosopher_wig
|
||||
name = "natural philosopher's wig"
|
||||
desc = "A stylish monstrosity unearthed from Earth's Renaissance period. With this most distinguish'd wig, you'll be ready for your next soiree!"
|
||||
icon_state = "philosopher_wig"
|
||||
item_state = "philosopher_wig"
|
||||
flags = FPRINT | TABLEPASS | BLOCKHAIR
|
||||
siemens_coefficient = 2.0 //why is it so conductive?!
|
||||
body_parts_covered = 0
|
||||
|
||||
/obj/item/clothing/head/orangebandana //themij: Taryn Kifer
|
||||
name = "orange bandana"
|
||||
desc = "An orange piece of cloth, worn on the head."
|
||||
icon_state = "orange_bandana"
|
||||
item_state = "orange_bandana"
|
||||
body_parts_covered = 0
|
||||
|
||||
@@ -126,33 +126,10 @@
|
||||
flags = FPRINT | TABLEPASS | HEADCOVERSEYES | HEADCOVERSMOUTH | BLOCKHAIR
|
||||
flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE
|
||||
body_parts_covered = HEAD|EYES
|
||||
var/brightness_on = 2 //luminosity when on
|
||||
var/on = 0
|
||||
brightness_on = 2
|
||||
light_overlay = "helmet_light"
|
||||
w_class = 3
|
||||
|
||||
attack_self(mob/user)
|
||||
if(!isturf(user.loc))
|
||||
user << "You cannot turn the light on while in this [user.loc]" //To prevent some lighting anomalities.
|
||||
return
|
||||
on = !on
|
||||
icon_state = "hardhat[on]_[item_color]"
|
||||
item_state = "hardhat[on]_[item_color]"
|
||||
|
||||
if(on) user.SetLuminosity(user.luminosity + brightness_on)
|
||||
else user.SetLuminosity(user.luminosity - brightness_on)
|
||||
|
||||
pickup(mob/user)
|
||||
if(on)
|
||||
user.SetLuminosity(user.luminosity + brightness_on)
|
||||
// user.UpdateLuminosity()
|
||||
SetLuminosity(0)
|
||||
|
||||
dropped(mob/user)
|
||||
if(on)
|
||||
user.SetLuminosity(user.luminosity - brightness_on)
|
||||
// user.UpdateLuminosity()
|
||||
SetLuminosity(brightness_on)
|
||||
|
||||
/*
|
||||
* Kitty ears
|
||||
*/
|
||||
|
||||
@@ -7,6 +7,10 @@
|
||||
flags_inv = HIDEFACE
|
||||
body_parts_covered = FACE
|
||||
w_class = 2
|
||||
sprite_sheets = list(
|
||||
"Tajara" = 'icons/mob/species/tajaran/helmet.dmi',
|
||||
"Unathi" = 'icons/mob/species/unathi/helmet.dmi',
|
||||
)
|
||||
|
||||
/obj/item/clothing/mask/balaclava/tactical
|
||||
name = "green balaclava"
|
||||
@@ -16,6 +20,10 @@
|
||||
flags = FPRINT|TABLEPASS|BLOCKHAIR
|
||||
flags_inv = HIDEFACE
|
||||
w_class = 2
|
||||
sprite_sheets = list(
|
||||
"Tajara" = 'icons/mob/species/tajaran/helmet.dmi',
|
||||
"Unathi" = 'icons/mob/species/unathi/helmet.dmi',
|
||||
)
|
||||
|
||||
/obj/item/clothing/mask/luchador
|
||||
name = "Luchador Mask"
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
name = "breath mask"
|
||||
icon_state = "breath"
|
||||
item_state = "breath"
|
||||
flags = FPRINT | TABLEPASS | MASKCOVERSMOUTH | MASKINTERNALS
|
||||
flags = FPRINT | TABLEPASS | MASKCOVERSMOUTH | AIRTIGHT
|
||||
body_parts_covered = 0
|
||||
w_class = 2
|
||||
gas_transfer_coefficient = 0.10
|
||||
@@ -24,14 +24,14 @@
|
||||
if(!src.hanging)
|
||||
src.hanging = !src.hanging
|
||||
gas_transfer_coefficient = 1 //gas is now escaping to the turf and vice versa
|
||||
flags &= ~(MASKCOVERSMOUTH | MASKINTERNALS)
|
||||
flags &= ~(MASKCOVERSMOUTH | AIRTIGHT)
|
||||
icon_state = "breathdown"
|
||||
usr << "Your mask is now hanging on your neck."
|
||||
|
||||
else
|
||||
src.hanging = !src.hanging
|
||||
gas_transfer_coefficient = 0.10
|
||||
flags |= MASKCOVERSMOUTH | MASKINTERNALS
|
||||
flags |= MASKCOVERSMOUTH | AIRTIGHT
|
||||
icon_state = "breath"
|
||||
usr << "You pull the mask up to cover your face."
|
||||
update_clothing_icon()
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
name = "gas mask"
|
||||
desc = "A face-covering mask that can be connected to an air supply. Filters harmful gases from the air."
|
||||
icon_state = "gas_alt"
|
||||
flags = FPRINT | TABLEPASS | MASKCOVERSMOUTH | MASKCOVERSEYES | BLOCK_GAS_SMOKE_EFFECT | MASKINTERNALS
|
||||
flags = FPRINT | TABLEPASS | MASKCOVERSMOUTH | MASKCOVERSEYES | BLOCK_GAS_SMOKE_EFFECT | AIRTIGHT
|
||||
flags_inv = HIDEEARS|HIDEEYES|HIDEFACE
|
||||
body_parts_covered = FACE|EYES
|
||||
w_class = 3.0
|
||||
@@ -43,27 +43,11 @@
|
||||
body_parts_covered = FACE|EYES
|
||||
|
||||
/obj/item/clothing/mask/gas/syndicate
|
||||
name = "syndicate mask"
|
||||
name = "tactical mask"
|
||||
desc = "A close-fitting tactical mask that can be connected to an air supply."
|
||||
icon_state = "swat"
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
/obj/item/clothing/mask/gas/voice
|
||||
name = "gas mask"
|
||||
//desc = "A face-covering mask that can be connected to an air supply. It seems to house some odd electronics."
|
||||
var/mode = 0// 0==Scouter | 1==Night Vision | 2==Thermal | 3==Meson
|
||||
var/voice = "Unknown"
|
||||
var/vchange = 0//This didn't do anything before. It now checks if the mask has special functions/N
|
||||
origin_tech = "syndicate=4"
|
||||
|
||||
/obj/item/clothing/mask/gas/voice/space_ninja
|
||||
name = "ninja mask"
|
||||
desc = "A close-fitting mask that acts both as an air filter and a post-modern fashion statement."
|
||||
icon_state = "s-ninja"
|
||||
item_state = "s-ninja_mask"
|
||||
vchange = 1
|
||||
siemens_coefficient = 0.2
|
||||
|
||||
/obj/item/clothing/mask/gas/clown_hat
|
||||
name = "clown wig and mask"
|
||||
desc = "A true prankster's facial attire. A clown is incomplete without his wig and mask."
|
||||
|
||||
@@ -8,14 +8,11 @@
|
||||
w_class = 2
|
||||
gas_transfer_coefficient = 0.90
|
||||
|
||||
//Monkeys can not take the muzzle off of themself! Call PETA!
|
||||
/obj/item/clothing/mask/muzzle/attack_paw(mob/user as mob)
|
||||
if (src == user.wear_mask)
|
||||
return
|
||||
else
|
||||
..()
|
||||
return
|
||||
|
||||
// Clumsy folks can't take the mask off themselves.
|
||||
/obj/item/clothing/mask/muzzle/attack_hand(mob/user as mob)
|
||||
if(user.wear_mask == src && !user.IsAdvancedToolUser())
|
||||
return 0
|
||||
..()
|
||||
|
||||
/obj/item/clothing/mask/surgical
|
||||
name = "sterile mask"
|
||||
|
||||
31
code/modules/clothing/masks/voice.dm
Normal file
31
code/modules/clothing/masks/voice.dm
Normal file
@@ -0,0 +1,31 @@
|
||||
/obj/item/voice_changer
|
||||
name = "voice changer"
|
||||
desc = "A voice scrambling module. If you can see this, report it as a bug on the tracker."
|
||||
var/voice //If set and item is present in mask/suit, this name will be used for the wearer's speech.
|
||||
var/active
|
||||
|
||||
/obj/item/clothing/mask/gas/voice
|
||||
name = "gas mask"
|
||||
desc = "A face-covering mask that can be connected to an air supply. It seems to house some odd electronics."
|
||||
var/obj/item/voice_changer/changer
|
||||
origin_tech = "syndicate=4"
|
||||
|
||||
/obj/item/clothing/mask/gas/voice/verb/Toggle_Voice_Changer()
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
changer.active = !changer.active
|
||||
usr << "<span class='notice'>You [changer.active ? "enable" : "disable"] the voice-changing module in \the [src].</span>"
|
||||
|
||||
/obj/item/clothing/mask/gas/voice/verb/Set_Voice(name as text)
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
var/voice = sanitize(copytext(name,1,MAX_MESSAGE_LEN))
|
||||
if(!voice || !length(voice)) return
|
||||
changer.voice = voice
|
||||
usr << "<span class='notice'>You are now mimicking <B>[changer.voice]</B>.</span>"
|
||||
|
||||
/obj/item/clothing/mask/gas/voice/New()
|
||||
..()
|
||||
changer = new(src)
|
||||
@@ -3,30 +3,32 @@
|
||||
name = "magboots"
|
||||
icon_state = "magboots0"
|
||||
species_restricted = null
|
||||
force = 3
|
||||
var/magpulse = 0
|
||||
var/icon_base = "magboots"
|
||||
icon_action_button = "action_blank"
|
||||
action_button_name = "Toggle the magboots"
|
||||
// flags = NOSLIP //disabled by default
|
||||
|
||||
attack_self(mob/user)
|
||||
if(magpulse)
|
||||
flags &= ~NOSLIP
|
||||
slowdown = SHOES_SLOWDOWN
|
||||
magpulse = 0
|
||||
icon_state = "magboots0"
|
||||
user << "You disable the mag-pulse traction system."
|
||||
else
|
||||
flags |= NOSLIP
|
||||
slowdown = 2
|
||||
magpulse = 1
|
||||
icon_state = "magboots1"
|
||||
user << "You enable the mag-pulse traction system."
|
||||
user.update_inv_shoes() //so our mob-overlays update
|
||||
|
||||
examine()
|
||||
set src in view()
|
||||
..()
|
||||
var/state = "disabled"
|
||||
if(src.flags&NOSLIP)
|
||||
state = "enabled"
|
||||
usr << "Its mag-pulse traction system appears to be [state]."
|
||||
/obj/item/clothing/shoes/magboots/attack_self(mob/user)
|
||||
if(magpulse)
|
||||
flags &= ~NOSLIP
|
||||
slowdown = SHOES_SLOWDOWN
|
||||
magpulse = 0
|
||||
force = 3
|
||||
if(icon_base) icon_state = "[icon_base]0"
|
||||
user << "You disable the mag-pulse traction system."
|
||||
else
|
||||
flags |= NOSLIP
|
||||
slowdown = 2
|
||||
magpulse = 1
|
||||
force = 5
|
||||
if(icon_base) icon_state = "[icon_base]1"
|
||||
user << "You enable the mag-pulse traction system."
|
||||
user.update_inv_shoes() //so our mob-overlays update
|
||||
|
||||
/obj/item/clothing/shoes/magboots/examine(mob/user)
|
||||
..(user)
|
||||
var/state = "disabled"
|
||||
if(src.flags&NOSLIP)
|
||||
state = "enabled"
|
||||
user << "Its mag-pulse traction system appears to be [state]."
|
||||
@@ -19,6 +19,7 @@
|
||||
name = "\improper SWAT shoes"
|
||||
desc = "When you want to turn up the heat."
|
||||
icon_state = "swat"
|
||||
force = 3
|
||||
armor = list(melee = 80, bullet = 60, laser = 50,energy = 25, bomb = 50, bio = 10, rad = 0)
|
||||
flags = NOSLIP
|
||||
siemens_coefficient = 0.6
|
||||
@@ -27,6 +28,7 @@
|
||||
name = "combat boots"
|
||||
desc = "When you REALLY want to turn up the heat"
|
||||
icon_state = "swat"
|
||||
force = 5
|
||||
armor = list(melee = 80, bullet = 60, laser = 50,energy = 25, bomb = 50, bio = 10, rad = 0)
|
||||
flags = NOSLIP
|
||||
siemens_coefficient = 0.6
|
||||
@@ -36,21 +38,6 @@
|
||||
heat_protection = FEET
|
||||
max_heat_protection_temperature = SHOE_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
|
||||
/obj/item/clothing/shoes/space_ninja
|
||||
name = "ninja shoes"
|
||||
desc = "A pair of running shoes. Excellent for running and even better for smashing skulls."
|
||||
icon_state = "s-ninja"
|
||||
permeability_coefficient = 0.01
|
||||
flags = NOSLIP
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
|
||||
siemens_coefficient = 0.2
|
||||
|
||||
cold_protection = FEET
|
||||
min_cold_protection_temperature = SHOE_MIN_COLD_PROTECTION_TEMPERATURE
|
||||
heat_protection = FEET
|
||||
max_heat_protection_temperature = SHOE_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
species_restricted = null
|
||||
|
||||
/obj/item/clothing/shoes/sandal
|
||||
desc = "A pair of rather plain, wooden sandals."
|
||||
name = "sandals"
|
||||
@@ -80,6 +67,7 @@
|
||||
item_state = "clown_shoes"
|
||||
slowdown = SHOES_SLOWDOWN+1
|
||||
item_color = "clown"
|
||||
force = 0
|
||||
var/footstep = 1 //used for squeeks whilst walking
|
||||
species_restricted = null
|
||||
|
||||
@@ -89,6 +77,7 @@
|
||||
icon_state = "jackboots"
|
||||
item_state = "jackboots"
|
||||
item_color = "hosred"
|
||||
force = 3
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
/obj/item/clothing/shoes/cult
|
||||
@@ -97,6 +86,7 @@
|
||||
icon_state = "cult"
|
||||
item_state = "cult"
|
||||
item_color = "cult"
|
||||
force = 2
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
cold_protection = FEET
|
||||
@@ -115,6 +105,7 @@
|
||||
desc = "Fluffy!"
|
||||
icon_state = "slippers"
|
||||
item_state = "slippers"
|
||||
force = 0
|
||||
species_restricted = null
|
||||
w_class = 2
|
||||
|
||||
@@ -123,6 +114,7 @@
|
||||
desc = "Fluffy..."
|
||||
icon_state = "slippers_worn"
|
||||
item_state = "slippers_worn"
|
||||
force = 0
|
||||
w_class = 2
|
||||
|
||||
/obj/item/clothing/shoes/laceup
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
item_color = "skrell_helmet_black"
|
||||
|
||||
/obj/item/clothing/suit/space/skrell
|
||||
name = "Skrellian hardsuit"
|
||||
name = "Skrellian voidsuit"
|
||||
desc = "Seems like a wetsuit with reinforced plating seamlessly attached to it. Very chic."
|
||||
armor = list(melee = 20, bullet = 20, laser = 50,energy = 50, bomb = 50, bio = 100, rad = 100)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/weapon/storage/bag/ore,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/weapon/rcd)
|
||||
@@ -35,50 +35,6 @@
|
||||
item_state = "skrell_suit_black"
|
||||
item_color = "skrell_suit_black"
|
||||
|
||||
//Unathi space gear. Huge and restrictive.
|
||||
/obj/item/clothing/head/helmet/space/unathi
|
||||
armor = list(melee = 40, bullet = 30, laser = 30,energy = 15, bomb = 35, bio = 100, rad = 50)
|
||||
heat_protection = HEAD
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
var/up = 0 //So Unathi helmets play nicely with the weldervision check.
|
||||
species_restricted = list("Unathi")
|
||||
|
||||
/obj/item/clothing/head/helmet/space/unathi/helmet_cheap
|
||||
name = "NT breacher helmet"
|
||||
desc = "Hey! Watch it with that thing! It's a knock-off of a Unathi battle-helm, and that spike could put someone's eye out."
|
||||
icon_state = "unathi_helm_cheap"
|
||||
item_state = "unathi_helm_cheap"
|
||||
item_color = "unathi_helm_cheap"
|
||||
|
||||
/obj/item/clothing/suit/space/unathi
|
||||
armor = list(melee = 40, bullet = 30, laser = 30,energy = 15, bomb = 35, bio = 100, rad = 50)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/weapon/storage/bag/ore,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/weapon/rcd)
|
||||
heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
species_restricted = list("Unathi")
|
||||
|
||||
/obj/item/clothing/suit/space/unathi/rig_cheap
|
||||
name = "NT breacher chassis"
|
||||
desc = "A cheap NT knock-off of a Unathi battle-rig. Looks like a fish, moves like a fish, steers like a cow."
|
||||
icon_state = "rig-unathi-cheap"
|
||||
item_state = "rig-unathi-cheap"
|
||||
slowdown = 3
|
||||
|
||||
/obj/item/clothing/head/helmet/space/unathi/breacher
|
||||
name = "breacher helm"
|
||||
desc = "Weathered, ancient and battle-scarred. The helmet is too."
|
||||
icon_state = "unathi_breacher"
|
||||
item_state = "unathi_breacher"
|
||||
item_color = "unathi_breacher"
|
||||
|
||||
/obj/item/clothing/suit/space/unathi/breacher
|
||||
name = "breacher chassis"
|
||||
desc = "Huge, bulky and absurdly heavy. It must be like wearing a tank."
|
||||
icon_state = "unathi_breacher"
|
||||
item_state = "unathi_breacher"
|
||||
item_color = "unathi_breacher"
|
||||
slowdown = 1
|
||||
|
||||
// Vox space gear (vaccuum suit, low pressure armour)
|
||||
// Can't be equipped by any other species due to bone structure and vox cybernetics.
|
||||
/obj/item/clothing/suit/space/vox
|
||||
@@ -231,8 +187,7 @@
|
||||
magpulse = 0
|
||||
canremove = 1
|
||||
|
||||
/obj/item/clothing/shoes/magboots/vox/examine()
|
||||
set src in view()
|
||||
..()
|
||||
/obj/item/clothing/shoes/magboots/vox/examine(mob/user)
|
||||
..(user)
|
||||
if (magpulse)
|
||||
usr << "It would be hard to take these off without relaxing your grip first." //theoretically this message should only be seen by the wearer when the claws are equipped.
|
||||
user << "It would be hard to take these off without relaxing your grip first." //theoretically this message should only be seen by the wearer when the claws are equipped.
|
||||
|
||||
@@ -214,8 +214,8 @@ var/global/list/breach_burn_descriptors = list(
|
||||
|
||||
..()
|
||||
|
||||
/obj/item/clothing/suit/space/examine()
|
||||
..()
|
||||
/obj/item/clothing/suit/space/examine(mob/user)
|
||||
..(user)
|
||||
if(can_breach && breaches && breaches.len)
|
||||
for(var/datum/breach/B in breaches)
|
||||
usr << "\red <B>It has \a [B.descriptor].</B>"
|
||||
user << "\red <B>It has \a [B.descriptor].</B>"
|
||||
|
||||
@@ -1,90 +0,0 @@
|
||||
/obj/item/clothing/head/helmet/space/rig/ert
|
||||
name = "emergency response team helmet"
|
||||
desc = "A helmet worn by members of the NanoTrasen Emergency Response Team. Armoured and space ready."
|
||||
icon_state = "rig0-ert_commander"
|
||||
item_state = "helm-command"
|
||||
armor = list(melee = 50, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 100, rad = 60)
|
||||
siemens_coefficient = 0.6
|
||||
var/obj/machinery/camera/camera
|
||||
|
||||
/obj/item/clothing/head/helmet/space/rig/ert/attack_self(mob/user)
|
||||
if(camera)
|
||||
..(user)
|
||||
else
|
||||
camera = new /obj/machinery/camera(src)
|
||||
camera.network = list("ERT")
|
||||
cameranet.removeCamera(camera)
|
||||
camera.c_tag = user.name
|
||||
user << "\blue User scanned as [camera.c_tag]. Camera activated."
|
||||
|
||||
/obj/item/clothing/head/helmet/space/rig/ert/examine()
|
||||
..()
|
||||
if(get_dist(usr,src) <= 1)
|
||||
usr << "This helmet has a built-in camera. It's [camera ? "" : "in"]active."
|
||||
|
||||
/obj/item/clothing/suit/space/rig/ert
|
||||
name = "emergency response team suit"
|
||||
desc = "A suit worn by members of the NanoTrasen Emergency Response Team. Armoured, space ready, and fire resistant."
|
||||
icon_state = "ert_commander"
|
||||
item_state = "suit-command"
|
||||
w_class = 3
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/melee/energy/sword,/obj/item/weapon/handcuffs,/obj/item/weapon/tank/emergency_oxygen)
|
||||
slowdown = 1
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 100, rad = 100)
|
||||
allowed = list(/obj/item/device/flashlight, /obj/item/weapon/tank, /obj/item/device/t_scanner, /obj/item/weapon/rcd, /obj/item/weapon/crowbar, \
|
||||
/obj/item/weapon/screwdriver, /obj/item/weapon/weldingtool, /obj/item/weapon/wirecutters, /obj/item/weapon/wrench, /obj/item/device/multitool, \
|
||||
/obj/item/device/radio, /obj/item/device/analyzer, /obj/item/weapon/gun/energy/laser, /obj/item/weapon/gun/energy/pulse_rifle, \
|
||||
/obj/item/weapon/gun/energy/taser, /obj/item/weapon/melee/baton, /obj/item/weapon/gun/energy/gun)
|
||||
siemens_coefficient = 0.6
|
||||
|
||||
//Commander
|
||||
/obj/item/clothing/head/helmet/space/rig/ert/commander
|
||||
name = "emergency response team commander helmet"
|
||||
desc = "A helmet worn by the commander of a NanoTrasen Emergency Response Team. Has blue highlights. Armoured and space ready."
|
||||
icon_state = "rig0-ert_commander"
|
||||
item_state = "helm-command"
|
||||
item_color = "ert_commander"
|
||||
|
||||
/obj/item/clothing/suit/space/rig/ert/commander
|
||||
name = "emergency response team commander suit"
|
||||
desc = "A suit worn by the commander of a NanoTrasen Emergency Response Team. Has blue highlights. Armoured, space ready, and fire resistant."
|
||||
icon_state = "ert_commander"
|
||||
item_state = "suit-command"
|
||||
|
||||
//Security
|
||||
/obj/item/clothing/head/helmet/space/rig/ert/security
|
||||
name = "emergency response team security helmet"
|
||||
desc = "A helmet worn by security members of a NanoTrasen Emergency Response Team. Has red highlights. Armoured and space ready."
|
||||
icon_state = "rig0-ert_security"
|
||||
item_state = "syndicate-helm-black-red"
|
||||
item_color = "ert_security"
|
||||
|
||||
/obj/item/clothing/suit/space/rig/ert/security
|
||||
name = "emergency response team security suit"
|
||||
desc = "A suit worn by security members of a NanoTrasen Emergency Response Team. Has red highlights. Armoured, space ready, and fire resistant."
|
||||
icon_state = "ert_security"
|
||||
item_state = "syndicate-black-red"
|
||||
|
||||
//Engineer
|
||||
/obj/item/clothing/head/helmet/space/rig/ert/engineer
|
||||
name = "emergency response team engineer helmet"
|
||||
desc = "A helmet worn by engineering members of a NanoTrasen Emergency Response Team. Has orange highlights. Armoured and space ready."
|
||||
icon_state = "rig0-ert_engineer"
|
||||
item_color = "ert_engineer"
|
||||
|
||||
/obj/item/clothing/suit/space/rig/ert/engineer
|
||||
name = "emergency response team engineer suit"
|
||||
desc = "A suit worn by the engineering of a NanoTrasen Emergency Response Team. Has orange highlights. Armoured, space ready, and fire resistant."
|
||||
icon_state = "ert_engineer"
|
||||
|
||||
//Medical
|
||||
/obj/item/clothing/head/helmet/space/rig/ert/medical
|
||||
name = "emergency response team medical helmet"
|
||||
desc = "A helmet worn by medical members of a NanoTrasen Emergency Response Team. Has white highlights. Armoured and space ready."
|
||||
icon_state = "rig0-ert_medical"
|
||||
item_color = "ert_medical"
|
||||
|
||||
/obj/item/clothing/suit/space/rig/ert/medical
|
||||
name = "emergency response team medical suit"
|
||||
desc = "A suit worn by medical members of a NanoTrasen Emergency Response Team. Has white highlights. Armoured and space ready."
|
||||
icon_state = "ert_medical"
|
||||
@@ -1,71 +0,0 @@
|
||||
/obj/item/clothing/head/helmet/space/space_ninja
|
||||
desc = "What may appear to be a simple black garment is in fact a highly sophisticated nano-weave helmet. Standard issue ninja gear."
|
||||
name = "ninja hood"
|
||||
icon_state = "s-ninja"
|
||||
item_state = "s-ninja_mask"
|
||||
allowed = list(/obj/item/weapon/cell)
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 25)
|
||||
siemens_coefficient = 0.2
|
||||
species_restricted = null
|
||||
body_parts_covered = HEAD|FACE
|
||||
flags_inv = HIDEEARS|HIDEEYES|HIDEFACE
|
||||
|
||||
/obj/item/clothing/suit/space/space_ninja
|
||||
name = "ninja suit"
|
||||
desc = "A unique, vaccum-proof suit of nano-enhanced armor designed specifically for Spider Clan assassins."
|
||||
icon_state = "s-ninja"
|
||||
item_state = "s-ninja_suit"
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/handcuffs,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/cell)
|
||||
slowdown = 0
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
|
||||
siemens_coefficient = 0.2
|
||||
species_restricted = null //Workaround for spawning alien ninja without internals.
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
|
||||
flags_inv = HIDEJUMPSUIT|HIDETAIL
|
||||
supporting_limbs = list()
|
||||
|
||||
// Hardsuit breaching data
|
||||
breach_threshold = 30 //A suit breach is a major issue for ninjas. This should maybe help.
|
||||
can_breach = 1
|
||||
|
||||
//Important parts of the suit.
|
||||
var/mob/living/carbon/affecting = null//The wearer.
|
||||
var/obj/item/weapon/cell/cell//Starts out with a high-capacity cell using New().
|
||||
var/datum/effect/effect/system/spark_spread/spark_system//To create sparks.
|
||||
var/reagent_list[] = list("tricordrazine","tramadol","dexalinp","spaceacillin","anti_toxin","nutriment","radium","hyronalin")//The reagents ids which are added to the suit at New().
|
||||
var/stored_research[]//For stealing station research.
|
||||
var/obj/item/weapon/disk/tech_disk/t_disk//To copy design onto disk.
|
||||
|
||||
//Other articles of ninja gear worn together, used to easily reference them after initializing.
|
||||
var/obj/item/clothing/head/helmet/space/space_ninja/n_hood
|
||||
var/obj/item/clothing/shoes/space_ninja/n_shoes
|
||||
var/obj/item/clothing/gloves/space_ninja/n_gloves
|
||||
|
||||
//Main function variables.
|
||||
var/s_initialized = 0//Suit starts off.
|
||||
var/s_coold = 0//If the suit is on cooldown. Can be used to attach different cooldowns to abilities. Ticks down every second based on suit ntick().
|
||||
var/s_cost = 5.0//Base energy cost each ntick.
|
||||
var/s_acost = 25.0//Additional cost for additional powers active.
|
||||
var/k_cost = 200.0//Kamikaze energy cost each ntick.
|
||||
var/k_damage = 1.0//Brute damage potentially done by Kamikaze each ntick.
|
||||
var/s_delay = 40.0//How fast the suit does certain things, lower is faster. Can be overridden in specific procs. Also determines adverse probability.
|
||||
var/a_transfer = 20.0//How much reagent is transferred when injecting.
|
||||
var/r_maxamount = 80.0//How much reagent in total there is.
|
||||
|
||||
//Support function variables.
|
||||
var/spideros = 0//Mode of SpiderOS. This can change so I won't bother listing the modes here (0 is hub). Check ninja_equipment.dm for how it all works.
|
||||
var/s_active = 0//Stealth off.
|
||||
var/s_busy = 0//Is the suit busy with a process? Like AI hacking. Used for safety functions.
|
||||
var/kamikaze = 0//Kamikaze on or off.
|
||||
var/k_unlock = 0//To unlock Kamikaze.
|
||||
|
||||
//Ability function variables.
|
||||
var/s_bombs = 10.0//Number of starting ninja smoke bombs.
|
||||
var/a_boost = 3.0//Number of adrenaline boosters.
|
||||
|
||||
//Onboard AI related variables.
|
||||
var/mob/living/silicon/ai/AI//If there is an AI inside the suit.
|
||||
var/obj/item/device/paicard/pai//A slot for a pAI device
|
||||
var/obj/effect/overlay/hologram//Is the AI hologram on or off? Visible only to the wearer of the suit. This works by attaching an image to a blank overlay.
|
||||
var/flush = 0//If an AI purge is in progress.
|
||||
var/s_control = 1//If user in control of the suit.
|
||||
@@ -1,478 +0,0 @@
|
||||
//Regular rig suits
|
||||
/obj/item/clothing/head/helmet/space/rig
|
||||
name = "hardsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low-pressure environment."
|
||||
icon_state = "rig0-engineering"
|
||||
item_state = "eng_helm"
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 20)
|
||||
allowed = list(/obj/item/device/flashlight)
|
||||
var/brightness_on = 4 //luminosity when on
|
||||
var/on = 0
|
||||
item_color = "engineering" //Determines used sprites: rig[on]-[color] and rig[on]-[color]2 (lying down sprite)
|
||||
icon_action_button = "action_hardhat"
|
||||
heat_protection = HEAD
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
|
||||
//Species-specific stuff.
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Diona","Vox")
|
||||
sprite_sheets_refit = list(
|
||||
"Unathi" = 'icons/mob/species/unathi/helmet.dmi',
|
||||
"Tajara" = 'icons/mob/species/tajaran/helmet.dmi',
|
||||
"Skrell" = 'icons/mob/species/skrell/helmet.dmi',
|
||||
)
|
||||
sprite_sheets_obj = list(
|
||||
"Unathi" = 'icons/obj/clothing/species/unathi/hats.dmi',
|
||||
"Tajara" = 'icons/obj/clothing/species/tajaran/hats.dmi',
|
||||
"Skrell" = 'icons/obj/clothing/species/skrell/hats.dmi',
|
||||
)
|
||||
|
||||
attack_self(mob/user)
|
||||
if(!isturf(user.loc))
|
||||
user << "You cannot turn the light on while in this [user.loc]" //To prevent some lighting anomalities.
|
||||
return
|
||||
on = !on
|
||||
icon_state = "rig[on]-[item_color]"
|
||||
// item_state = "rig[on]-[color]"
|
||||
|
||||
if(on) user.SetLuminosity(user.luminosity + brightness_on)
|
||||
else user.SetLuminosity(user.luminosity - brightness_on)
|
||||
|
||||
if(istype(user,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.update_inv_head()
|
||||
|
||||
pickup(mob/user)
|
||||
if(on)
|
||||
user.SetLuminosity(user.luminosity + brightness_on)
|
||||
// user.UpdateLuminosity()
|
||||
SetLuminosity(0)
|
||||
|
||||
dropped(mob/user)
|
||||
if(on)
|
||||
user.SetLuminosity(user.luminosity - brightness_on)
|
||||
// user.UpdateLuminosity()
|
||||
SetLuminosity(brightness_on)
|
||||
|
||||
/obj/item/clothing/suit/space/rig
|
||||
name = "hardsuit"
|
||||
desc = "A special space suit for environments that might pose hazards beyond just the vacuum of space. Provides more protection than a standard space suit."
|
||||
icon_state = "rig-engineering"
|
||||
item_state = "eng_hardsuit"
|
||||
slowdown = 1
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 20)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit)
|
||||
heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox")
|
||||
sprite_sheets_refit = list(
|
||||
"Unathi" = 'icons/mob/species/unathi/suit.dmi',
|
||||
"Tajara" = 'icons/mob/species/tajaran/suit.dmi',
|
||||
"Skrell" = 'icons/mob/species/skrell/suit.dmi',
|
||||
)
|
||||
sprite_sheets_obj = list(
|
||||
"Unathi" = 'icons/obj/clothing/species/unathi/suits.dmi',
|
||||
"Tajara" = 'icons/obj/clothing/species/tajaran/suits.dmi',
|
||||
"Skrell" = 'icons/obj/clothing/species/skrell/suits.dmi',
|
||||
)
|
||||
|
||||
//Breach thresholds, should ideally be inherited by most (if not all) hardsuits.
|
||||
breach_threshold = 18
|
||||
can_breach = 1
|
||||
|
||||
//Component/device holders.
|
||||
var/obj/item/weapon/stock_parts/gloves = null // Basic capacitor allows insulation, upgrades allow shock gloves etc.
|
||||
|
||||
var/attached_boots = 1 // Can't wear boots if some are attached
|
||||
var/obj/item/clothing/shoes/magboots/boots = null // Deployable boots, if any.
|
||||
var/attached_helmet = 1 // Can't wear a helmet if one is deployable.
|
||||
var/obj/item/clothing/head/helmet/helmet = null // Deployable helmet, if any.
|
||||
|
||||
var/list/max_mounted_devices = 0 // Maximum devices. Easy.
|
||||
var/list/can_mount = null // Types of device that can be hardpoint mounted.
|
||||
var/list/mounted_devices = null // Holder for the above device.
|
||||
var/obj/item/active_device = null // Currently deployed device, if any.
|
||||
|
||||
/obj/item/clothing/suit/space/rig/equipped(mob/M)
|
||||
..()
|
||||
|
||||
var/mob/living/carbon/human/H = M
|
||||
|
||||
if(!istype(H)) return
|
||||
|
||||
if(H.wear_suit != src)
|
||||
return
|
||||
|
||||
if(attached_helmet && helmet)
|
||||
if(H.head)
|
||||
M << "You are unable to deploy your suit's helmet as \the [H.head] is in the way."
|
||||
else
|
||||
M << "Your suit's helmet deploys with a hiss."
|
||||
//TODO: Species check, skull damage for forcing an unfitting helmet on?
|
||||
helmet.loc = H
|
||||
H.equip_to_slot(helmet, slot_head)
|
||||
helmet.canremove = 0
|
||||
|
||||
if(attached_boots && boots)
|
||||
if(H.shoes)
|
||||
M << "You are unable to deploy your suit's magboots as \the [H.shoes] are in the way."
|
||||
else
|
||||
M << "Your suit's boots deploy with a hiss."
|
||||
boots.loc = H
|
||||
H.equip_to_slot(boots, slot_shoes)
|
||||
boots.canremove = 0
|
||||
|
||||
/obj/item/clothing/suit/space/rig/dropped()
|
||||
..()
|
||||
|
||||
var/mob/living/carbon/human/H
|
||||
|
||||
if(helmet)
|
||||
H = helmet.loc
|
||||
if(istype(H))
|
||||
if(helmet && H.head == helmet)
|
||||
helmet.canremove = 1
|
||||
H.drop_from_inventory(helmet)
|
||||
helmet.loc = src
|
||||
|
||||
if(boots)
|
||||
H = boots.loc
|
||||
if(istype(H))
|
||||
if(boots && H.shoes == boots)
|
||||
boots.canremove = 1
|
||||
H.drop_from_inventory(boots)
|
||||
boots.loc = src
|
||||
|
||||
/*
|
||||
/obj/item/clothing/suit/space/rig/verb/get_mounted_device()
|
||||
|
||||
set name = "Deploy Mounted Device"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
if(!can_mount)
|
||||
verbs -= /obj/item/clothing/suit/space/rig/verb/get_mounted_device
|
||||
verbs -= /obj/item/clothing/suit/space/rig/verb/stow_mounted_device
|
||||
return
|
||||
|
||||
if(!istype(usr, /mob/living)) return
|
||||
if(usr.stat) return
|
||||
|
||||
if(active_device)
|
||||
usr << "You already have \the [active_device] deployed."
|
||||
return
|
||||
|
||||
if(!mounted_devices.len)
|
||||
usr << "You do not have any devices mounted on \the [src]."
|
||||
return
|
||||
|
||||
/obj/item/clothing/suit/space/rig/verb/stow_mounted_device()
|
||||
|
||||
set name = "Stow Mounted Device"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
if(!can_mount)
|
||||
verbs -= /obj/item/clothing/suit/space/rig/verb/get_mounted_device
|
||||
verbs -= /obj/item/clothing/suit/space/rig/verb/stow_mounted_device
|
||||
return
|
||||
|
||||
if(!istype(usr, /mob/living)) return
|
||||
|
||||
if(usr.stat) return
|
||||
|
||||
if(!active_device)
|
||||
usr << "You have no device currently deployed."
|
||||
return
|
||||
*/
|
||||
|
||||
/obj/item/clothing/suit/space/rig/verb/toggle_helmet()
|
||||
|
||||
set name = "Toggle Helmet"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
if(!istype(src.loc,/mob/living)) return
|
||||
|
||||
if(!helmet)
|
||||
usr << "There is no helmet installed."
|
||||
return
|
||||
|
||||
var/mob/living/carbon/human/H = usr
|
||||
|
||||
if(!istype(H)) return
|
||||
if(H.stat) return
|
||||
if(H.wear_suit != src) return
|
||||
|
||||
if(H.head == helmet)
|
||||
helmet.canremove = 1
|
||||
H.drop_from_inventory(helmet)
|
||||
helmet.loc = src
|
||||
H << "\blue You retract your hardsuit helmet."
|
||||
else
|
||||
if(H.head)
|
||||
H << "\red You cannot deploy your helmet while wearing another helmet."
|
||||
return
|
||||
//TODO: Species check, skull damage for forcing an unfitting helmet on?
|
||||
helmet.loc = H
|
||||
helmet.pickup(H)
|
||||
H.equip_to_slot(helmet, slot_head)
|
||||
helmet.canremove = 0
|
||||
H << "\blue You deploy your hardsuit helmet, sealing you off from the world."
|
||||
|
||||
/obj/item/clothing/suit/space/rig/attackby(obj/item/W as obj, mob/user as mob)
|
||||
|
||||
if(!istype(user,/mob/living)) return
|
||||
|
||||
if(user.a_intent == "help")
|
||||
|
||||
if(istype(src.loc,/mob/living))
|
||||
user << "How do you propose to modify a hardsuit while it is being worn?"
|
||||
return
|
||||
|
||||
var/target_zone = user.zone_sel.selecting
|
||||
|
||||
if(target_zone == "head")
|
||||
|
||||
//Installing a component into or modifying the contents of the helmet.
|
||||
if(!attached_helmet)
|
||||
user << "\The [src] does not have a helmet mount."
|
||||
return
|
||||
|
||||
if(istype(W,/obj/item/weapon/screwdriver))
|
||||
if(!helmet)
|
||||
user << "\The [src] does not have a helmet installed."
|
||||
else
|
||||
user << "You detatch \the [helmet] from \the [src]'s helmet mount."
|
||||
helmet.loc = get_turf(src)
|
||||
src.helmet = null
|
||||
return
|
||||
else if(istype(W,/obj/item/clothing/head/helmet/space))
|
||||
if(helmet)
|
||||
user << "\The [src] already has a helmet installed."
|
||||
else
|
||||
user << "You attach \the [W] to \the [src]'s helmet mount."
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
src.helmet = W
|
||||
return
|
||||
else
|
||||
return ..()
|
||||
|
||||
else if(target_zone == "l_leg" || target_zone == "r_leg" || target_zone == "l_foot" || target_zone == "r_foot")
|
||||
|
||||
//Installing a component into or modifying the contents of the feet.
|
||||
if(!attached_boots)
|
||||
user << "\The [src] does not have boot mounts."
|
||||
return
|
||||
|
||||
if(istype(W,/obj/item/weapon/screwdriver))
|
||||
if(!boots)
|
||||
user << "\The [src] does not have any boots installed."
|
||||
else
|
||||
user << "You detatch \the [boots] from \the [src]'s boot mounts."
|
||||
boots.loc = get_turf(src)
|
||||
boots = null
|
||||
return
|
||||
else if(istype(W,/obj/item/clothing/shoes/magboots))
|
||||
if(boots)
|
||||
user << "\The [src] already has magboots installed."
|
||||
else
|
||||
user << "You attach \the [W] to \the [src]'s boot mounts."
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
boots = W
|
||||
else
|
||||
return ..()
|
||||
|
||||
/*
|
||||
else if(target_zone == "l_arm" || target_zone == "r_arm" || target_zone == "l_hand" || target_zone == "r_hand")
|
||||
|
||||
//Installing a component into or modifying the contents of the hands.
|
||||
|
||||
else if(target_zone == "torso" || target_zone == "groin")
|
||||
|
||||
//Modifying the cell or mounted devices
|
||||
|
||||
if(!mounted_devices)
|
||||
return
|
||||
*/
|
||||
|
||||
else //wat
|
||||
return ..()
|
||||
|
||||
..()
|
||||
|
||||
//Engineering rig
|
||||
/obj/item/clothing/head/helmet/space/rig/engineering
|
||||
name = "engineering hardsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low-pressure environment. Has radiation shielding."
|
||||
icon_state = "rig0-engineering"
|
||||
item_state = "eng_helm"
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 80)
|
||||
|
||||
/obj/item/clothing/suit/space/rig/engineering
|
||||
name = "engineering hardsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has radiation shielding."
|
||||
icon_state = "rig-engineering"
|
||||
item_state = "eng_hardsuit"
|
||||
slowdown = 1
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 80)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/storage/bag/ore,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/weapon/rcd)
|
||||
|
||||
//Chief Engineer's rig
|
||||
/obj/item/clothing/head/helmet/space/rig/engineering/chief
|
||||
name = "advanced hardsuit helmet"
|
||||
desc = "An advanced helmet designed for work in a hazardous, low pressure environment. Shines with a high polish."
|
||||
icon_state = "rig0-white"
|
||||
item_state = "ce_helm"
|
||||
item_color = "white"
|
||||
sprite_sheets_refit = null
|
||||
sprite_sheets_obj = null
|
||||
|
||||
/obj/item/clothing/suit/space/rig/engineering/chief
|
||||
icon_state = "rig-white"
|
||||
name = "advanced hardsuit"
|
||||
desc = "An advanced suit that protects against hazardous, low pressure environments. Shines with a high polish."
|
||||
item_state = "ce_hardsuit"
|
||||
sprite_sheets_refit = null
|
||||
sprite_sheets_obj = null
|
||||
|
||||
//Mining rig
|
||||
/obj/item/clothing/head/helmet/space/rig/mining
|
||||
name = "mining hardsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low pressure environment. Has reinforced plating."
|
||||
icon_state = "rig0-mining"
|
||||
item_state = "mining_helm"
|
||||
item_color = "mining"
|
||||
armor = list(melee = 50, bullet = 5, laser = 20,energy = 5, bomb = 55, bio = 100, rad = 20)
|
||||
|
||||
/obj/item/clothing/suit/space/rig/mining
|
||||
icon_state = "rig-mining"
|
||||
name = "mining hardsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has reinforced plating."
|
||||
item_state = "mining_hardsuit"
|
||||
armor = list(melee = 50, bullet = 5, laser = 20,energy = 5, bomb = 55, bio = 100, rad = 20)
|
||||
|
||||
|
||||
//Syndicate rig
|
||||
/obj/item/clothing/head/helmet/space/rig/syndi
|
||||
name = "blood-red hardsuit helmet"
|
||||
desc = "An advanced helmet designed for work in special operations. Property of Gorlex Marauders."
|
||||
icon_state = "rig0-syndie"
|
||||
item_state = "syndie_helm"
|
||||
item_color = "syndie"
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 35, bio = 100, rad = 60)
|
||||
siemens_coefficient = 0.6
|
||||
var/obj/machinery/camera/camera
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Vox")
|
||||
|
||||
|
||||
/obj/item/clothing/head/helmet/space/rig/syndi/attack_self(mob/user)
|
||||
if(camera)
|
||||
..(user)
|
||||
else
|
||||
camera = new /obj/machinery/camera(src)
|
||||
camera.network = list("NUKE")
|
||||
cameranet.removeCamera(camera)
|
||||
camera.c_tag = user.name
|
||||
user << "\blue User scanned as [camera.c_tag]. Camera activated."
|
||||
|
||||
/obj/item/clothing/head/helmet/space/rig/syndi/examine()
|
||||
..()
|
||||
if(get_dist(usr,src) <= 1)
|
||||
usr << "This helmet has a built-in camera. It's [camera ? "" : "in"]active."
|
||||
|
||||
/obj/item/clothing/suit/space/rig/syndi
|
||||
icon_state = "rig-syndie"
|
||||
name = "blood-red hardsuit"
|
||||
desc = "An advanced suit that protects against injuries during special operations. Property of Gorlex Marauders."
|
||||
item_state = "syndie_hardsuit"
|
||||
slowdown = 1
|
||||
w_class = 3
|
||||
armor = list(melee = 60, bullet = 50, laser = 30, energy = 15, bomb = 35, bio = 100, rad = 60)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/melee/energy/sword,/obj/item/weapon/handcuffs)
|
||||
siemens_coefficient = 0.6
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Vox")
|
||||
|
||||
|
||||
//Wizard Rig
|
||||
/obj/item/clothing/head/helmet/space/rig/wizard
|
||||
name = "gem-encrusted hardsuit helmet"
|
||||
desc = "A bizarre gem-encrusted helmet that radiates magical energies."
|
||||
icon_state = "rig0-wiz"
|
||||
item_state = "wiz_helm"
|
||||
item_color = "wiz"
|
||||
unacidable = 1 //No longer shall our kind be foiled by lone chemists with spray bottles!
|
||||
armor = list(melee = 40, bullet = 20, laser = 20,energy = 20, bomb = 35, bio = 100, rad = 60)
|
||||
siemens_coefficient = 0.7
|
||||
sprite_sheets_refit = null
|
||||
sprite_sheets_obj = null
|
||||
|
||||
/obj/item/clothing/suit/space/rig/wizard
|
||||
icon_state = "rig-wiz"
|
||||
name = "gem-encrusted hardsuit"
|
||||
desc = "A bizarre gem-encrusted suit that radiates magical energies."
|
||||
item_state = "wiz_hardsuit"
|
||||
slowdown = 1
|
||||
w_class = 3
|
||||
unacidable = 1
|
||||
armor = list(melee = 40, bullet = 20, laser = 20,energy = 20, bomb = 35, bio = 100, rad = 60)
|
||||
siemens_coefficient = 0.7
|
||||
sprite_sheets_refit = null
|
||||
sprite_sheets_obj = null
|
||||
|
||||
//Medical Rig
|
||||
/obj/item/clothing/head/helmet/space/rig/medical
|
||||
name = "medical hardsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low pressure environment. Has minor radiation shielding."
|
||||
icon_state = "rig0-medical"
|
||||
item_state = "medical_helm"
|
||||
item_color = "medical"
|
||||
armor = list(melee = 30, bullet = 5, laser = 20,energy = 5, bomb = 25, bio = 100, rad = 50)
|
||||
|
||||
/obj/item/clothing/suit/space/rig/medical
|
||||
icon_state = "rig-medical"
|
||||
name = "medical hardsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has minor radiation shielding."
|
||||
item_state = "medical_hardsuit"
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/storage/firstaid,/obj/item/device/healthanalyzer,/obj/item/stack/medical)
|
||||
armor = list(melee = 30, bullet = 5, laser = 20,energy = 5, bomb = 25, bio = 100, rad = 50)
|
||||
|
||||
//Security
|
||||
/obj/item/clothing/head/helmet/space/rig/security
|
||||
name = "security hardsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low pressure environment. Has an additional layer of armor."
|
||||
icon_state = "rig0-sec"
|
||||
item_state = "sec_helm"
|
||||
item_color = "sec"
|
||||
armor = list(melee = 60, bullet = 10, laser = 30, energy = 5, bomb = 45, bio = 100, rad = 10)
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
/obj/item/clothing/suit/space/rig/security
|
||||
icon_state = "rig-sec"
|
||||
name = "security hardsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has an additional layer of armor."
|
||||
item_state = "sec_hardsuit"
|
||||
armor = list(melee = 60, bullet = 10, laser = 30, energy = 5, bomb = 45, bio = 100, rad = 10)
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/melee/baton)
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
|
||||
//Atmospherics Rig (BS12)
|
||||
/obj/item/clothing/head/helmet/space/rig/atmos
|
||||
desc = "A special helmet designed for work in a hazardous, low pressure environments. Has improved thermal protection and minor radiation shielding."
|
||||
name = "atmospherics hardsuit helmet"
|
||||
icon_state = "rig0-atmos"
|
||||
item_state = "atmos_helm"
|
||||
item_color = "atmos"
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 50)
|
||||
max_heat_protection_temperature = FIRE_HELMET_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
|
||||
/obj/item/clothing/suit/space/rig/atmos
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has improved thermal protection and minor radiation shielding."
|
||||
icon_state = "rig-atmos"
|
||||
name = "atmos hardsuit"
|
||||
item_state = "atmos_hardsuit"
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 50)
|
||||
max_heat_protection_temperature = FIRESUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
224
code/modules/clothing/spacesuits/rig/modules/combat.dm
Normal file
224
code/modules/clothing/spacesuits/rig/modules/combat.dm
Normal file
@@ -0,0 +1,224 @@
|
||||
/*
|
||||
* Contains
|
||||
* /obj/item/rig_module/grenade_launcher
|
||||
* /obj/item/rig_module/mounted
|
||||
* /obj/item/rig_module/mounted/taser
|
||||
* /obj/item/rig_module/shield
|
||||
* /obj/item/rig_module/fabricator
|
||||
*/
|
||||
|
||||
/obj/item/rig_module/grenade_launcher
|
||||
|
||||
name = "mounted grenade launcher"
|
||||
desc = "A shoulder-mounted micro-explosive dispenser."
|
||||
selectable = 1
|
||||
|
||||
interface_name = "integrated grenade launcher"
|
||||
interface_desc = "Discharges loaded grenades against the wearer's location."
|
||||
|
||||
var/fire_force = 30
|
||||
var/fire_distance = 10
|
||||
|
||||
charges = list(
|
||||
list("flashbang", "flashbang", /obj/item/weapon/grenade/flashbang, 3),
|
||||
list("smoke bomb", "smoke bomb", /obj/item/weapon/grenade/smokebomb, 3),
|
||||
list("EMP grenade", "EMP grenade", /obj/item/weapon/grenade/empgrenade, 3),
|
||||
)
|
||||
|
||||
/obj/item/rig_module/grenade_launcher/accepts_item(var/obj/item/input_device, var/mob/living/user)
|
||||
|
||||
if(!istype(input_device) || !istype(user))
|
||||
return 0
|
||||
|
||||
var/datum/rig_charge/accepted_item
|
||||
for(var/charge in charges)
|
||||
var/datum/rig_charge/charge_datum = charges[charge]
|
||||
if(input_device.type == charge_datum.product_type)
|
||||
accepted_item = charge_datum
|
||||
break
|
||||
|
||||
if(!accepted_item)
|
||||
return 0
|
||||
|
||||
if(accepted_item.charges >= 5)
|
||||
user << "<span class='danger'>Another grenade of that type will not fit into the module.</span>"
|
||||
return 0
|
||||
|
||||
user << "<font color='blue'><b>You slot \the [input_device] into the suit module.</b></font>"
|
||||
user.drop_from_inventory(input_device)
|
||||
del(input_device)
|
||||
accepted_item.charges++
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/grenade_launcher/engage(atom/target)
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
if(!target)
|
||||
return 0
|
||||
|
||||
var/mob/living/carbon/human/H = holder.wearer
|
||||
|
||||
if(!charge_selected)
|
||||
H << "<span class='danger'>You have not selected a grenade type.</span>"
|
||||
return 0
|
||||
|
||||
var/datum/rig_charge/charge = charges[charge_selected]
|
||||
|
||||
if(!charge)
|
||||
return 0
|
||||
|
||||
if(charge.charges <= 0)
|
||||
H << "<span class='danger'>Insufficient grenades!</span>"
|
||||
return 0
|
||||
|
||||
charge.charges--
|
||||
var/obj/item/weapon/grenade/new_grenade = new charge.product_type(get_turf(H))
|
||||
H.visible_message("<span class='danger'>[H] launches \a [new_grenade]!")
|
||||
new_grenade.activate(H)
|
||||
new_grenade.throw_at(target,fire_force,fire_distance)
|
||||
|
||||
/obj/item/rig_module/mounted
|
||||
|
||||
name = "mounted laser cannon"
|
||||
desc = "A shoulder-mounted battery-powered laser cannon mount."
|
||||
selectable = 1
|
||||
usable = 1
|
||||
use_power_cost = 10
|
||||
|
||||
engage_string = "Configure"
|
||||
|
||||
interface_name = "mounted laser cannon"
|
||||
interface_desc = "A shoulder-mounted cell-powered laser cannon."
|
||||
|
||||
var/gun_type = /obj/item/weapon/gun/energy/lasercannon/mounted
|
||||
var/obj/item/weapon/gun/gun
|
||||
|
||||
/obj/item/rig_module/mounted/New()
|
||||
..()
|
||||
gun = new gun_type(src)
|
||||
|
||||
/obj/item/rig_module/mounted/engage(atom/target)
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
if(!target)
|
||||
gun.attack_self(holder.wearer)
|
||||
return 1
|
||||
|
||||
gun.Fire(target,holder.wearer)
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/mounted/taser
|
||||
|
||||
name = "mounted taser"
|
||||
desc = "A shoulder-mounted energy projector."
|
||||
|
||||
usable = 0
|
||||
|
||||
suit_overlay_active = "mounted-taser"
|
||||
suit_overlay_inactive = "mounted-taser"
|
||||
|
||||
interface_name = "mounted energy gun"
|
||||
interface_desc = "A shoulder-mounted cell-powered energy gun."
|
||||
|
||||
gun_type = /obj/item/weapon/gun/energy/gun/mounted
|
||||
|
||||
/obj/item/rig_module/mounted/energy_blade
|
||||
|
||||
name = "energy blade projector"
|
||||
desc = "A powerful cutting beam projector."
|
||||
|
||||
activate_string = "Project Blade"
|
||||
deactivate_string = "Cancel Blade"
|
||||
|
||||
interface_name = "spider fang blade"
|
||||
interface_desc = "A lethal energy projector that can shape a blade projected from the hand of the wearer or launch radioactive darts."
|
||||
|
||||
usable = 0
|
||||
selectable = 1
|
||||
toggleable = 1
|
||||
use_power_cost = 50
|
||||
active_power_cost = 5
|
||||
passive_power_cost = 0
|
||||
|
||||
gun_type = /obj/item/weapon/gun/energy/crossbow/ninja
|
||||
|
||||
/obj/item/rig_module/mounted/energy_blade/process()
|
||||
|
||||
if(holder && holder.wearer)
|
||||
if(!(locate(/obj/item/weapon/melee/energy/blade) in holder.wearer))
|
||||
deactivate()
|
||||
return 0
|
||||
|
||||
return ..()
|
||||
|
||||
/obj/item/rig_module/mounted/energy_blade/activate()
|
||||
|
||||
..()
|
||||
|
||||
var/mob/living/M = holder.wearer
|
||||
|
||||
if(M.l_hand && M.r_hand)
|
||||
M << "<span class='danger'>Your hands are full.</span>"
|
||||
deactivate()
|
||||
return
|
||||
|
||||
var/obj/item/weapon/melee/energy/blade/blade = new(M)
|
||||
blade.creator = M
|
||||
M.put_in_hands(blade)
|
||||
|
||||
/obj/item/rig_module/mounted/energy_blade/deactivate()
|
||||
|
||||
..()
|
||||
|
||||
var/mob/living/M = holder.wearer
|
||||
|
||||
if(!M)
|
||||
return
|
||||
|
||||
for(var/obj/item/weapon/melee/energy/blade/blade in M.contents)
|
||||
M.drop_from_inventory(blade)
|
||||
del(blade)
|
||||
|
||||
/obj/item/rig_module/fabricator
|
||||
|
||||
name = "matter fabricator"
|
||||
desc = "A self-contained microfactory system for hardsuit integration."
|
||||
selectable = 1
|
||||
usable = 1
|
||||
use_power_cost = 15
|
||||
|
||||
engage_string = "Fabricate Star"
|
||||
|
||||
interface_name = "death blossom launcher"
|
||||
interface_desc = "An integrated microfactory that produces poisoned throwing stars from thin air and electricity."
|
||||
|
||||
var/fabrication_type = /obj/item/weapon/star/ninja
|
||||
var/fire_force = 30
|
||||
var/fire_distance = 10
|
||||
|
||||
/obj/item/rig_module/fabricator/engage(atom/target)
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
var/mob/living/H = holder.wearer
|
||||
|
||||
if(target)
|
||||
var/obj/item/firing = new fabrication_type()
|
||||
firing.loc = get_turf(src)
|
||||
H.visible_message("<span class='danger'>[H] launches \a [firing]!</span>")
|
||||
firing.throw_at(target,fire_force,fire_distance)
|
||||
else
|
||||
if(H.l_hand && H.r_hand)
|
||||
H << "<span class='danger'>Your hands are full."
|
||||
else
|
||||
var/obj/item/new_weapon = new fabrication_type()
|
||||
new_weapon.loc = H
|
||||
H << "<font color='blue'><b>You quickly fabricate \a [new_weapon].</b></font>"
|
||||
H.put_in_hands(new_weapon)
|
||||
|
||||
return 1
|
||||
443
code/modules/clothing/spacesuits/rig/modules/computer.dm
Normal file
443
code/modules/clothing/spacesuits/rig/modules/computer.dm
Normal file
@@ -0,0 +1,443 @@
|
||||
/*
|
||||
* Contains
|
||||
* /obj/item/rig_module/ai_container
|
||||
* /obj/item/rig_module/datajack
|
||||
* /obj/item/rig_module/power_sink
|
||||
* /obj/item/rig_module/electrowarfare_suite
|
||||
*/
|
||||
|
||||
/obj/item/ai_verbs
|
||||
name = "AI verb holder"
|
||||
|
||||
/obj/item/ai_verbs/verb/hardsuit_interface()
|
||||
set category = "Hardsuit"
|
||||
set name = "Open Hardsuit Interface"
|
||||
set src in usr
|
||||
|
||||
if(!usr.loc || !usr.loc.loc || !istype(usr.loc.loc, /obj/item/rig_module))
|
||||
usr << "You are not loaded into a hardsuit."
|
||||
return
|
||||
|
||||
var/obj/item/rig_module/module = usr.loc.loc
|
||||
if(!module.holder)
|
||||
usr << "Your module is not installed in a hardsuit."
|
||||
return
|
||||
|
||||
module.holder.ui_interact(usr)
|
||||
|
||||
/obj/item/rig_module/ai_container
|
||||
|
||||
name = "IIS module"
|
||||
desc = "An integrated intelligence system module suitable for most hardsuits."
|
||||
toggleable = 1
|
||||
usable = 1
|
||||
disruptive = 0
|
||||
activates_on_touch = 1
|
||||
|
||||
engage_string = "Eject AI"
|
||||
activate_string = "Enable Dataspike"
|
||||
deactivate_string = "Disable Dataspike"
|
||||
|
||||
interface_name = "integrated intelligence system"
|
||||
interface_desc = "A socket that supports a range of artificial intelligence systems."
|
||||
|
||||
var/mob/integrated_ai // Direct reference to the actual mob held in the suit.
|
||||
var/obj/item/ai_card // Reference to the MMI, posibrain, intellicard or pAI card previously holding the AI.
|
||||
var/obj/item/ai_verbs/verb_holder
|
||||
|
||||
/obj/item/rig_module/ai_container/proc/update_verb_holder()
|
||||
if(!verb_holder)
|
||||
verb_holder = new(src)
|
||||
if(integrated_ai)
|
||||
verb_holder.loc = integrated_ai
|
||||
else
|
||||
verb_holder.loc = src
|
||||
|
||||
/obj/item/rig_module/ai_container/accepts_item(var/obj/item/input_device, var/mob/living/user)
|
||||
|
||||
// Check if there's actually an AI to deal with.
|
||||
var/mob/living/silicon/ai/target_ai
|
||||
if(istype(input_device, /mob/living/silicon/ai))
|
||||
target_ai = input_device
|
||||
else
|
||||
target_ai = locate(/mob/living/silicon/ai) in input_device.contents
|
||||
|
||||
var/obj/item/device/aicard/card = ai_card
|
||||
|
||||
// Downloading from/loading to a terminal.
|
||||
if(istype(input_device,/obj/machinery/computer/aifixer) || istype(input_device,/mob/living/silicon/ai) || istype(input_device,/obj/structure/AIcore/deactivated))
|
||||
|
||||
// If we're stealing an AI, make sure we have a card for it.
|
||||
if(!card)
|
||||
card = new /obj/item/device/aicard(src)
|
||||
|
||||
// Terminal interaction only works with an intellicarded AI.
|
||||
if(!istype(card))
|
||||
return 0
|
||||
|
||||
// Since we've explicitly checked for three types, this should be safe.
|
||||
input_device.attackby(card,user)
|
||||
|
||||
// If the transfer failed we can delete the card.
|
||||
if(locate(/mob/living/silicon/ai) in card)
|
||||
ai_card = card
|
||||
integrated_ai = locate(/mob/living/silicon/ai) in card
|
||||
else
|
||||
eject_ai()
|
||||
update_verb_holder()
|
||||
return 1
|
||||
|
||||
if(istype(input_device,/obj/item/device/aicard))
|
||||
// We are carding the AI in our suit.
|
||||
if(integrated_ai)
|
||||
integrated_ai.attackby(input_device,user)
|
||||
// If the transfer was successful, we can clear out our vars.
|
||||
if(integrated_ai.loc != src)
|
||||
integrated_ai = null
|
||||
eject_ai()
|
||||
else
|
||||
// You're using an empty card on an empty suit, idiot.
|
||||
if(!target_ai)
|
||||
return 0
|
||||
integrate_ai(input_device,user)
|
||||
return 1
|
||||
|
||||
// Okay, it wasn't a terminal being touched, check for all the simple insertions.
|
||||
if(input_device.type in list(/obj/item/device/paicard, /obj/item/device/mmi, /obj/item/device/mmi/digital/posibrain))
|
||||
integrate_ai(input_device,user)
|
||||
return 1
|
||||
|
||||
return 0
|
||||
|
||||
/obj/item/rig_module/ai_container/engage(atom/target)
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
var/mob/living/carbon/human/H = holder.wearer
|
||||
|
||||
if(!target)
|
||||
if(ai_card)
|
||||
if(istype(ai_card,/obj/item/device/aicard))
|
||||
ai_card.attack_self(H)
|
||||
else
|
||||
eject_ai(H)
|
||||
update_verb_holder()
|
||||
return 1
|
||||
|
||||
if(accepts_item(target,H))
|
||||
return 1
|
||||
|
||||
return 0
|
||||
|
||||
/obj/item/rig_module/ai_container/removed()
|
||||
eject_ai()
|
||||
..()
|
||||
|
||||
/obj/item/rig_module/ai_container/proc/eject_ai(var/mob/user)
|
||||
|
||||
if(ai_card)
|
||||
if(istype(ai_card, /obj/item/device/aicard))
|
||||
if(integrated_ai && !integrated_ai.stat)
|
||||
if(user)
|
||||
user << "<span class='danger'>You cannot eject your currently stored AI. Purge it manually.</span>"
|
||||
return 0
|
||||
user << "<span class='danger'>You purge the remaining scraps of data from your previous AI, freeing it for use.</span>"
|
||||
if(integrated_ai)
|
||||
integrated_ai.ghostize()
|
||||
del(integrated_ai)
|
||||
if(ai_card) del(ai_card)
|
||||
else if(user)
|
||||
user.put_in_hands(ai_card)
|
||||
else
|
||||
ai_card.loc = get_turf(src)
|
||||
ai_card = null
|
||||
integrated_ai = null
|
||||
update_verb_holder()
|
||||
|
||||
/obj/item/rig_module/ai_container/proc/integrate_ai(var/obj/item/ai,var/mob/user)
|
||||
|
||||
if(!ai) return
|
||||
|
||||
// The ONLY THING all the different AI systems have in common is that they all store the mob inside an item.
|
||||
var/mob/living/ai_mob = locate(/mob/living) in ai.contents
|
||||
if(ai_mob)
|
||||
|
||||
if(ai_mob.key && ai_mob.client)
|
||||
|
||||
if(istype(ai, /obj/item/device/aicard))
|
||||
|
||||
if(!ai_card)
|
||||
ai_card = new /obj/item/device/aicard(src)
|
||||
|
||||
var/obj/item/device/aicard/source_card = ai
|
||||
var/obj/item/device/aicard/target_card = ai_card
|
||||
if(istype(source_card) && istype(target_card))
|
||||
if(target_card.grab_ai(ai_mob, user))
|
||||
source_card.clear()
|
||||
else
|
||||
return 0
|
||||
else
|
||||
return 0
|
||||
else
|
||||
user.drop_from_inventory(ai)
|
||||
ai.loc = src
|
||||
ai_card = ai
|
||||
ai_mob << "<font color='blue'>You have been transferred to \the [holder]'s [src].</font>"
|
||||
user << "<font color='blue'>You load [ai_mob] into \the [holder]'s [src].</font>"
|
||||
|
||||
integrated_ai = ai_mob
|
||||
|
||||
if(!(locate(integrated_ai) in ai_card))
|
||||
integrated_ai = null
|
||||
eject_ai()
|
||||
else
|
||||
user << "<span class='warning'>There is no active AI within \the [ai].</span>"
|
||||
else
|
||||
user << "<span class='warning'>There is no active AI within \the [ai].</span>"
|
||||
update_verb_holder()
|
||||
return
|
||||
|
||||
/obj/item/rig_module/datajack
|
||||
|
||||
name = "datajack module"
|
||||
desc = "A simple induction datalink module."
|
||||
toggleable = 1
|
||||
activates_on_touch = 1
|
||||
usable = 0
|
||||
|
||||
activate_string = "Enable Datajack"
|
||||
deactivate_string = "Disable Datajack"
|
||||
|
||||
interface_name = "contact datajack"
|
||||
interface_desc = "An induction-powered high-throughput datalink suitable for hacking encrypted networks."
|
||||
var/list/stored_research
|
||||
|
||||
/obj/item/rig_module/datajack/New()
|
||||
..()
|
||||
stored_research = list()
|
||||
|
||||
/obj/item/rig_module/datajack/engage(atom/target)
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
if(target)
|
||||
var/mob/living/carbon/human/H = holder.wearer
|
||||
if(!accepts_item(target,H))
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/datajack/accepts_item(var/obj/item/input_device, var/mob/living/user)
|
||||
|
||||
if(istype(input_device,/obj/item/weapon/disk/tech_disk))
|
||||
user << "You slot the disk into [src]."
|
||||
var/obj/item/weapon/disk/tech_disk/disk = input_device
|
||||
if(disk.stored)
|
||||
if(load_data(disk.stored))
|
||||
user << "<font color='blue'>Download successful; disk erased.</font>"
|
||||
disk.stored = null
|
||||
else
|
||||
user << "<span class='warning'>The disk is corrupt. It is useless to you.</span>"
|
||||
else
|
||||
user << "<span class='warning'>The disk is blank. It is useless to you.</span>"
|
||||
return 1
|
||||
|
||||
// I fucking hate R&D code. This typecheck spam would be totally unnecessary in a sane setup.
|
||||
else if(istype(input_device,/obj/machinery))
|
||||
var/datum/research/incoming_files
|
||||
if(istype(input_device,/obj/machinery/computer/rdconsole))
|
||||
var/obj/machinery/computer/rdconsole/input_machine = input_device
|
||||
incoming_files = input_machine.files
|
||||
else if(istype(input_device,/obj/machinery/r_n_d/server))
|
||||
var/obj/machinery/r_n_d/server/input_machine = input_device
|
||||
incoming_files = input_machine.files
|
||||
else if(istype(input_device,/obj/machinery/mecha_part_fabricator))
|
||||
var/obj/machinery/mecha_part_fabricator/input_machine = input_device
|
||||
incoming_files = input_machine.files
|
||||
|
||||
if(!incoming_files || !incoming_files.known_tech || !incoming_files.known_tech.len)
|
||||
user << "<span class='warning'>Memory failure. There is nothing accessible stored on this terminal.</span>"
|
||||
else
|
||||
// Maybe consider a way to drop all your data into a target repo in the future.
|
||||
if(load_data(incoming_files.known_tech))
|
||||
user << "<font color='blue'>Download successful; local and remote repositories synchronized.</font>"
|
||||
else
|
||||
user << "<span class='warning'>Scan complete. There is nothing useful stored on this terminal.</span>"
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/rig_module/datajack/proc/load_data(var/incoming_data)
|
||||
|
||||
if(islist(incoming_data))
|
||||
for(var/entry in incoming_data)
|
||||
load_data(entry)
|
||||
return 1
|
||||
|
||||
if(istype(incoming_data, /datum/tech))
|
||||
var/data_found
|
||||
var/datum/tech/new_data = incoming_data
|
||||
for(var/datum/tech/current_data in stored_research)
|
||||
if(current_data.id == new_data.id)
|
||||
data_found = 1
|
||||
if(current_data.level < new_data.level)
|
||||
current_data.level = new_data.level
|
||||
break
|
||||
if(!data_found)
|
||||
stored_research += incoming_data
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/rig_module/electrowarfare_suite
|
||||
|
||||
name = "electrowarfare module"
|
||||
desc = "A bewilderingly complex bundle of fiber optics and chips."
|
||||
toggleable = 1
|
||||
usable = 0
|
||||
|
||||
activate_string = "Enable Countermeasures"
|
||||
deactivate_string = "Disable Countermeasures"
|
||||
|
||||
interface_name = "electrowarfare system"
|
||||
interface_desc = "An active counter-electronic warfare suite that disrupts AI tracking."
|
||||
|
||||
/obj/item/rig_module/electrowarfare_suite/activate()
|
||||
|
||||
if(!..())
|
||||
return
|
||||
|
||||
// This is not the best way to handle this, but I don't want it to mess with ling camo
|
||||
var/mob/living/M = holder.wearer
|
||||
M.digitalcamo++
|
||||
|
||||
/obj/item/rig_module/electrowarfare_suite/deactivate()
|
||||
|
||||
if(!..())
|
||||
return
|
||||
|
||||
var/mob/living/M = holder.wearer
|
||||
M.digitalcamo = max(0,(M.digitalcamo-1))
|
||||
|
||||
/obj/item/rig_module/power_sink
|
||||
|
||||
name = "hardsuit power sink"
|
||||
desc = "An heavy-duty power sink."
|
||||
toggleable = 1
|
||||
activates_on_touch = 1
|
||||
disruptive = 0
|
||||
|
||||
activate_string = "Enable Power Sink"
|
||||
deactivate_string = "Disable Power Sink"
|
||||
|
||||
interface_name = "niling d-sink"
|
||||
interface_desc = "Colloquially known as a power siphon, this module drains power through the suit hands into the suit battery."
|
||||
|
||||
var/atom/interfaced_with // Currently draining power from this device.
|
||||
var/total_power_drained = 0
|
||||
|
||||
/obj/item/rig_module/power_sink/deactivate()
|
||||
|
||||
if(interfaced_with)
|
||||
if(holder && holder.wearer)
|
||||
holder.wearer << "<span class = 'warning'>Your power sink retracts as the module deactivates.</span>"
|
||||
drain_complete()
|
||||
interfaced_with = null
|
||||
total_power_drained = 0
|
||||
return ..()
|
||||
|
||||
/obj/item/rig_module/power_sink/activate()
|
||||
interfaced_with = null
|
||||
total_power_drained = 0
|
||||
return ..()
|
||||
|
||||
/obj/item/rig_module/power_sink/engage(atom/target)
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
//Target wasn't supplied or we're already draining.
|
||||
if(interfaced_with)
|
||||
return 0
|
||||
|
||||
if(!target)
|
||||
return 1
|
||||
|
||||
// Are we close enough?
|
||||
var/mob/living/carbon/human/H = holder.wearer
|
||||
if(!target.Adjacent(H))
|
||||
return 0
|
||||
|
||||
// Is it a valid power source?
|
||||
if(target.drain_power(1) <= 0)
|
||||
return 0
|
||||
|
||||
H << "<span class = 'danger'>You begin draining power from [target]!</span>"
|
||||
interfaced_with = target
|
||||
|
||||
holder.spark_system.start()
|
||||
playsound(H.loc, 'sound/effects/sparks2.ogg', 50, 1)
|
||||
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/power_sink/accepts_item(var/obj/item/input_device, var/mob/living/user)
|
||||
var/can_drain = input_device.drain_power(1)
|
||||
if(can_drain > 0)
|
||||
engage(input_device)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/rig_module/power_sink/process()
|
||||
|
||||
if(!interfaced_with)
|
||||
return ..()
|
||||
|
||||
var/mob/living/carbon/human/H
|
||||
if(holder && holder.wearer)
|
||||
H = holder.wearer
|
||||
|
||||
if(!H || !istype(H))
|
||||
return 0
|
||||
|
||||
holder.spark_system.start()
|
||||
playsound(H.loc, 'sound/effects/sparks2.ogg', 50, 1)
|
||||
|
||||
if(!holder.cell)
|
||||
H << "<span class = 'danger'>Your power sink flashes an error; there is no cell in your rig.</span>"
|
||||
drain_complete(H)
|
||||
return
|
||||
|
||||
if(!interfaced_with || !interfaced_with.Adjacent(H))
|
||||
H << "<span class = 'warning'>Your power sink retracts into its casing.</span>"
|
||||
drain_complete(H)
|
||||
return
|
||||
|
||||
if(holder.cell.fully_charged())
|
||||
H << "<span class = 'warning'>Your power sink flashes an amber light; your rig cell is full.</span>"
|
||||
drain_complete(H)
|
||||
return
|
||||
|
||||
// Attempts to drain up to 40kW, determines this value from remaining cell capacity to ensure we don't drain too much..
|
||||
var/to_drain = min(40000, ((holder.cell.maxcharge - holder.cell.charge) / CELLRATE))
|
||||
var/target_drained = interfaced_with.drain_power(0,0,to_drain)
|
||||
if(target_drained <= 0)
|
||||
H << "<span class = 'danger'>Your power sink flashes a red light; there is no power left in [interfaced_with].</span>"
|
||||
drain_complete(H)
|
||||
return
|
||||
|
||||
holder.cell.give(target_drained * CELLRATE)
|
||||
total_power_drained += target_drained
|
||||
|
||||
|
||||
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/power_sink/proc/drain_complete(var/mob/living/M)
|
||||
|
||||
if(!interfaced_with)
|
||||
if(M) M << "<font color='blue'><b>Total power drained:</b> [round(total_power_drained/1000)]kJ.</font>"
|
||||
else
|
||||
if(M) M << "<font color='blue'><b>Total power drained from [interfaced_with]:</b> [round(total_power_drained/1000)]kJ.</font>"
|
||||
interfaced_with.drain_power(0,1,0) // Damage the victim.
|
||||
|
||||
interfaced_with = null
|
||||
total_power_drained = 0
|
||||
212
code/modules/clothing/spacesuits/rig/modules/modules.dm
Normal file
212
code/modules/clothing/spacesuits/rig/modules/modules.dm
Normal file
@@ -0,0 +1,212 @@
|
||||
/*
|
||||
* Rigsuit upgrades/abilities.
|
||||
*/
|
||||
|
||||
/datum/rig_charge
|
||||
var/short_name = "undef"
|
||||
var/display_name = "undefined"
|
||||
var/product_type = "undefined"
|
||||
var/charges = 0
|
||||
|
||||
/obj/item/rig_module
|
||||
name = "hardsuit upgrade"
|
||||
desc = "It looks pretty sciency."
|
||||
icon = 'icons/obj/rig_modules.dmi'
|
||||
icon_state = "module"
|
||||
matter = list("metal" = 20000, "plastic" = 30000, "glass" = 5000)
|
||||
|
||||
var/damage = 0
|
||||
var/obj/item/weapon/rig/holder
|
||||
|
||||
var/module_cooldown = 10
|
||||
var/next_use = 0
|
||||
|
||||
var/toggleable // Set to 1 for the device to show up as an active effect.
|
||||
var/usable // Set to 1 for the device to have an on-use effect.
|
||||
var/selectable // Set to 1 to be able to assign the device as primary system.
|
||||
var/redundant // Set to 1 to ignore duplicate module checking when installing.
|
||||
var/permanent // If set, the module can't be removed.
|
||||
var/disruptive = 1 // Can disrupt by other effects.
|
||||
var/activates_on_touch // If set, unarmed attacks will call engage() on the target.
|
||||
|
||||
var/active // Basic module status
|
||||
var/disruptable // Will deactivate if some other powers are used.
|
||||
|
||||
var/use_power_cost = 0 // Power used when single-use ability called.
|
||||
var/active_power_cost = 0 // Power used when turned on.
|
||||
var/passive_power_cost = 0 // Power used when turned off.
|
||||
|
||||
var/list/charges // Associative list of charge types and remaining numbers.
|
||||
var/charge_selected // Currently selected option used for charge dispensing.
|
||||
|
||||
// Icons.
|
||||
var/suit_overlay
|
||||
var/suit_overlay_active // If set, drawn over icon and mob when effect is active.
|
||||
var/suit_overlay_inactive // As above, inactive.
|
||||
var/suit_overlay_used // As above, when engaged.
|
||||
|
||||
//Display fluff
|
||||
var/interface_name = "hardsuit upgrade"
|
||||
var/interface_desc = "A generic hardsuit upgrade."
|
||||
var/engage_string = "Engage"
|
||||
var/activate_string = "Activate"
|
||||
var/deactivate_string = "Deactivate"
|
||||
|
||||
/obj/item/rig_module/examine()
|
||||
..()
|
||||
switch(damage)
|
||||
if(0)
|
||||
usr << "It is undamaged."
|
||||
if(1)
|
||||
usr << "It is badly damaged."
|
||||
if(2)
|
||||
usr << "It is almost completely destroyed."
|
||||
|
||||
/obj/item/rig_module/attackby(obj/item/W as obj, mob/user as mob)
|
||||
|
||||
if(istype(W,/obj/item/stack/nanopaste))
|
||||
|
||||
if(damage == 0)
|
||||
user << "There is no damage to mend."
|
||||
return
|
||||
|
||||
user << "You start mending the damaged portions of \the [src]..."
|
||||
|
||||
if(!do_after(user,30) || !W || !src)
|
||||
return
|
||||
|
||||
var/obj/item/stack/nanopaste/paste = W
|
||||
damage = 0
|
||||
user << "You mend the damage to [src] with [W]."
|
||||
paste.use(1)
|
||||
return
|
||||
|
||||
else if(istype(W,/obj/item/stack/cable_coil))
|
||||
|
||||
switch(damage)
|
||||
if(0)
|
||||
user << "There is no damage to mend."
|
||||
return
|
||||
if(2)
|
||||
user << "There is no damage that you are capable of mending with such crude tools."
|
||||
return
|
||||
|
||||
var/obj/item/stack/cable_coil/cable = W
|
||||
if(!cable.amount >= 5)
|
||||
user << "You need five units of cable to repair \the [src]."
|
||||
return
|
||||
|
||||
user << "You start mending the damaged portions of \the [src]..."
|
||||
if(!do_after(user,30) || !W || !src)
|
||||
return
|
||||
|
||||
damage = 1
|
||||
user << "You mend some of damage to [src] with [W], but you will need more advanced tools to fix it completely."
|
||||
cable.use(5)
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/item/rig_module/New()
|
||||
..()
|
||||
if(suit_overlay_inactive)
|
||||
suit_overlay = suit_overlay_inactive
|
||||
|
||||
if(charges && charges.len)
|
||||
var/list/processed_charges = list()
|
||||
for(var/list/charge in charges)
|
||||
var/datum/rig_charge/charge_dat = new
|
||||
|
||||
charge_dat.short_name = charge[1]
|
||||
charge_dat.display_name = charge[2]
|
||||
charge_dat.product_type = charge[3]
|
||||
charge_dat.charges = charge[4]
|
||||
|
||||
if(!charge_selected) charge_selected = charge_dat.short_name
|
||||
processed_charges[charge_dat.short_name] = charge_dat
|
||||
|
||||
charges = processed_charges
|
||||
|
||||
..()
|
||||
|
||||
// Called when the module is installed into a suit.
|
||||
/obj/item/rig_module/proc/installed(var/obj/item/weapon/rig/new_holder)
|
||||
holder = new_holder
|
||||
return
|
||||
|
||||
//Proc for one-use abilities like teleport.
|
||||
/obj/item/rig_module/proc/engage()
|
||||
|
||||
if(damage >= 2)
|
||||
usr << "<span class='warning'>The [interface_name] is damaged beyond use!</span>"
|
||||
|
||||
if(world.time < next_use)
|
||||
usr << "<span class='warning'>You cannot use the [interface_name] again so soon.</span>"
|
||||
return 0
|
||||
|
||||
if(!holder || holder.canremove)
|
||||
usr << "<span class='warning'>The suit is not initialized.</span>"
|
||||
return 0
|
||||
|
||||
if(holder.security_check_enabled && !holder.check_suit_access(usr))
|
||||
usr << "<span class='danger'>Access denied.</span>"
|
||||
return
|
||||
|
||||
if(!holder.check_power_cost(usr, use_power_cost, 0, src, (istype(usr,/mob/living/silicon ? 1 : 0) ) ) )
|
||||
return 0
|
||||
|
||||
next_use = world.time + module_cooldown
|
||||
|
||||
return 1
|
||||
|
||||
// Proc for toggling on active abilities.
|
||||
/obj/item/rig_module/proc/activate()
|
||||
|
||||
if(active || !engage())
|
||||
return 0
|
||||
|
||||
active = 1
|
||||
|
||||
spawn(1)
|
||||
if(suit_overlay_active)
|
||||
suit_overlay = suit_overlay_active
|
||||
else
|
||||
suit_overlay = null
|
||||
holder.update_icon()
|
||||
|
||||
return 1
|
||||
|
||||
// Proc for toggling off active abilities.
|
||||
/obj/item/rig_module/proc/deactivate()
|
||||
|
||||
if(!active)
|
||||
return 0
|
||||
|
||||
active = 0
|
||||
|
||||
spawn(1)
|
||||
if(suit_overlay_inactive)
|
||||
suit_overlay = suit_overlay_inactive
|
||||
else
|
||||
suit_overlay = null
|
||||
if(holder)
|
||||
holder.update_icon()
|
||||
|
||||
return 1
|
||||
|
||||
// Called when the module is uninstalled from a suit.
|
||||
/obj/item/rig_module/proc/removed()
|
||||
deactivate()
|
||||
holder = null
|
||||
return
|
||||
|
||||
// Called by the hardsuit each rig process tick.
|
||||
/obj/item/rig_module/process()
|
||||
if(active)
|
||||
return active_power_cost
|
||||
else
|
||||
return passive_power_cost
|
||||
|
||||
// Called by holder rigsuit attackby()
|
||||
// Checks if an item is usable with this module and handles it if it is
|
||||
/obj/item/rig_module/proc/accepts_item(var/obj/item/input_device)
|
||||
return 0
|
||||
186
code/modules/clothing/spacesuits/rig/modules/ninja.dm
Normal file
186
code/modules/clothing/spacesuits/rig/modules/ninja.dm
Normal file
@@ -0,0 +1,186 @@
|
||||
/*
|
||||
* Contains
|
||||
* /obj/item/rig_module/stealth_field
|
||||
* /obj/item/rig_module/teleporter
|
||||
* /obj/item/rig_module/fabricator/energy_net
|
||||
* /obj/item/rig_module/self_destruct
|
||||
*/
|
||||
|
||||
/obj/item/rig_module/stealth_field
|
||||
|
||||
name = "active camouflage module"
|
||||
desc = "A robust hardsuit-integrated stealth module."
|
||||
icon_state = "stealth"
|
||||
|
||||
toggleable = 1
|
||||
disruptable = 1
|
||||
disruptive = 0
|
||||
|
||||
use_power_cost = 5
|
||||
active_power_cost = 1
|
||||
passive_power_cost = 0
|
||||
|
||||
activate_string = "Enable Cloak"
|
||||
deactivate_string = "Disable Cloak"
|
||||
|
||||
interface_name = "integrated stealth system"
|
||||
interface_desc = "An integrated active camouflage system."
|
||||
|
||||
suit_overlay_active = "stealth_active"
|
||||
suit_overlay_inactive = "stealth_inactive"
|
||||
|
||||
/obj/item/rig_module/stealth_field/activate()
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
var/mob/living/carbon/human/H = holder.wearer
|
||||
|
||||
H << "<font color='blue'><b>You are now invisible to normal detection.</b></font>"
|
||||
H.invisibility = INVISIBILITY_LEVEL_TWO
|
||||
|
||||
anim(get_turf(H), H, 'icons/effects/effects.dmi', "electricity",null,20,null)
|
||||
|
||||
H.visible_message("[H.name] vanishes into thin air!",1)
|
||||
|
||||
/obj/item/rig_module/stealth_field/deactivate()
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
var/mob/living/carbon/human/H = holder.wearer
|
||||
|
||||
H << "<span class='danger'>You are now visible.</span>"
|
||||
H.invisibility = 0
|
||||
|
||||
anim(get_turf(H), H,'icons/mob/mob.dmi',,"uncloak",,H.dir)
|
||||
anim(get_turf(H), H, 'icons/effects/effects.dmi', "electricity",null,20,null)
|
||||
|
||||
for(var/mob/O in oviewers(H))
|
||||
O.show_message("[H.name] appears from thin air!",1)
|
||||
playsound(get_turf(H), 'sound/effects/stealthoff.ogg', 75, 1)
|
||||
|
||||
|
||||
/obj/item/rig_module/teleporter
|
||||
|
||||
name = "teleportation module"
|
||||
desc = "A complex, sleek-looking, hardsuit-integrated teleportation module."
|
||||
use_power_cost = 40
|
||||
redundant = 1
|
||||
usable = 1
|
||||
selectable = 1
|
||||
|
||||
engage_string = "Emergency Leap"
|
||||
|
||||
interface_name = "VOID-shift phase projector"
|
||||
interface_desc = "An advanced teleportation system. It is capable of pinpoint precision or random leaps forward."
|
||||
|
||||
/obj/item/rig_module/teleporter/proc/phase_in(var/mob/M,var/turf/T)
|
||||
|
||||
if(!M || !T)
|
||||
return
|
||||
|
||||
holder.spark_system.start()
|
||||
playsound(T, 'sound/effects/phasein.ogg', 25, 1)
|
||||
playsound(T, 'sound/effects/sparks2.ogg', 50, 1)
|
||||
anim(T,M,'icons/mob/mob.dmi',,"phasein",,M.dir)
|
||||
|
||||
/obj/item/rig_module/teleporter/proc/phase_out(var/mob/M,var/turf/T)
|
||||
|
||||
if(!M || !T)
|
||||
return
|
||||
|
||||
playsound(T, "sparks", 50, 1)
|
||||
anim(T,M,'icons/mob/mob.dmi',,"phaseout",,M.dir)
|
||||
|
||||
/obj/item/rig_module/teleporter/engage(atom/target)
|
||||
|
||||
if(!..()) return 0
|
||||
|
||||
var/mob/living/carbon/human/H = holder.wearer
|
||||
|
||||
var/turf/T
|
||||
if(target)
|
||||
T = get_turf(target)
|
||||
else
|
||||
T = get_teleport_loc(get_turf(H), H, rand(5, 9))
|
||||
|
||||
if(!T || T.density)
|
||||
H << "<span class='warning'>You cannot teleport into solid walls.</span>"
|
||||
return 0
|
||||
|
||||
phase_out(H,get_turf(H))
|
||||
H.loc = T
|
||||
phase_in(H,get_turf(H))
|
||||
|
||||
for(var/obj/item/weapon/grab/G in H.contents)
|
||||
if(G.affecting)
|
||||
phase_out(G.affecting,get_turf(G.affecting))
|
||||
G.affecting.loc = locate(T.x+rand(-1,1),T.y+rand(-1,1),T.z)
|
||||
phase_in(G.affecting,get_turf(G.affecting))
|
||||
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/fabricator/energy_net
|
||||
|
||||
name = "net projector"
|
||||
desc = "Some kind of complex energy projector with a hardsuit mount."
|
||||
|
||||
interface_name = "energy net launcher"
|
||||
interface_desc = "An advanced energy-patterning projector used to capture targets."
|
||||
|
||||
engage_string = "Fabricate Net"
|
||||
|
||||
fabrication_type = /obj/item/weapon/energy_net
|
||||
use_power_cost = 70
|
||||
|
||||
/obj/item/rig_module/fabricator/energy_net/engage(atom/target)
|
||||
|
||||
if(holder && holder.wearer)
|
||||
if(..(target) && target)
|
||||
holder.wearer.Beam(target,"n_beam",,10)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/rig_module/self_destruct
|
||||
|
||||
name = "self-destruct module"
|
||||
desc = "Oh my God, Captain. A bomb."
|
||||
usable = 1
|
||||
active = 1
|
||||
permanent = 1
|
||||
|
||||
engage_string = "Detonate"
|
||||
|
||||
interface_name = "dead man's switch"
|
||||
interface_desc = "An integrated self-destruct module. When the wearer dies, so does the surrounding area. Do not press this button."
|
||||
|
||||
/obj/item/rig_module/self_destruct/activate()
|
||||
return
|
||||
|
||||
/obj/item/rig_module/self_destruct/deactivate()
|
||||
return
|
||||
|
||||
/obj/item/rig_module/self_destruct/process()
|
||||
|
||||
// Not being worn, leave it alone.
|
||||
if(!holder || !holder.wearer || !holder.wearer.wear_suit == holder)
|
||||
return 0
|
||||
|
||||
//OH SHIT.
|
||||
if(holder.wearer.stat == 2)
|
||||
engage()
|
||||
|
||||
/obj/item/rig_module/self_destruct/engage()
|
||||
explosion(get_turf(src), 1, 2, 4, 5)
|
||||
if(holder && holder.wearer)
|
||||
holder.wearer.drop_from_inventory(src)
|
||||
del(holder)
|
||||
del(src)
|
||||
|
||||
/obj/item/rig_module/self_destruct/small/engage()
|
||||
explosion(get_turf(src), 0, 0, 3, 4)
|
||||
if(holder && holder.wearer)
|
||||
holder.wearer.drop_from_inventory(src)
|
||||
del(holder)
|
||||
del(src)
|
||||
341
code/modules/clothing/spacesuits/rig/modules/utility.dm
Normal file
341
code/modules/clothing/spacesuits/rig/modules/utility.dm
Normal file
@@ -0,0 +1,341 @@
|
||||
/* Contains:
|
||||
* /obj/item/rig_module/device
|
||||
* /obj/item/rig_module/device/plasmacutter
|
||||
* /obj/item/rig_module/device/healthscanner
|
||||
* /obj/item/rig_module/device/drill
|
||||
* /obj/item/rig_module/device/orescanner
|
||||
* /obj/item/rig_module/device/rcd
|
||||
* /obj/item/rig_module/device/anomaly_scanner
|
||||
* /obj/item/rig_module/maneuvering_jets
|
||||
* /obj/item/rig_module/foam_sprayer
|
||||
* /obj/item/rig_module/device/broadcaster
|
||||
* /obj/item/rig_module/chem_dispenser
|
||||
* /obj/item/rig_module/chem_dispenser/injector
|
||||
* /obj/item/rig_module/voice
|
||||
*/
|
||||
|
||||
/obj/item/rig_module/device
|
||||
name = "mounted device"
|
||||
desc = "Some kind of hardsuit mount."
|
||||
usable = 0
|
||||
selectable = 1
|
||||
toggleable = 0
|
||||
disruptive = 0
|
||||
|
||||
var/device_type
|
||||
var/obj/item/device
|
||||
|
||||
/obj/item/rig_module/device/plasmacutter
|
||||
name = "hardsuit plasma cutter"
|
||||
desc = "A lethal-looking industrial cutter."
|
||||
interface_name = "plasma cutter"
|
||||
interface_desc = "A self-sustaining plasma arc capable of cutting through walls."
|
||||
suit_overlay_active = "plasmacutter"
|
||||
suit_overlay_inactive = "plasmacutter"
|
||||
|
||||
device_type = /obj/item/weapon/pickaxe/plasmacutter
|
||||
|
||||
/obj/item/rig_module/device/healthscanner
|
||||
name = "health scanner module"
|
||||
desc = "A hardsuit-mounted health scanner."
|
||||
interface_name = "health scanner"
|
||||
interface_desc = "Shows an informative health readout when used on a subject."
|
||||
|
||||
device_type = /obj/item/device/healthanalyzer
|
||||
|
||||
/obj/item/rig_module/device/drill
|
||||
name = "hardsuit drill mount"
|
||||
desc = "A very heavy diamond-tipped drill."
|
||||
interface_name = "mounted drill"
|
||||
interface_desc = "A diamond-tipped industrial drill."
|
||||
suit_overlay_active = "mounted-drill"
|
||||
suit_overlay_inactive = "mounted-drill"
|
||||
|
||||
device_type = /obj/item/weapon/pickaxe/diamonddrill
|
||||
|
||||
/obj/item/rig_module/device/anomaly_scanner
|
||||
name = "hardsuit anomaly scanner"
|
||||
desc = "You think it's called an Elder Sarsparilla or something."
|
||||
interface_name = "Alden-Saraspova counter"
|
||||
interface_desc = "An exotic particle detector commonly used by xenoarchaeologists."
|
||||
engage_string = "Begin Scan"
|
||||
usable = 1
|
||||
selectable = 0
|
||||
device_type = /obj/item/device/ano_scanner
|
||||
|
||||
/obj/item/rig_module/device/orescanner
|
||||
name = "ore scanner module"
|
||||
desc = "A clunky old ore scanner."
|
||||
interface_name = "ore detector"
|
||||
interface_desc = "A sonar system for detecting large masses of ore."
|
||||
engage_string = "Begin Scan"
|
||||
usable = 1
|
||||
selectable = 0
|
||||
device_type = /obj/item/weapon/mining_scanner
|
||||
|
||||
/obj/item/rig_module/device/rcd
|
||||
name = "RCD mount"
|
||||
desc = "A cell-powered rapid construction device for a hardsuit."
|
||||
interface_name = "mounted RCD"
|
||||
interface_desc = "A device for building or removing walls. Cell-powered."
|
||||
usable = 1
|
||||
engage_string = "Configure RCD"
|
||||
|
||||
device_type = /obj/item/weapon/rcd/mounted
|
||||
|
||||
/obj/item/rig_module/device/New()
|
||||
..()
|
||||
if(device_type) device = new device_type(src)
|
||||
|
||||
/obj/item/rig_module/device/engage(atom/target)
|
||||
|
||||
if(!..() || !device)
|
||||
return 0
|
||||
|
||||
if(!target)
|
||||
device.attack_self(holder.wearer)
|
||||
return 1
|
||||
|
||||
var/turf/T = get_turf(target)
|
||||
if(istype(T) && !T.Adjacent(get_turf(src)))
|
||||
return 0
|
||||
|
||||
var/resolved = target.attackby(device,holder.wearer)
|
||||
if(!resolved && device && target)
|
||||
device.afterattack(target,holder.wearer,1)
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/chem_dispenser
|
||||
name = "mounted chemical dispenser"
|
||||
desc = "A complex web of tubing and needles suitable for hardsuit use."
|
||||
usable = 1
|
||||
selectable = 0
|
||||
toggleable = 0
|
||||
disruptive = 0
|
||||
|
||||
engage_string = "Inject"
|
||||
|
||||
interface_name = "integrated chemical dispenser"
|
||||
interface_desc = "Dispenses loaded chemicals directly into the wearer's bloodstream."
|
||||
|
||||
charges = list(
|
||||
list("tricordrazine", "tricordrazine", 0, 80),
|
||||
list("tramadol", "tramadol", 0, 80),
|
||||
list("dexalin plus", "dexalinp", 0, 80),
|
||||
list("antibiotics", "spaceacillin", 0, 80),
|
||||
list("antitoxins", "anti_toxin", 0, 80),
|
||||
list("nutrients", "nutriment", 0, 80),
|
||||
list("hyronalin", "hyronalin", 0, 80),
|
||||
list("radium", "radium", 0, 80)
|
||||
)
|
||||
|
||||
var/max_reagent_volume = 80 //Used when refilling.
|
||||
|
||||
/obj/item/rig_module/chem_dispenser/accepts_item(var/obj/item/input_item, var/mob/living/user)
|
||||
|
||||
if(!input_item.is_open_container())
|
||||
return 0
|
||||
|
||||
if(!input_item.reagents || !input_item.reagents.total_volume)
|
||||
user << "\The [input_item] is empty."
|
||||
return 0
|
||||
|
||||
// Magical chemical filtration system, do not question it.
|
||||
var/total_transferred = 0
|
||||
for(var/datum/reagent/R in input_item.reagents.reagent_list)
|
||||
for(var/chargetype in charges)
|
||||
var/datum/rig_charge/charge = charges[chargetype]
|
||||
if(charge.display_name == R.id)
|
||||
|
||||
var/chems_to_transfer = R.volume
|
||||
|
||||
if((charge.charges + chems_to_transfer) > max_reagent_volume)
|
||||
chems_to_transfer = max_reagent_volume - charge.charges
|
||||
|
||||
charge.charges += chems_to_transfer
|
||||
input_item.reagents.remove_reagent(R.id, chems_to_transfer)
|
||||
total_transferred += chems_to_transfer
|
||||
|
||||
break
|
||||
|
||||
if(total_transferred)
|
||||
user << "<font color='blue'>You transfer [total_transferred] units into the suit reservoir.</font>"
|
||||
else
|
||||
user << "<span class='danger'>None of the reagents seem suitable.</span>"
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/chem_dispenser/engage(atom/target)
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
var/mob/living/carbon/human/H = holder.wearer
|
||||
|
||||
if(!charge_selected)
|
||||
H << "<span class='danger'>You have not selected a chemical type.</span>"
|
||||
return 0
|
||||
|
||||
var/datum/rig_charge/charge = charges[charge_selected]
|
||||
|
||||
if(!charge)
|
||||
return 0
|
||||
|
||||
var/chems_to_use = 10
|
||||
if(charge.charges <= 0)
|
||||
H << "<span class='danger'>Insufficient chems!</span>"
|
||||
return 0
|
||||
else if(charge.charges < chems_to_use)
|
||||
chems_to_use = charge.charges
|
||||
|
||||
var/mob/living/target_mob
|
||||
if(target)
|
||||
if(istype(target,/mob/living))
|
||||
target_mob = target
|
||||
else
|
||||
return 0
|
||||
else
|
||||
target_mob = H
|
||||
|
||||
if(target_mob != H)
|
||||
H << "<span class='danger'>You inject [target_mob] with [chems_to_use] unit[chems_to_use == 1 ? "" : "s"] of [charge.display_name].</span>"
|
||||
target_mob << "<span class='danger'>You feel a rushing in your veins as [chems_to_use] unit[chems_to_use == 1 ? "" : "s"] of [charge.display_name] [chems_to_use == 1 ? "is" : "are"] injected.</span>"
|
||||
target_mob.reagents.add_reagent(charge.display_name, chems_to_use)
|
||||
|
||||
charge.charges -= chems_to_use
|
||||
if(charge.charges < 0) charge.charges = 0
|
||||
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/chem_dispenser/combat
|
||||
|
||||
|
||||
/obj/item/rig_module/chem_dispenser/injector
|
||||
|
||||
name = "mounted chemical injector"
|
||||
desc = "A complex web of tubing and a large needle suitable for hardsuit use."
|
||||
usable = 0
|
||||
selectable = 1
|
||||
disruptive = 1
|
||||
|
||||
interface_name = "mounted chem injector"
|
||||
interface_desc = "Dispenses loaded chemicals via an arm-mounted injector."
|
||||
|
||||
/obj/item/rig_module/voice
|
||||
|
||||
name = "hardsuit voice synthesiser"
|
||||
desc = "A speaker box and sound processor."
|
||||
usable = 1
|
||||
selectable = 0
|
||||
toggleable = 0
|
||||
disruptive = 0
|
||||
|
||||
engage_string = "Configure Synthesiser"
|
||||
|
||||
interface_name = "voice synthesiser"
|
||||
interface_desc = "A flexible and powerful voice modulator system."
|
||||
|
||||
var/obj/item/voice_changer/voice_holder
|
||||
|
||||
/obj/item/rig_module/voice/New()
|
||||
..()
|
||||
voice_holder = new(src)
|
||||
voice_holder.active = 0
|
||||
|
||||
/obj/item/rig_module/voice/installed()
|
||||
..()
|
||||
holder.speech = src
|
||||
|
||||
/obj/item/rig_module/voice/engage()
|
||||
|
||||
if(!..())
|
||||
return 0
|
||||
|
||||
var/choice= input("Would you like to toggle the synthesiser or set the name?") as null|anything in list("Enable","Disable","Set Name")
|
||||
|
||||
if(!choice)
|
||||
return 0
|
||||
|
||||
switch(choice)
|
||||
if("Enable")
|
||||
active = 1
|
||||
voice_holder.active = 1
|
||||
usr << "<font color='blue'>You enable the speech synthesiser.</font>"
|
||||
if("Disable")
|
||||
active = 0
|
||||
voice_holder.active = 0
|
||||
usr << "<font color='blue'>You disable the speech synthesiser.</font>"
|
||||
if("Set Name")
|
||||
var/raw_choice = input(usr, "Please enter a new name.") as text|null
|
||||
if(!raw_choice)
|
||||
return 0
|
||||
voice_holder.voice = sanitize(copytext(raw_choice,1,MAX_MESSAGE_LEN))
|
||||
usr << "<font color='blue'>You are now mimicking <B>[voice_holder.voice]</B>.</font>"
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/maneuvering_jets
|
||||
|
||||
name = "hardsuit maneuvering jets"
|
||||
desc = "A compact gas thruster system for a hardsuit."
|
||||
usable = 1
|
||||
toggleable = 1
|
||||
selectable = 0
|
||||
disruptive = 0
|
||||
|
||||
suit_overlay_active = "maneuvering_active"
|
||||
suit_overlay_inactive = null //"maneuvering_inactive"
|
||||
|
||||
engage_string = "Toggle Stabilizers"
|
||||
activate_string = "Activate Thrusters"
|
||||
deactivate_string = "Deactivate Thrusters"
|
||||
|
||||
interface_name = "maneuvering jets"
|
||||
interface_desc = "An inbuilt EVA maneuvering system that runs off the rig air supply."
|
||||
|
||||
var/obj/item/weapon/tank/jetpack/rig/jets
|
||||
|
||||
/obj/item/rig_module/maneuvering_jets/engage()
|
||||
if(!..())
|
||||
return 0
|
||||
jets.toggle_rockets()
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/maneuvering_jets/activate()
|
||||
|
||||
if(active)
|
||||
return 0
|
||||
|
||||
active = 1
|
||||
|
||||
spawn(1)
|
||||
if(suit_overlay_active)
|
||||
suit_overlay = suit_overlay_active
|
||||
else
|
||||
suit_overlay = null
|
||||
holder.update_icon()
|
||||
|
||||
if(!jets.on)
|
||||
jets.toggle()
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/maneuvering_jets/deactivate()
|
||||
if(!..())
|
||||
return 0
|
||||
if(jets.on)
|
||||
jets.toggle()
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/maneuvering_jets/New()
|
||||
..()
|
||||
jets = new(src)
|
||||
|
||||
/obj/item/rig_module/maneuvering_jets/installed()
|
||||
..()
|
||||
jets.holder = holder
|
||||
jets.ion_trail.set_up(holder)
|
||||
|
||||
/obj/item/rig_module/maneuvering_jets/removed()
|
||||
..()
|
||||
jets.holder = null
|
||||
jets.ion_trail.set_up(jets)
|
||||
|
||||
/obj/item/rig_module/foam_sprayer
|
||||
118
code/modules/clothing/spacesuits/rig/modules/vision.dm
Normal file
118
code/modules/clothing/spacesuits/rig/modules/vision.dm
Normal file
@@ -0,0 +1,118 @@
|
||||
/*
|
||||
* Contains
|
||||
* /obj/item/rig_module/vision
|
||||
* /obj/item/rig_module/vision/meson
|
||||
* /obj/item/rig_module/vision/thermal
|
||||
*/
|
||||
|
||||
/datum/rig_vision
|
||||
var/mode
|
||||
var/obj/item/clothing/glasses/glasses
|
||||
|
||||
/datum/rig_vision/nvg
|
||||
mode = "night vision"
|
||||
/datum/rig_vision/nvg/New()
|
||||
glasses = new /obj/item/clothing/glasses/night
|
||||
|
||||
/datum/rig_vision/thermal
|
||||
mode = "thermal scanner"
|
||||
/datum/rig_vision/thermal/New()
|
||||
glasses = new /obj/item/clothing/glasses/thermal
|
||||
|
||||
/datum/rig_vision/meson
|
||||
mode = "meson scanner"
|
||||
/datum/rig_vision/meson/New()
|
||||
glasses = new /obj/item/clothing/glasses/meson
|
||||
|
||||
/obj/item/rig_module/vision
|
||||
|
||||
name = "hardsuit visor"
|
||||
desc = "A layered, translucent visor system for a hardsuit."
|
||||
|
||||
interface_name = "optical scanners"
|
||||
interface_desc = "An integrated multi-mode vision system."
|
||||
|
||||
usable = 1
|
||||
toggleable = 1
|
||||
disruptive = 0
|
||||
|
||||
engage_string = "Cycle Visor Mode"
|
||||
activate_string = "Enable Visor"
|
||||
deactivate_string = "Disable Visor"
|
||||
|
||||
var/datum/rig_vision/vision
|
||||
var/list/vision_modes = list(
|
||||
/datum/rig_vision/nvg,
|
||||
/datum/rig_vision/thermal,
|
||||
/datum/rig_vision/meson
|
||||
)
|
||||
|
||||
var/vision_index
|
||||
|
||||
/obj/item/rig_module/vision/meson
|
||||
|
||||
name = "hardsuit meson scanner"
|
||||
desc = "A layered, translucent visor system for a hardsuit."
|
||||
|
||||
usable = 0
|
||||
|
||||
interface_name = "meson scanner"
|
||||
interface_desc = "An integrated meson scanner."
|
||||
|
||||
vision_modes = list(/datum/rig_vision/meson)
|
||||
|
||||
/obj/item/rig_module/vision/thermal
|
||||
|
||||
name = "hardsuit thermal scanner"
|
||||
desc = "A layered, translucent visor system for a hardsuit."
|
||||
|
||||
usable = 0
|
||||
|
||||
interface_name = "thermal scanner"
|
||||
interface_desc = "An integrated thermal scanner."
|
||||
|
||||
vision_modes = list(/datum/rig_vision/thermal)
|
||||
|
||||
// There should only ever be one vision module installed in a suit.
|
||||
/obj/item/rig_module/vision/installed()
|
||||
..()
|
||||
holder.visor = src
|
||||
|
||||
/obj/item/rig_module/vision/engage()
|
||||
|
||||
var/starting_up = !active
|
||||
|
||||
if(!..() || !vision_modes)
|
||||
return 0
|
||||
|
||||
// Don't cycle if this engage() is being called by activate().
|
||||
if(starting_up)
|
||||
holder.wearer << "<font color='blue'>You activate your visual sensors.</font>"
|
||||
return 1
|
||||
|
||||
if(vision_modes.len > 1)
|
||||
vision_index++
|
||||
if(vision_index > vision_modes.len)
|
||||
vision_index = 1
|
||||
vision = vision_modes[vision_index]
|
||||
|
||||
holder.wearer << "<font color='blue'>You cycle your sensors to <b>[vision.mode]</b> mode.</font>"
|
||||
else
|
||||
holder.wearer << "<font color='blue'>Your sensors only have one mode.</font>"
|
||||
return 1
|
||||
|
||||
/obj/item/rig_module/vision/New()
|
||||
..()
|
||||
|
||||
if(!vision_modes)
|
||||
return
|
||||
|
||||
vision_index = 1
|
||||
var/list/processed_vision = list()
|
||||
|
||||
for(var/vision_mode in vision_modes)
|
||||
var/datum/rig_vision/vision_datum = new vision_mode
|
||||
if(!vision) vision = vision_datum
|
||||
processed_vision += vision_datum
|
||||
|
||||
vision_modes = processed_vision
|
||||
726
code/modules/clothing/spacesuits/rig/rig.dm
Normal file
726
code/modules/clothing/spacesuits/rig/rig.dm
Normal file
@@ -0,0 +1,726 @@
|
||||
#define ONLY_DEPLOY 1
|
||||
#define ONLY_RETRACT 2
|
||||
#define SEAL_DELAY 30
|
||||
|
||||
/*
|
||||
* Defines the behavior of hardsuits/rigs/power armour.
|
||||
*/
|
||||
|
||||
/obj/item/weapon/rig
|
||||
|
||||
name = "hardsuit control module"
|
||||
icon = 'icons/obj/rig_modules.dmi'
|
||||
desc = "A back-mounted hardsuit deployment and control mechanism."
|
||||
slot_flags = SLOT_BACK
|
||||
req_one_access = null
|
||||
req_access = null
|
||||
w_class = 4
|
||||
|
||||
// These values are passed on to all component pieces.
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 20)
|
||||
min_cold_protection_temperature = SPACE_SUIT_MIN_COLD_PROTECTION_TEMPERATURE
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
siemens_coefficient = 0.1
|
||||
permeability_coefficient = 0.1
|
||||
unacidable = 1
|
||||
|
||||
var/interface_path = "hardsuit.tmpl"
|
||||
var/ai_interface_path = "hardsuit.tmpl"
|
||||
var/interface_title = "Hardsuit Controller"
|
||||
|
||||
// Keeps track of what this rig should spawn with.
|
||||
var/suit_type = "hardsuit"
|
||||
var/list/initial_modules
|
||||
var/chest_type = /obj/item/clothing/suit/space/rig
|
||||
var/helm_type = /obj/item/clothing/head/helmet/space/rig
|
||||
var/boot_type = /obj/item/clothing/shoes/magboots/rig
|
||||
var/glove_type = /obj/item/clothing/gloves/rig
|
||||
var/cell_type = /obj/item/weapon/cell/high
|
||||
var/air_type = /obj/item/weapon/tank/oxygen
|
||||
|
||||
//Component/device holders.
|
||||
var/obj/item/weapon/tank/air_supply // Air tank, if any.
|
||||
var/obj/item/clothing/shoes/boots = null // Deployable boots, if any.
|
||||
var/obj/item/clothing/suit/space/rig/chest // Deployable chestpiece, if any.
|
||||
var/obj/item/clothing/head/helmet/space/rig/helmet = null // Deployable helmet, if any.
|
||||
var/obj/item/clothing/gloves/rig/gloves = null // Deployable gauntlets, if any.
|
||||
var/obj/item/weapon/cell/cell // Power supply, if any.
|
||||
var/obj/item/rig_module/selected_module = null // Primary system (used with middle-click)
|
||||
var/obj/item/rig_module/vision/visor // Kinda shitty to have a var for a module, but saves time.
|
||||
var/obj/item/rig_module/voice/speech // As above.
|
||||
var/mob/living/carbon/human/wearer // The person currently wearing the rig.
|
||||
var/image/mob_icon // Holder for on-mob icon.
|
||||
var/list/installed_modules = list() // Power consumption/use bookkeeping.
|
||||
|
||||
// Rig status vars.
|
||||
var/open = 0 // Access panel status.
|
||||
var/locked = 1 // Lock status.
|
||||
var/subverted = 0
|
||||
var/interface_locked = 0
|
||||
var/control_overridden = 0
|
||||
var/ai_override_enabled = 0
|
||||
var/security_check_enabled = 1
|
||||
var/malfunctioning = 0
|
||||
var/malfunction_delay = 0
|
||||
var/electrified = 0
|
||||
var/locked_down = 0
|
||||
var/locked_dna = null
|
||||
|
||||
var/sealing // Keeps track of seal status independantly of canremove.
|
||||
var/offline = 1 // Should we be applying suit maluses?
|
||||
var/offline_slowdown = 10 // If the suit is deployed and unpowered, it sets slowdown to this.
|
||||
var/vision_restriction
|
||||
var/offline_vision_restriction = 1 // 0 - none, 1 - welder vision, 2 - blind. Maybe move this to helmets.
|
||||
|
||||
// Wiring! How exciting.
|
||||
var/datum/wires/rig/wires
|
||||
var/datum/effect/effect/system/spark_spread/spark_system
|
||||
|
||||
/obj/item/weapon/rig/examine()
|
||||
usr << "This is \icon[src][src.name]."
|
||||
usr << "[src.desc]"
|
||||
if(wearer)
|
||||
for(var/obj/item/piece in list(helmet,gloves,chest,boots))
|
||||
if(!piece || piece.loc != wearer)
|
||||
continue
|
||||
usr << "\icon[piece] \The [piece] [piece.gender == PLURAL ? "are" : "is"] deployed."
|
||||
|
||||
if(src.loc == usr)
|
||||
usr << "The maintenance panel is [open ? "open" : "closed"]."
|
||||
usr << "Hardsuit systems are [offline ? "<font color='red'>offline</font>" : "<font color='green'>online</green>"]."
|
||||
|
||||
/obj/item/weapon/rig/New()
|
||||
..()
|
||||
|
||||
item_state = icon_state
|
||||
wires = new(src)
|
||||
|
||||
if((!req_access || !req_access.len) && (!req_one_access || !req_one_access.len))
|
||||
locked = 0
|
||||
|
||||
spark_system = new()
|
||||
spark_system.set_up(5, 0, src)
|
||||
spark_system.attach(src)
|
||||
|
||||
processing_objects |= src
|
||||
|
||||
if(initial_modules && initial_modules.len)
|
||||
for(var/path in initial_modules)
|
||||
var/obj/item/rig_module/module = new path(src)
|
||||
installed_modules += module
|
||||
module.installed(src)
|
||||
|
||||
// Create and initialize our various segments.
|
||||
if(cell_type)
|
||||
cell = new cell_type(src)
|
||||
if(air_type)
|
||||
air_supply = new air_type(src)
|
||||
if(glove_type)
|
||||
gloves = new glove_type(src)
|
||||
verbs |= /obj/item/weapon/rig/proc/toggle_gauntlets
|
||||
if(helm_type)
|
||||
helmet = new helm_type(src)
|
||||
verbs |= /obj/item/weapon/rig/proc/toggle_helmet
|
||||
if(boot_type)
|
||||
boots = new boot_type(src)
|
||||
verbs |= /obj/item/weapon/rig/proc/toggle_boots
|
||||
if(chest_type)
|
||||
chest = new chest_type(src)
|
||||
if(allowed)
|
||||
chest.allowed = allowed
|
||||
chest.slowdown = offline_slowdown
|
||||
verbs |= /obj/item/weapon/rig/proc/toggle_chest
|
||||
|
||||
for(var/obj/item/piece in list(gloves,helmet,boots,chest))
|
||||
if(!piece)
|
||||
continue
|
||||
piece.canremove = 0
|
||||
piece.name = "[suit_type] [initial(piece.name)]"
|
||||
piece.desc = "It seems to be part of a [src.name]."
|
||||
piece.icon_state = "[initial(icon_state)]"
|
||||
piece.armor = armor
|
||||
piece.min_cold_protection_temperature = min_cold_protection_temperature
|
||||
piece.max_heat_protection_temperature = max_heat_protection_temperature
|
||||
piece.siemens_coefficient = siemens_coefficient
|
||||
piece.permeability_coefficient = permeability_coefficient
|
||||
piece.unacidable = unacidable
|
||||
|
||||
update_icon(1)
|
||||
|
||||
/obj/item/weapon/rig/Del()
|
||||
for(var/obj/item/piece in list(gloves,boots,helmet,chest))
|
||||
var/mob/living/M = piece.loc
|
||||
if(istype(M))
|
||||
M.drop_from_inventory(piece)
|
||||
del(piece)
|
||||
processing_objects -= src
|
||||
..()
|
||||
|
||||
/obj/item/weapon/rig/proc/suit_is_deployed()
|
||||
if(!istype(wearer) || src.loc != wearer || wearer.back != src)
|
||||
return 0
|
||||
if(helm_type && !(helmet && wearer.head == helmet))
|
||||
return 0
|
||||
if(glove_type && !(gloves && wearer.gloves == gloves))
|
||||
return 0
|
||||
if(boot_type && !(boots && wearer.shoes == boots))
|
||||
return 0
|
||||
if(chest_type && !(chest && wearer.wear_suit == chest))
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/rig/proc/reset()
|
||||
offline = 2
|
||||
canremove = 1
|
||||
for(var/obj/item/piece in list(helmet,boots,gloves,chest))
|
||||
if(!piece) continue
|
||||
piece.icon_state = "[initial(icon_state)]"
|
||||
piece.flags &= ~STOPSPRESSUREDMAGE
|
||||
piece.flags &= ~AIRTIGHT
|
||||
update_icon(1)
|
||||
|
||||
/obj/item/weapon/rig/proc/toggle_seals(var/mob/living/carbon/human/M,var/instant)
|
||||
|
||||
if(sealing) return
|
||||
|
||||
if(!check_power_cost(M))
|
||||
return 0
|
||||
|
||||
deploy(M,instant)
|
||||
|
||||
var/seal_target = !canremove
|
||||
var/failed_to_seal
|
||||
|
||||
canremove = 0 // No removing the suit while unsealing.
|
||||
sealing = 1
|
||||
|
||||
if(!seal_target && !suit_is_deployed())
|
||||
M.visible_message("<span class='danger'>[M]'s suit flashes an error light.</span>","<span class='danger'>Your suit flashes an error light. It can't function properly without being fully deployed.</span>")
|
||||
failed_to_seal = 1
|
||||
|
||||
if(!failed_to_seal)
|
||||
|
||||
if(!instant)
|
||||
M.visible_message("<font color='blue'>[M]'s suit emits a quiet hum as it begins to adjust its seals.</font>","<font color='blue'>With a quiet hum, the suit begins running checks and adjusting components.</font>")
|
||||
if(!do_after(M,SEAL_DELAY))
|
||||
if(M) M << "<span class='warning'>You must remain still while the suit is adjusting the components.</span>"
|
||||
failed_to_seal = 1
|
||||
|
||||
if(!M)
|
||||
failed_to_seal = 1
|
||||
else
|
||||
for(var/list/piece_data in list(list(M.shoes,boots,"boots",boot_type),list(M.gloves,gloves,"gloves",glove_type),list(M.head,helmet,"helmet",helm_type),list(M.wear_suit,chest,"chest",chest_type)))
|
||||
|
||||
var/obj/item/piece = piece_data[1]
|
||||
var/obj/item/compare_piece = piece_data[2]
|
||||
var/msg_type = piece_data[3]
|
||||
var/piece_type = piece_data[4]
|
||||
|
||||
if(!piece || !piece_type)
|
||||
continue
|
||||
|
||||
if(!istype(M) || !istype(piece) || !istype(compare_piece) || !msg_type)
|
||||
if(M) M << "<span class='warning'>You must remain still while the suit is adjusting the components.</span>"
|
||||
failed_to_seal = 1
|
||||
break
|
||||
|
||||
if(!failed_to_seal && M.back == src && piece == compare_piece)
|
||||
|
||||
if(!instant)
|
||||
if(!do_after(M,SEAL_DELAY))
|
||||
failed_to_seal = 1
|
||||
|
||||
piece.icon_state = "[initial(icon_state)][!seal_target ? "_sealed" : ""]"
|
||||
switch(msg_type)
|
||||
if("boots")
|
||||
M << "<font color='blue'>\The [piece] [!seal_target ? "seal around your feet" : "relax their grip on your legs"].</font>"
|
||||
M.update_inv_shoes()
|
||||
if("gloves")
|
||||
M << "<font color='blue'>\The [piece] [!seal_target ? "tighten around your fingers and wrists" : "become loose around your fingers"].</font>"
|
||||
M.update_inv_gloves()
|
||||
if("chest")
|
||||
M << "<font color='blue'>\The [piece] [!seal_target ? "cinches tight again your chest" : "releases your chest"].</font>"
|
||||
M.update_inv_wear_suit()
|
||||
if("helmet")
|
||||
M << "<font color='blue'>\The [piece] hisses [!seal_target ? "closed" : "open"].</font>"
|
||||
M.update_inv_head()
|
||||
if(helmet)
|
||||
if(!seal_target)
|
||||
if(flags & AIRTIGHT)
|
||||
helmet.flags |= AIRTIGHT
|
||||
else
|
||||
helmet.flags &= ~AIRTIGHT
|
||||
helmet.update_light(wearer)
|
||||
else
|
||||
failed_to_seal = 1
|
||||
|
||||
if((M && !(istype(M) && M.back == src) && !istype(M,/mob/living/silicon)) || (!seal_target && !suit_is_deployed()))
|
||||
failed_to_seal = 1
|
||||
|
||||
sealing = null
|
||||
|
||||
if(failed_to_seal)
|
||||
for(var/obj/item/piece in list(helmet,boots,gloves,chest))
|
||||
if(!piece) continue
|
||||
piece.icon_state = "[initial(icon_state)][!seal_target ? "" : "_sealed"]"
|
||||
canremove = !seal_target
|
||||
if(helmet)
|
||||
if(canremove)
|
||||
if(flags & AIRTIGHT)
|
||||
helmet.flags |= AIRTIGHT
|
||||
else
|
||||
if(flags & AIRTIGHT)
|
||||
helmet.flags &= ~AIRTIGHT
|
||||
update_icon(1)
|
||||
return 0
|
||||
|
||||
// Success!
|
||||
canremove = seal_target
|
||||
M << "<font color='blue'><b>Your entire suit [canremove ? "loosens as the components relax" : "tightens around you as the components lock into place"].</b></font>"
|
||||
|
||||
if(canremove)
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
module.deactivate()
|
||||
for(var/obj/item/piece in list(helmet,boots,gloves,chest))
|
||||
if(!piece) continue
|
||||
if(canremove)
|
||||
piece.flags &= ~STOPSPRESSUREDMAGE
|
||||
piece.flags &= ~AIRTIGHT
|
||||
else
|
||||
piece.flags |= STOPSPRESSUREDMAGE
|
||||
piece.flags |= AIRTIGHT
|
||||
update_icon(1)
|
||||
|
||||
/obj/item/weapon/rig/process()
|
||||
|
||||
// If we've lost any parts, grab them back.
|
||||
var/mob/living/M
|
||||
for(var/obj/item/piece in list(gloves,boots,helmet,chest))
|
||||
if(piece.loc != src && !(wearer && piece.loc == wearer))
|
||||
if(istype(piece.loc, /mob/living))
|
||||
M = piece.loc
|
||||
M.drop_from_inventory(piece)
|
||||
piece.loc = src
|
||||
|
||||
if(!istype(wearer) || loc != wearer || wearer.back != src || canremove || !cell || cell.charge <= 0)
|
||||
if(!cell || cell.charge <= 0)
|
||||
if(electrified >0)
|
||||
electrified = 0
|
||||
if(!offline)
|
||||
if(istype(wearer))
|
||||
if(!canremove)
|
||||
if (offline_slowdown < 3)
|
||||
wearer << "<span class='danger'>Your suit beeps stridently, and suddenly goes dead.</span>"
|
||||
else
|
||||
wearer << "<span class='danger'>Your suit beeps stridently, and suddenly you're wearing a leaden mass of metal and plastic instead of a powered suit.</span>"
|
||||
if(offline_vision_restriction == 1)
|
||||
wearer << "<span class='danger'>The suit optics flicker and die, leaving you with restricted vision.</span>"
|
||||
else if(offline_vision_restriction == 2)
|
||||
wearer << "<span class='danger'>The suit optics drop out completely, drowning you in darkness.</span>"
|
||||
if(!offline)
|
||||
offline = 1
|
||||
else
|
||||
if(offline)
|
||||
offline = 0
|
||||
chest.slowdown = initial(slowdown)
|
||||
|
||||
if(offline)
|
||||
if(offline == 1)
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
module.deactivate()
|
||||
offline = 2
|
||||
chest.slowdown = offline_slowdown
|
||||
return
|
||||
|
||||
if(cell && cell.charge > 0 && electrified > 0)
|
||||
electrified--
|
||||
|
||||
if(malfunction_delay > 0)
|
||||
malfunction_delay--
|
||||
else if(malfunctioning)
|
||||
malfunctioning--
|
||||
malfunction()
|
||||
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
cell.use(module.process()*10)
|
||||
|
||||
/obj/item/weapon/rig/proc/check_power_cost(var/mob/living/user, var/cost, var/use_unconcious, var/obj/item/rig_module/mod, var/user_is_ai)
|
||||
|
||||
if(!istype(user))
|
||||
return 0
|
||||
|
||||
var/fail_msg
|
||||
|
||||
if(!user_is_ai)
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(istype(H) && H.back != src)
|
||||
fail_msg = "<span class='warning'>You must be wearing \the [src] to do this.</span>"
|
||||
else if(user.incorporeal_move)
|
||||
fail_msg = "<span class='warning'>You must be solid to do this.</span>"
|
||||
if(sealing)
|
||||
fail_msg = "<span class='warning'>The hardsuit is in the process of adjusting seals and cannot be activated.</span>"
|
||||
else if(!fail_msg && ((use_unconcious && user.stat > 1) || (!use_unconcious && user.stat)))
|
||||
fail_msg = "<span class='warning'>You are in no fit state to do that."
|
||||
else if(!cell)
|
||||
fail_msg = "<span class='warning'>There is no cell installed in the suit.</span>"
|
||||
else if(cost && cell.charge < cost * 10) //TODO: Cellrate?
|
||||
fail_msg = "<span class='warning'>Not enough stored power.</span>"
|
||||
|
||||
if(fail_msg)
|
||||
user << "[fail_msg]"
|
||||
return 0
|
||||
|
||||
// This is largely for cancelling stealth and whatever.
|
||||
if(mod && mod.disruptive)
|
||||
for(var/obj/item/rig_module/module in (installed_modules - mod))
|
||||
if(module.active && module.disruptable)
|
||||
module.deactivate()
|
||||
|
||||
cell.use(cost*10)
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/rig/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
|
||||
if(!user)
|
||||
return
|
||||
|
||||
var/list/data = list()
|
||||
|
||||
if(selected_module)
|
||||
data["primarysystem"] = "[selected_module.interface_name]"
|
||||
|
||||
if(src.loc != user)
|
||||
data["ai"] = 1
|
||||
|
||||
data["seals"] = "[src.canremove]"
|
||||
data["sealing"] = "[src.sealing]"
|
||||
data["helmet"] = (helmet ? "[helmet.name]" : "None.")
|
||||
data["gauntlets"] = (gloves ? "[gloves.name]" : "None.")
|
||||
data["boots"] = (boots ? "[boots.name]" : "None.")
|
||||
data["chest"] = (chest ? "[chest.name]" : "None.")
|
||||
|
||||
data["charge"] = cell ? cell.charge : 0
|
||||
data["maxcharge"] = cell ? cell.maxcharge : 0
|
||||
data["chargestatus"] = cell ? Floor((cell.charge/cell.maxcharge)*50) : 0
|
||||
|
||||
data["emagged"] = subverted
|
||||
data["coverlock"] = locked
|
||||
data["interfacelock"] = interface_locked
|
||||
data["aicontrol"] = control_overridden
|
||||
data["aioverride"] = ai_override_enabled
|
||||
data["securitycheck"] = security_check_enabled
|
||||
data["malf"] = malfunctioning
|
||||
|
||||
|
||||
var/list/module_list = list()
|
||||
var/i = 1
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
var/list/module_data = list(
|
||||
"index" = i,
|
||||
"name" = "[module.interface_name]",
|
||||
"desc" = "[module.interface_desc]",
|
||||
"can_use" = "[module.usable]",
|
||||
"can_select" = "[module.selectable]",
|
||||
"can_toggle" = "[module.toggleable]",
|
||||
"is_active" = "[module.active]",
|
||||
"engagecost" = module.use_power_cost*10,
|
||||
"activecost" = module.active_power_cost*10,
|
||||
"passivecost" = module.passive_power_cost*10,
|
||||
"engagestring" = module.engage_string,
|
||||
"activatestring" = module.activate_string,
|
||||
"deactivatestring" = module.deactivate_string,
|
||||
"damage" = module.damage
|
||||
)
|
||||
|
||||
if(module.charges && module.charges.len)
|
||||
|
||||
module_data["charges"] = list()
|
||||
var/datum/rig_charge/selected = module.charges[module.charge_selected]
|
||||
module_data["chargetype"] = selected ? "[selected.display_name]" : "none"
|
||||
|
||||
for(var/chargetype in module.charges)
|
||||
var/datum/rig_charge/charge = module.charges[chargetype]
|
||||
module_data["charges"] += list(list("caption" = "[chargetype] ([charge.charges])", "index" = "[chargetype]"))
|
||||
|
||||
module_list += list(module_data)
|
||||
i++
|
||||
|
||||
if(module_list.len)
|
||||
data["modules"] = module_list
|
||||
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if (!ui)
|
||||
ui = new(user, src, ui_key, ((src.loc != user) ? ai_interface_path : interface_path), interface_title, 480, 550)
|
||||
ui.set_initial_data(data)
|
||||
ui.open()
|
||||
ui.set_auto_update(1)
|
||||
|
||||
/obj/item/weapon/rig/update_icon(var/update_mob_icon)
|
||||
|
||||
//TODO: Maybe consider a cache for this (use mob_icon as blank canvas, use suit icon overlay).
|
||||
overlays.Cut()
|
||||
if(!mob_icon || update_mob_icon)
|
||||
var/species_icon = 'icons/mob/rig_back.dmi'
|
||||
// Since setting mob_icon will override the species checks in
|
||||
// update_inv_wear_suit(), handle species checks here.
|
||||
if(wearer && sprite_sheets && sprite_sheets[wearer.species.name])
|
||||
species_icon = sprite_sheets[wearer.species.name]
|
||||
mob_icon = image("icon" = species_icon, "icon_state" = "[icon_state]")
|
||||
|
||||
if(installed_modules.len)
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
if(module.suit_overlay)
|
||||
chest.overlays += image("icon" = 'icons/mob/rig_modules.dmi', "icon_state" = "[module.suit_overlay]", "dir" = SOUTH)
|
||||
|
||||
if(wearer)
|
||||
wearer.update_inv_shoes()
|
||||
wearer.update_inv_gloves()
|
||||
wearer.update_inv_head()
|
||||
wearer.update_inv_wear_suit()
|
||||
wearer.update_inv_back()
|
||||
return
|
||||
|
||||
/obj/item/weapon/rig/proc/check_suit_access(var/mob/living/carbon/human/user)
|
||||
|
||||
if(!security_check_enabled)
|
||||
return 1
|
||||
|
||||
if(istype(user))
|
||||
if(user.back != src)
|
||||
return 0
|
||||
if(locked_dna)
|
||||
if(!user.dna || user.dna.unique_enzymes != locked_dna)
|
||||
user << "<span class='danger'>DNA scan mismatch. Access denied.</span>"
|
||||
return 0
|
||||
else if(!src.allowed(user))
|
||||
user << "<span class='danger'>Unauthorized user. Access denied.</span>"
|
||||
return 0
|
||||
|
||||
else if(!ai_override_enabled)
|
||||
user << "<span class='danger'>Synthetic access disabled. Please consult hardware provider.</span>"
|
||||
return 0
|
||||
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/rig/Topic(href,href_list)
|
||||
|
||||
if(!check_suit_access(usr))
|
||||
return
|
||||
|
||||
if(href_list["toggle_piece"])
|
||||
toggle_piece(href_list["toggle_piece"], usr)
|
||||
else if(href_list["toggle_seals"])
|
||||
toggle_seals(usr)
|
||||
else if(href_list["interact_module"])
|
||||
|
||||
var/module_index = text2num(href_list["interact_module"])
|
||||
|
||||
if(module_index > 0 && module_index <= installed_modules.len)
|
||||
var/obj/item/rig_module/module = installed_modules[module_index]
|
||||
switch(href_list["module_mode"])
|
||||
if("activate")
|
||||
module.activate()
|
||||
if("deactivate")
|
||||
module.deactivate()
|
||||
if("engage")
|
||||
module.engage()
|
||||
if("select")
|
||||
selected_module = module
|
||||
if("select_charge_type")
|
||||
module.charge_selected = href_list["charge_type"]
|
||||
else if(href_list["toggle_ai_control"])
|
||||
ai_override_enabled = !ai_override_enabled
|
||||
notify_ai("Synthetic suit control has been [ai_override_enabled ? "enabled" : "disabled"].")
|
||||
else if(href_list["toggle_suit_lock"])
|
||||
locked = !locked
|
||||
|
||||
usr.set_machine(src)
|
||||
src.add_fingerprint(usr)
|
||||
return
|
||||
|
||||
/obj/item/weapon/rig/proc/notify_ai(var/message)
|
||||
if(!message || !installed_modules || !installed_modules.len)
|
||||
return
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
for(var/mob/living/silicon/ai/ai in module.contents)
|
||||
if(ai && ai.client && !ai.stat)
|
||||
ai << "[message]"
|
||||
|
||||
/obj/item/weapon/rig/equipped(mob/living/carbon/human/M)
|
||||
..()
|
||||
|
||||
if(istype(M) && M.back == src)
|
||||
M.visible_message("<font color='blue'>[M] starts putting on \the [src]...</font>", "<font color='blue'>You start putting on \the [src]...</font>")
|
||||
|
||||
if(!do_after(M,SEAL_DELAY))
|
||||
if(M && M.back == src)
|
||||
M.back = null
|
||||
M.drop_from_inventory(src)
|
||||
src.loc = get_turf(src)
|
||||
return
|
||||
|
||||
if(istype(M) && M.back == src)
|
||||
M.visible_message("<font color='blue'><b>[M] struggles into \the [src].</b></font>", "<font color='blue'><b>You struggle into \the [src].</b></font>")
|
||||
wearer = M
|
||||
update_icon()
|
||||
|
||||
/obj/item/weapon/rig/proc/toggle_piece(var/piece, var/mob/living/carbon/human/H, var/deploy_mode)
|
||||
|
||||
if(sealing || !cell || !cell.charge)
|
||||
return
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
return
|
||||
|
||||
var/obj/item/check_slot
|
||||
var/equip_to
|
||||
var/obj/item/use_obj
|
||||
|
||||
if(!H)
|
||||
return
|
||||
|
||||
switch(piece)
|
||||
if("helmet")
|
||||
equip_to = slot_head
|
||||
use_obj = helmet
|
||||
check_slot = H.head
|
||||
if("gauntlets")
|
||||
equip_to = slot_gloves
|
||||
use_obj = gloves
|
||||
check_slot = H.gloves
|
||||
if("boots")
|
||||
equip_to = slot_shoes
|
||||
use_obj = boots
|
||||
check_slot = H.shoes
|
||||
if("chest")
|
||||
equip_to = slot_wear_suit
|
||||
use_obj = chest
|
||||
check_slot = H.wear_suit
|
||||
|
||||
if(use_obj)
|
||||
if(check_slot == use_obj && deploy_mode != ONLY_DEPLOY)
|
||||
|
||||
var/mob/living/carbon/human/holder
|
||||
|
||||
if(use_obj)
|
||||
holder = use_obj.loc
|
||||
if(istype(holder))
|
||||
if(use_obj && check_slot == use_obj)
|
||||
H << "<font color='blue'><b>Your [use_obj.name] [use_obj.gender == PLURAL ? "retract" : "retracts"] swiftly.</b></font>"
|
||||
use_obj.canremove = 1
|
||||
holder.drop_from_inventory(use_obj)
|
||||
use_obj.loc = get_turf(src)
|
||||
use_obj.dropped()
|
||||
use_obj.canremove = 0
|
||||
use_obj.loc = src
|
||||
|
||||
else if (deploy_mode != ONLY_RETRACT)
|
||||
if(check_slot)
|
||||
if(check_slot != use_obj)
|
||||
H << "<span class='danger'>You are unable to deploy \the [piece] as \the [check_slot] [check_slot.gender == PLURAL ? "are" : "is"] in the way.</span>"
|
||||
return
|
||||
else
|
||||
H << "<font color='blue'><b>Your [use_obj.name] [use_obj.gender == PLURAL ? "deploy" : "deploys"] swiftly.</b></span>"
|
||||
use_obj.loc = H
|
||||
H.equip_to_slot(use_obj, equip_to)
|
||||
|
||||
if(piece == "helmet" && helmet)
|
||||
helmet.update_light(H)
|
||||
|
||||
/obj/item/weapon/rig/proc/deploy(mob/M,var/sealed)
|
||||
|
||||
var/mob/living/carbon/human/H = M
|
||||
|
||||
if(!H || !istype(H)) return
|
||||
|
||||
if(H.back != src)
|
||||
return
|
||||
|
||||
if(sealed)
|
||||
if(H.head)
|
||||
var/obj/item/garbage = H.head
|
||||
H.drop_from_inventory(garbage)
|
||||
H.head = null
|
||||
del(garbage)
|
||||
|
||||
if(H.gloves)
|
||||
var/obj/item/garbage = H.gloves
|
||||
H.drop_from_inventory(garbage)
|
||||
H.gloves = null
|
||||
del(garbage)
|
||||
|
||||
if(H.shoes)
|
||||
var/obj/item/garbage = H.shoes
|
||||
H.drop_from_inventory(garbage)
|
||||
H.shoes = null
|
||||
del(garbage)
|
||||
|
||||
if(H.wear_suit)
|
||||
var/obj/item/garbage = H.wear_suit
|
||||
H.drop_from_inventory(garbage)
|
||||
H.wear_suit = null
|
||||
del(garbage)
|
||||
|
||||
for(var/piece in list("helmet","gauntlets","chest","boots"))
|
||||
toggle_piece(piece, H, ONLY_DEPLOY)
|
||||
|
||||
/obj/item/weapon/rig/dropped(var/mob/user)
|
||||
..()
|
||||
for(var/piece in list("helmet","gauntlets","chest","boots"))
|
||||
toggle_piece(piece, user, ONLY_RETRACT)
|
||||
wearer = null
|
||||
|
||||
//Todo
|
||||
/obj/item/weapon/rig/proc/malfunction()
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/rig/emp_act(severity)
|
||||
malfunctioning += severity*10
|
||||
if(malfunction_delay <= 0)
|
||||
malfunction_delay = 20
|
||||
take_hit(severity*10,"electrical pulse")
|
||||
|
||||
/obj/item/weapon/rig/proc/shock(mob/user)
|
||||
if (electrocute_mob(user, cell, src))
|
||||
spark_system.start()
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/rig/proc/take_hit(damage,source)
|
||||
|
||||
if(!installed_modules.len)
|
||||
return
|
||||
|
||||
if(!prob(max(0,(damage-(chest ? chest.breach_threshold : 0)))))
|
||||
return
|
||||
|
||||
var/list/valid_modules = list()
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
if(module.damage < 2)
|
||||
valid_modules |= module
|
||||
|
||||
if(!valid_modules.len)
|
||||
return
|
||||
|
||||
var/obj/item/rig_module/dam_module = pick(valid_modules)
|
||||
dam_module.damage++
|
||||
|
||||
if(!source)
|
||||
source = "hit"
|
||||
|
||||
if(wearer)
|
||||
wearer << "<span class='danger'>The [source] has [dam_module.damage >= 2 ? "destroyed" : "damaged"] your [dam_module.interface_name]!"
|
||||
dam_module.deactivate()
|
||||
|
||||
/*/obj/item/weapon/rig/proc/forced_move(dir)
|
||||
if(locked_down)
|
||||
return 0
|
||||
if(!control_overridden)
|
||||
return
|
||||
if(!wearer || wearer.back != src)
|
||||
return 0
|
||||
wearer.Move(null,dir)*/
|
||||
|
||||
#undef ONLY_DEPLOY
|
||||
#undef ONLY_RETRACT
|
||||
#undef SEAL_DELAY
|
||||
200
code/modules/clothing/spacesuits/rig/rig_attackby.dm
Normal file
200
code/modules/clothing/spacesuits/rig/rig_attackby.dm
Normal file
@@ -0,0 +1,200 @@
|
||||
/obj/item/weapon/rig/attackby(obj/item/W as obj, mob/user as mob)
|
||||
|
||||
if(!istype(user,/mob/living)) return 0
|
||||
|
||||
if(electrified != 0)
|
||||
if(cell && cell.charge >= 100)
|
||||
cell.use(100)
|
||||
if(shock(user, 100))
|
||||
return
|
||||
|
||||
// Pass repair items on to the chestpiece.
|
||||
if(chest && (istype(W,/obj/item/stack/sheet/mineral/plastic) || istype(W,/obj/item/stack/sheet/metal) || istype(W, /obj/item/weapon/weldingtool)))
|
||||
return chest.attackby(W,user)
|
||||
|
||||
// Lock or unlock the access panel.
|
||||
if(istype(W, /obj/item/weapon/card) || istype(W, /obj/item/device/pda))
|
||||
|
||||
if(subverted)
|
||||
locked = 0
|
||||
user << "<span class='danger'>It looks like the locking system has been shorted out.</span>"
|
||||
return
|
||||
else if(istype(W, /obj/item/weapon/card/emag))
|
||||
locked_dna = null
|
||||
req_access = null
|
||||
req_one_access = null
|
||||
locked = 0
|
||||
subverted = 1
|
||||
user << "<span class='danger'>You short out the access protocol for the suit.</span>"
|
||||
return
|
||||
|
||||
if((!req_access || !req_access.len) && (!req_one_access || !req_one_access.len))
|
||||
locked = 0
|
||||
user << "<span class='danger'>\The [src] doesn't seem to have a locking mechanism.</span>"
|
||||
return
|
||||
|
||||
if(security_check_enabled && !src.allowed(user))
|
||||
user << "<span class='danger'>Access denied.</span>"
|
||||
return
|
||||
|
||||
locked = !locked
|
||||
user << "You [locked ? "lock" : "unlock"] \the [src] access panel."
|
||||
return
|
||||
|
||||
else if(istype(W,/obj/item/weapon/crowbar))
|
||||
|
||||
if(!open && locked)
|
||||
user << "The access panel is locked shut."
|
||||
return
|
||||
|
||||
open = !open
|
||||
user << "You [open ? "open" : "close"] the access panel."
|
||||
return
|
||||
|
||||
if(open)
|
||||
|
||||
// Hacking.
|
||||
if(istype(W,/obj/item/weapon/wirecutters) || istype(W,/obj/item/device/multitool))
|
||||
if(open)
|
||||
wires.Interact(user)
|
||||
else
|
||||
user << "You can't reach the wiring."
|
||||
return
|
||||
// Air tank.
|
||||
if(istype(W,/obj/item/weapon/tank)) //Todo, some kind of check for suits without integrated air supplies.
|
||||
|
||||
if(air_supply)
|
||||
user << "\The [src] already has a tank installed."
|
||||
return
|
||||
|
||||
user.drop_from_inventory(W)
|
||||
air_supply = W
|
||||
W.loc = src
|
||||
user << "You slot [W] into [src] and tighten the connecting valve."
|
||||
return
|
||||
|
||||
// Check if this is a hardsuit upgrade or a modification.
|
||||
else if(istype(W,/obj/item/rig_module))
|
||||
|
||||
if(istype(src.loc,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = src.loc
|
||||
if(H.back == src)
|
||||
user << "<span class='danger'>You can't install a hardsuit module while the suit is being worn.</span>"
|
||||
return 1
|
||||
|
||||
if(!installed_modules) installed_modules = list()
|
||||
if(installed_modules.len)
|
||||
for(var/obj/item/rig_module/installed_mod in installed_modules)
|
||||
if(!installed_mod.redundant && istype(installed_mod,W))
|
||||
user << "The hardsuit already has a module of that class installed."
|
||||
return 1
|
||||
|
||||
var/obj/item/rig_module/mod = W
|
||||
user << "You begin installing \the [mod] into \the [src]."
|
||||
if(!do_after(user,40))
|
||||
return
|
||||
if(!user || !W)
|
||||
return
|
||||
user << "You install \the [mod] into \the [src]."
|
||||
user.drop_from_inventory(mod)
|
||||
installed_modules |= mod
|
||||
mod.loc = src
|
||||
mod.installed(src)
|
||||
update_icon()
|
||||
return 1
|
||||
|
||||
else if(!cell && istype(W,/obj/item/weapon/cell))
|
||||
|
||||
user << "You jack \the [W] into \the [src]'s battery mount."
|
||||
user.drop_from_inventory(W)
|
||||
W.loc = src
|
||||
src.cell = W
|
||||
return
|
||||
|
||||
else if(istype(W,/obj/item/weapon/wrench))
|
||||
|
||||
if(!air_supply)
|
||||
user << "There is not tank to remove."
|
||||
return
|
||||
|
||||
if(user.r_hand && user.l_hand)
|
||||
air_supply.loc = get_turf(user)
|
||||
else
|
||||
user.put_in_hands(air_supply)
|
||||
user << "You detach and remove \the [air_supply]."
|
||||
air_supply = null
|
||||
return
|
||||
|
||||
else if(istype(W,/obj/item/weapon/screwdriver))
|
||||
|
||||
var/list/current_mounts = list()
|
||||
if(cell) current_mounts += "cell"
|
||||
if(installed_modules && installed_modules.len) current_mounts += "system module"
|
||||
|
||||
var/to_remove = input("Which would you like to modify?") as null|anything in current_mounts
|
||||
if(!to_remove)
|
||||
return
|
||||
|
||||
if(istype(src.loc,/mob/living/carbon/human) && to_remove != "cell")
|
||||
var/mob/living/carbon/human/H = src.loc
|
||||
if(H.back == src)
|
||||
user << "You can't remove an installed device while the hardsuit is being worn."
|
||||
return
|
||||
|
||||
switch(to_remove)
|
||||
|
||||
if("cell")
|
||||
|
||||
if(cell)
|
||||
user << "You detatch \the [cell] from \the [src]'s battery mount."
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
module.deactivate()
|
||||
if(user.r_hand && user.l_hand)
|
||||
cell.loc = get_turf(user)
|
||||
else
|
||||
cell.loc = user.put_in_hands(cell)
|
||||
cell = null
|
||||
else
|
||||
user << "There is nothing loaded in that mount."
|
||||
|
||||
if("system module")
|
||||
|
||||
var/list/possible_removals = list()
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
if(module.permanent)
|
||||
continue
|
||||
possible_removals[module.name] = module
|
||||
|
||||
if(!possible_removals.len)
|
||||
user << "There are no installed modules to remove."
|
||||
return
|
||||
|
||||
var/removal_choice = input("Which module would you like to remove?") as null|anything in possible_removals
|
||||
if(!removal_choice)
|
||||
return
|
||||
|
||||
var/obj/item/rig_module/removed = possible_removals[removal_choice]
|
||||
user << "You detatch \the [removed] from \the [src]."
|
||||
removed.loc = get_turf(src)
|
||||
removed.removed()
|
||||
installed_modules -= removed
|
||||
update_icon()
|
||||
|
||||
return
|
||||
|
||||
// If we've gotten this far, all we have left to do before we pass off to root procs
|
||||
// is check if any of the loaded modules want to use the item we've been given.
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
if(module.accepts_item(W,user)) //Item is handled in this proc
|
||||
return
|
||||
..()
|
||||
|
||||
|
||||
/obj/item/weapon/rig/attack_hand(var/mob/user)
|
||||
|
||||
if(electrified != 0)
|
||||
if(cell && cell.charge >= 100)
|
||||
cell.use(100)
|
||||
if(shock(user, 100))
|
||||
return
|
||||
..()
|
||||
67
code/modules/clothing/spacesuits/rig/rig_pieces.dm
Normal file
67
code/modules/clothing/spacesuits/rig/rig_pieces.dm
Normal file
@@ -0,0 +1,67 @@
|
||||
/*
|
||||
* Defines the helmets, gloves and shoes for rigs.
|
||||
*/
|
||||
|
||||
/obj/item/clothing/head/helmet/space/rig
|
||||
name = "helmet"
|
||||
flags = FPRINT | TABLEPASS | HEADCOVERSEYES | BLOCKHAIR | HEADCOVERSMOUTH | THICKMATERIAL
|
||||
flags_inv = HIDEEARS|HIDEEYES|HIDEFACE
|
||||
body_parts_covered = HEAD|FACE|EYES
|
||||
heat_protection = HEAD|FACE|EYES
|
||||
cold_protection = HEAD|FACE|EYES
|
||||
brightness_on = 4
|
||||
species_restricted = null
|
||||
|
||||
/obj/item/clothing/gloves/rig
|
||||
name = "gauntlets"
|
||||
flags = FPRINT | TABLEPASS | THICKMATERIAL
|
||||
body_parts_covered = HANDS
|
||||
heat_protection = HANDS
|
||||
cold_protection = HANDS
|
||||
species_restricted = null
|
||||
gender = PLURAL
|
||||
|
||||
/obj/item/clothing/shoes/magboots/rig
|
||||
name = "boots"
|
||||
cold_protection = FEET
|
||||
heat_protection = FEET
|
||||
species_restricted = null
|
||||
gender = PLURAL
|
||||
icon_base = null
|
||||
|
||||
/obj/item/clothing/suit/space/rig
|
||||
name = "chestpiece"
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit)
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
|
||||
heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
|
||||
cold_protection = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
|
||||
flags_inv = HIDEJUMPSUIT|HIDETAIL
|
||||
flags = FPRINT | TABLEPASS | STOPSPRESSUREDMAGE | THICKMATERIAL | AIRTIGHT
|
||||
slowdown = 0
|
||||
breach_threshold = 35
|
||||
can_breach = 1
|
||||
supporting_limbs = list()
|
||||
|
||||
//TODO: move this to modules
|
||||
/obj/item/clothing/head/helmet/space/rig/proc/prevent_track()
|
||||
return 0
|
||||
|
||||
/obj/item/clothing/gloves/rig/Touch(var/atom/A, var/proximity)
|
||||
|
||||
if(!A || !proximity)
|
||||
return 0
|
||||
|
||||
var/mob/living/carbon/human/H = loc
|
||||
if(!istype(H) || !H.back)
|
||||
return 0
|
||||
|
||||
var/obj/item/weapon/rig/suit = H.back
|
||||
if(!suit || !istype(suit) || !suit.installed_modules.len)
|
||||
return 0
|
||||
|
||||
for(var/obj/item/rig_module/module in suit.installed_modules)
|
||||
if(module.active && module.activates_on_touch)
|
||||
if(module.engage(A))
|
||||
return 1
|
||||
|
||||
return 0
|
||||
280
code/modules/clothing/spacesuits/rig/rig_verbs.dm
Normal file
280
code/modules/clothing/spacesuits/rig/rig_verbs.dm
Normal file
@@ -0,0 +1,280 @@
|
||||
// Interface for humans.
|
||||
/obj/item/weapon/rig/verb/hardsuit_interface()
|
||||
|
||||
set name = "Open Hardsuit Interface"
|
||||
set desc = "Open the hardsuit system interface."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(wearer && wearer.back == src)
|
||||
ui_interact(usr)
|
||||
|
||||
/obj/item/weapon/rig/verb/toggle_vision()
|
||||
|
||||
set name = "Toggle Visor"
|
||||
set desc = "Turns your rig visor off or on."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
if(!check_power_cost(usr))
|
||||
return
|
||||
|
||||
if(canremove)
|
||||
usr << "<span class='warning'>The suit is not active.</span>"
|
||||
return
|
||||
|
||||
if(!check_suit_access(usr))
|
||||
return
|
||||
|
||||
if(!visor)
|
||||
usr << "<span class='warning'>The hardsuit does not have a configurable visor.</span>"
|
||||
return
|
||||
|
||||
if(!visor.active)
|
||||
visor.activate()
|
||||
else
|
||||
visor.deactivate()
|
||||
|
||||
/obj/item/weapon/rig/proc/toggle_helmet()
|
||||
|
||||
set name = "Toggle Helmet"
|
||||
set desc = "Deploys or retracts your helmet."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
if(!check_suit_access(usr))
|
||||
return
|
||||
|
||||
toggle_piece("helmet",wearer)
|
||||
|
||||
/obj/item/weapon/rig/proc/toggle_chest()
|
||||
|
||||
set name = "Toggle Chestpiece"
|
||||
set desc = "Deploys or retracts your chestpiece."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!check_suit_access(usr))
|
||||
return
|
||||
|
||||
toggle_piece("chest",wearer)
|
||||
|
||||
/obj/item/weapon/rig/proc/toggle_gauntlets()
|
||||
|
||||
set name = "Toggle Gauntlets"
|
||||
set desc = "Deploys or retracts your gauntlets."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
if(!check_suit_access(usr))
|
||||
return
|
||||
|
||||
toggle_piece("gauntlets",wearer)
|
||||
|
||||
/obj/item/weapon/rig/proc/toggle_boots()
|
||||
|
||||
set name = "Toggle Boots"
|
||||
set desc = "Deploys or retracts your boots."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
if(!check_suit_access(usr))
|
||||
return
|
||||
|
||||
toggle_piece("boots",wearer)
|
||||
|
||||
/obj/item/weapon/rig/verb/deploy_suit()
|
||||
|
||||
set name = "Deploy Hardsuit"
|
||||
set desc = "Deploys helmet, gloves and boots."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
if(!check_suit_access(usr))
|
||||
return
|
||||
|
||||
if(!check_power_cost(usr))
|
||||
return
|
||||
|
||||
deploy(wearer)
|
||||
|
||||
/obj/item/weapon/rig/verb/toggle_seals_verb()
|
||||
|
||||
set name = "Toggle Seals"
|
||||
set desc = "Activates or deactivates your rig seals."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
if(!check_suit_access(usr))
|
||||
return
|
||||
|
||||
toggle_seals(wearer)
|
||||
|
||||
/obj/item/weapon/rig/verb/switch_vision_mode()
|
||||
|
||||
set name = "Switch Vision Mode"
|
||||
set desc = "Switches between available vision modes."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!check_power_cost(usr, 0, 0, 0, 0))
|
||||
return
|
||||
|
||||
if(canremove)
|
||||
usr << "<span class='warning'>The suit is not active.</span>"
|
||||
return
|
||||
|
||||
if(!visor)
|
||||
usr << "<span class='warning'>The hardsuit does not have a configurable visor.</span>"
|
||||
return
|
||||
|
||||
if(!visor.active)
|
||||
visor.activate()
|
||||
|
||||
if(!visor.active)
|
||||
usr << "<span class='warning'>The visor is suffering a hardware fault and cannot be configured.</span>"
|
||||
return
|
||||
|
||||
visor.engage()
|
||||
|
||||
/obj/item/weapon/rig/verb/alter_voice()
|
||||
|
||||
set name = "Configure Voice Synthesiser"
|
||||
set desc = "Toggles or configures your voice synthesizer."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(canremove)
|
||||
usr << "<span class='warning'>The suit is not active.</span>"
|
||||
return
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
if(!speech)
|
||||
usr << "<span class='warning'>The hardsuit does not have a speech synthesiser.</span>"
|
||||
return
|
||||
|
||||
speech.engage()
|
||||
|
||||
/obj/item/weapon/rig/verb/select_module()
|
||||
|
||||
set name = "Select Module"
|
||||
set desc = "Selects a module as your primary system."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!check_power_cost(usr, 0, 0, 0, 0))
|
||||
return
|
||||
|
||||
if(canremove)
|
||||
usr << "<span class='warning'>The suit is not active.</span>"
|
||||
return
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
var/list/selectable = list()
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
if(module.selectable)
|
||||
selectable |= module
|
||||
|
||||
var/obj/item/rig_module/module = input("Which module do you wish to select?") as null|anything in selectable
|
||||
|
||||
if(!istype(module))
|
||||
return
|
||||
|
||||
selected_module = module
|
||||
usr << "<font color='blue'><b>Primary system is now: [selected_module.interface_name].</b></font>"
|
||||
|
||||
/obj/item/weapon/rig/verb/toggle_module()
|
||||
|
||||
set name = "Toggle Module"
|
||||
set desc = "Toggle a system module."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(!check_power_cost(usr, 0, 0, 0, 0))
|
||||
return
|
||||
|
||||
if(canremove)
|
||||
usr << "<span class='warning'>The suit is not active.</span>"
|
||||
return
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
var/list/selectable = list()
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
if(module.toggleable)
|
||||
selectable |= module
|
||||
|
||||
var/obj/item/rig_module/module = input("Which module do you wish to toggle?") as null|anything in selectable
|
||||
|
||||
if(!istype(module))
|
||||
return
|
||||
|
||||
if(module.active)
|
||||
usr << "<font color='blue'><b>You attempt to deactivate \the [module.interface_name].</b></font>"
|
||||
module.deactivate()
|
||||
else
|
||||
usr << "<font color='blue'><b>You attempt to activate \the [module.interface_name].</b></font>"
|
||||
module.activate()
|
||||
|
||||
/obj/item/weapon/rig/verb/engage_module()
|
||||
|
||||
set name = "Engage Module"
|
||||
set desc = "Engages a system module."
|
||||
set category = "Hardsuit"
|
||||
set src = usr.contents
|
||||
|
||||
if(canremove)
|
||||
usr << "<span class='warning'>The suit is not active.</span>"
|
||||
return
|
||||
|
||||
if(!istype(wearer) || !wearer.back == src)
|
||||
usr << "<span class='warning'>The hardsuit is not being worn.</span>"
|
||||
return
|
||||
|
||||
if(!check_power_cost(usr, 0, 0, 0, 0))
|
||||
return
|
||||
|
||||
var/list/selectable = list()
|
||||
for(var/obj/item/rig_module/module in installed_modules)
|
||||
if(module.usable)
|
||||
selectable |= module
|
||||
|
||||
var/obj/item/rig_module/module = input("Which module do you wish to engage?") as null|anything in selectable
|
||||
|
||||
if(!istype(module))
|
||||
return
|
||||
|
||||
usr << "<font color='blue'><b>You attempt to engage the [module.interface_name].</b></font>"
|
||||
module.engage()
|
||||
57
code/modules/clothing/spacesuits/rig/rig_wiring.dm
Normal file
57
code/modules/clothing/spacesuits/rig/rig_wiring.dm
Normal file
@@ -0,0 +1,57 @@
|
||||
/datum/wires/rig
|
||||
random = 1
|
||||
holder_type = /obj/item/weapon/rig
|
||||
wire_count = 5
|
||||
|
||||
#define RIG_SECURITY 1
|
||||
#define RIG_AI_OVERRIDE 2
|
||||
#define RIG_SYSTEM_CONTROL 4
|
||||
#define RIG_INTERFACE_LOCK 8
|
||||
#define RIG_INTERFACE_SHOCK 16
|
||||
/*
|
||||
* Rig security can be snipped to disable ID access checks on rig.
|
||||
* Rig AI override can be pulsed to toggle whether or not the AI can take control of the suit.
|
||||
* System control can be pulsed to toggle some malfunctions.
|
||||
* Interface lock can be pulsed to toggle whether or not the interface can be accessed.
|
||||
*/
|
||||
|
||||
/datum/wires/rig/UpdateCut(var/index, var/mended)
|
||||
|
||||
var/obj/item/weapon/rig/rig = holder
|
||||
switch(index)
|
||||
if(RIG_SECURITY)
|
||||
if(mended)
|
||||
rig.req_access = initial(rig.req_access)
|
||||
rig.req_one_access = initial(rig.req_one_access)
|
||||
if(RIG_INTERFACE_SHOCK)
|
||||
rig.electrified = mended ? 0 : -1
|
||||
rig.shock(usr,100)
|
||||
|
||||
/datum/wires/rig/UpdatePulsed(var/index)
|
||||
|
||||
var/obj/item/weapon/rig/rig = holder
|
||||
switch(index)
|
||||
if(RIG_SECURITY)
|
||||
rig.security_check_enabled = !rig.security_check_enabled
|
||||
rig.visible_message("\The [rig] twitches as several suit locks [rig.security_check_enabled?"close":"open"].")
|
||||
if(RIG_AI_OVERRIDE)
|
||||
rig.ai_override_enabled = !rig.ai_override_enabled
|
||||
rig.visible_message("A small red light on [rig] [rig.ai_override_enabled?"goes dead":"flickers on"].")
|
||||
if(RIG_SYSTEM_CONTROL)
|
||||
rig.malfunctioning += 10
|
||||
if(rig.malfunction_delay <= 0)
|
||||
rig.malfunction_delay = 20
|
||||
rig.shock(usr,100)
|
||||
if(RIG_INTERFACE_LOCK)
|
||||
rig.interface_locked = !rig.interface_locked
|
||||
rig.visible_message("\The [rig] clicks audibly as the software interface [rig.interface_locked?"darkens":"brightens"].")
|
||||
if(RIG_INTERFACE_SHOCK)
|
||||
if(rig.electrified != -1)
|
||||
rig.electrified = 30
|
||||
rig.shock(usr,100)
|
||||
|
||||
/datum/wires/rig/CanUse(var/mob/living/L)
|
||||
var/obj/item/weapon/rig/rig = holder
|
||||
if(rig.open)
|
||||
return 1
|
||||
return 0
|
||||
19
code/modules/clothing/spacesuits/rig/suits/alien.dm
Normal file
19
code/modules/clothing/spacesuits/rig/suits/alien.dm
Normal file
@@ -0,0 +1,19 @@
|
||||
/obj/item/weapon/rig/unathi
|
||||
name = "NT breacher chassis control module"
|
||||
desc = "A cheap NT knock-off of a Unathi battle-rig. Looks like a fish, moves like a fish, steers like a cow."
|
||||
suit_type = "NT breacher"
|
||||
icon_state = "breacher_rig_cheap"
|
||||
armor = list(melee = 60, bullet = 60, laser = 60, energy = 60, bomb = 70, bio = 100, rad = 50)
|
||||
slowdown = 6
|
||||
offline_slowdown = 10
|
||||
vision_restriction = 1
|
||||
offline_vision_restriction = 2
|
||||
|
||||
/obj/item/weapon/rig/unathi/fancy
|
||||
name = "breacher chassis control module"
|
||||
desc = "An authentic Unathi breacher chassis. Huge, bulky and absurdly heavy. It must be like wearing a tank."
|
||||
suit_type = "breacher chassis"
|
||||
icon_state = "breacher_rig"
|
||||
armor = list(melee = 90, bullet = 90, laser = 90, energy = 90, bomb = 90, bio = 100, rad = 80)
|
||||
vision_restriction = 0
|
||||
slowdown = 4
|
||||
25
code/modules/clothing/spacesuits/rig/suits/combat.dm
Normal file
25
code/modules/clothing/spacesuits/rig/suits/combat.dm
Normal file
@@ -0,0 +1,25 @@
|
||||
/obj/item/clothing/head/helmet/space/rig/combat
|
||||
light_overlay = "helmet_light_dual_green"
|
||||
|
||||
/obj/item/weapon/rig/combat
|
||||
name = "combat hardsuit control module"
|
||||
desc = "A sleek and dangerous hardsuit for active combat."
|
||||
icon_state = "security_rig"
|
||||
suit_type = "combat hardsuit"
|
||||
armor = list(melee = 80, bullet = 65, laser = 50, energy = 15, bomb = 80, bio = 100, rad = 60)
|
||||
slowdown = 1
|
||||
offline_slowdown = 3
|
||||
offline_vision_restriction = 1
|
||||
|
||||
helm_type = /obj/item/clothing/head/helmet/space/rig/combat
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/melee/baton)
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/mounted,
|
||||
/obj/item/rig_module/vision/thermal,
|
||||
/obj/item/rig_module/grenade_launcher,
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/power_sink,
|
||||
/obj/item/rig_module/electrowarfare_suite,
|
||||
/obj/item/rig_module/chem_dispenser/combat
|
||||
)
|
||||
66
code/modules/clothing/spacesuits/rig/suits/ert.dm
Normal file
66
code/modules/clothing/spacesuits/rig/suits/ert.dm
Normal file
@@ -0,0 +1,66 @@
|
||||
/obj/item/clothing/head/helmet/space/rig/ert
|
||||
light_overlay = "helmet_light_dual"
|
||||
camera_networks = list("ERT","SS13")
|
||||
|
||||
/obj/item/weapon/rig/ert
|
||||
name = "ERT-C hardsuit control module"
|
||||
desc = "A suit worn by the commander of a NanoTrasen Emergency Response Team. Has blue highlights. Armoured and space ready."
|
||||
suit_type = "ERT commander"
|
||||
icon_state = "ert_commander_rig"
|
||||
offline_slowdown = 3
|
||||
|
||||
helm_type = /obj/item/clothing/head/helmet/space/rig/ert
|
||||
|
||||
req_access = list(access_cent_specops)
|
||||
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 100, rad = 100)
|
||||
allowed = list(/obj/item/device/flashlight, /obj/item/weapon/tank, /obj/item/device/t_scanner, /obj/item/weapon/rcd, /obj/item/weapon/crowbar, \
|
||||
/obj/item/weapon/screwdriver, /obj/item/weapon/weldingtool, /obj/item/weapon/wirecutters, /obj/item/weapon/wrench, /obj/item/device/multitool, \
|
||||
/obj/item/device/radio, /obj/item/device/analyzer, /obj/item/weapon/gun/energy/laser, /obj/item/weapon/gun/energy/pulse_rifle, \
|
||||
/obj/item/weapon/gun/energy/taser, /obj/item/weapon/melee/baton, /obj/item/weapon/gun, /obj/item/weapon/storage/firstaid, /obj/item/weapon/reagent_containers/hypospray, /obj/item/roller)
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/maneuvering_jets,
|
||||
/obj/item/rig_module/datajack,
|
||||
/obj/item/rig_module/mounted
|
||||
)
|
||||
|
||||
/obj/item/weapon/rig/ert/engineer
|
||||
name = "ERT-E suit control module"
|
||||
desc = "A suit worn by the engineering division of a NanoTrasen Emergency Response Team. Has orange highlights. Armoured and space ready."
|
||||
suit_type = "ERT engineer"
|
||||
icon_state = "ert_engineer_rig"
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/maneuvering_jets,
|
||||
/obj/item/rig_module/device/plasmacutter,
|
||||
/obj/item/rig_module/device/rcd
|
||||
)
|
||||
|
||||
/obj/item/weapon/rig/ert/medical
|
||||
name = "ERT-M suit control module"
|
||||
desc = "A suit worn by the medical division of a NanoTrasen Emergency Response Team. Has white highlights. Armoured and space ready."
|
||||
suit_type = "ERT medic"
|
||||
icon_state = "ert_medical_rig"
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/maneuvering_jets,
|
||||
/obj/item/rig_module/device/healthscanner,
|
||||
/obj/item/rig_module/chem_dispenser/injector
|
||||
)
|
||||
|
||||
/obj/item/weapon/rig/ert/security
|
||||
name = "ERT-S suit control module"
|
||||
desc = "A suit worn by the security division of a NanoTrasen Emergency Response Team. Has red highlights. Armoured and space ready."
|
||||
suit_type = "ERT security"
|
||||
icon_state = "ert_security_rig"
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/maneuvering_jets,
|
||||
/obj/item/rig_module/grenade_launcher,
|
||||
/obj/item/rig_module/mounted
|
||||
)
|
||||
90
code/modules/clothing/spacesuits/rig/suits/light.dm
Normal file
90
code/modules/clothing/spacesuits/rig/suits/light.dm
Normal file
@@ -0,0 +1,90 @@
|
||||
// Light rigs are not space-capable, but don't suffer excessive slowdown or sight issues when depowered.
|
||||
/obj/item/weapon/rig/light
|
||||
name = "light suit control module"
|
||||
desc = "A lighter, less armoured rig suit."
|
||||
icon_state = "ninja_rig"
|
||||
suit_type = "light suit"
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/handcuffs,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/cell)
|
||||
armor = list(melee = 50, bullet = 15, laser = 50, energy = 10, bomb = 25, bio = 0, rad = 0)
|
||||
slowdown = 0
|
||||
flags = FPRINT | TABLEPASS | STOPSPRESSUREDMAGE | THICKMATERIAL
|
||||
offline_slowdown = 0
|
||||
offline_vision_restriction = 0
|
||||
|
||||
chest_type = /obj/item/clothing/suit/space/rig/light
|
||||
helm_type = /obj/item/clothing/head/helmet/space/rig/light
|
||||
boot_type = /obj/item/clothing/shoes/magboots/rig/light
|
||||
glove_type = /obj/item/clothing/gloves/rig/light
|
||||
|
||||
/obj/item/clothing/suit/space/rig/light
|
||||
name = "suit"
|
||||
|
||||
/obj/item/clothing/gloves/rig/light
|
||||
name = "gloves"
|
||||
|
||||
/obj/item/clothing/shoes/magboots/rig/light
|
||||
name = "shoes"
|
||||
|
||||
/obj/item/clothing/head/helmet/space/rig/light
|
||||
name = "hood"
|
||||
|
||||
/obj/item/weapon/rig/light/hacker
|
||||
name = "cybersuit control module"
|
||||
suit_type = "cyber"
|
||||
desc = "An advanced powered armour suit with many cyberwarfare enhancements."
|
||||
icon_state = "hacker_rig"
|
||||
|
||||
req_access = list(access_syndicate)
|
||||
|
||||
helm_type = /obj/item/clothing/head/helmet/space/rig/mask
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/power_sink,
|
||||
/obj/item/rig_module/datajack
|
||||
)
|
||||
|
||||
/obj/item/clothing/head/helmet/space/rig/mask
|
||||
name = "mask"
|
||||
flags = FPRINT | TABLEPASS | THICKMATERIAL
|
||||
|
||||
/obj/item/weapon/rig/light/ninja
|
||||
name = "ominous suit control module"
|
||||
suit_type = "ominous"
|
||||
desc = "A unique, vaccum-proof suit of nano-enhanced armor designed specifically for Spider Clan assassins."
|
||||
icon_state = "ninja_rig"
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
|
||||
slowdown = 0
|
||||
|
||||
req_access = list(access_syndicate)
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/teleporter,
|
||||
/obj/item/rig_module/stealth_field,
|
||||
/obj/item/rig_module/mounted/energy_blade,
|
||||
/obj/item/rig_module/vision,
|
||||
/obj/item/rig_module/voice,
|
||||
/obj/item/rig_module/fabricator/energy_net,
|
||||
/obj/item/rig_module/chem_dispenser,
|
||||
/obj/item/rig_module/grenade_launcher,
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/power_sink,
|
||||
/obj/item/rig_module/datajack,
|
||||
/obj/item/rig_module/self_destruct
|
||||
)
|
||||
|
||||
..()
|
||||
|
||||
/obj/item/weapon/rig/light/stealth
|
||||
name = "stealth suit control module"
|
||||
suit_type = "stealth"
|
||||
desc = "A highly advanced and expensive suit designed for covert operations."
|
||||
icon_state = "ninja_rig"
|
||||
|
||||
req_access = list(access_syndicate)
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/teleporter,
|
||||
/obj/item/rig_module/stealth_field,
|
||||
/obj/item/rig_module/vision
|
||||
)
|
||||
27
code/modules/clothing/spacesuits/rig/suits/merc.dm
Normal file
27
code/modules/clothing/spacesuits/rig/suits/merc.dm
Normal file
@@ -0,0 +1,27 @@
|
||||
/obj/item/clothing/head/helmet/space/rig/merc
|
||||
light_overlay = "helmet_light_dual_green"
|
||||
camera_networks = list("NUKE")
|
||||
|
||||
/obj/item/weapon/rig/merc
|
||||
name = "crimson hardsuit control module"
|
||||
desc = "A blood-red hardsuit featuring some fairly illegal technology."
|
||||
icon_state = "merc_rig"
|
||||
suit_type = "crimson hardsuit"
|
||||
armor = list(melee = 80, bullet = 65, laser = 50, energy = 15, bomb = 80, bio = 100, rad = 60)
|
||||
slowdown = 1
|
||||
offline_slowdown = 3
|
||||
offline_vision_restriction = 1
|
||||
|
||||
helm_type = /obj/item/clothing/head/helmet/space/rig/merc
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/melee/energy/sword,/obj/item/weapon/handcuffs)
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/mounted,
|
||||
/obj/item/rig_module/vision/thermal,
|
||||
/obj/item/rig_module/grenade_launcher,
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/power_sink,
|
||||
/obj/item/rig_module/electrowarfare_suite,
|
||||
/obj/item/rig_module/chem_dispenser/combat,
|
||||
/obj/item/rig_module/fabricator/energy_net
|
||||
)
|
||||
112
code/modules/clothing/spacesuits/rig/suits/station.dm
Normal file
112
code/modules/clothing/spacesuits/rig/suits/station.dm
Normal file
@@ -0,0 +1,112 @@
|
||||
/obj/item/weapon/rig/industrial
|
||||
name = "industrial suit control module"
|
||||
suit_type = "industrial hardsuit"
|
||||
desc = "A heavy, powerful rig used by construction crews and mining corporations."
|
||||
icon_state = "engineering_rig"
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
|
||||
slowdown = 3
|
||||
offline_slowdown = 10
|
||||
offline_vision_restriction = 2
|
||||
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/storage/bag/ore,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/weapon/rcd)
|
||||
|
||||
req_access = null
|
||||
req_one_access = null
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/device/plasmacutter,
|
||||
/obj/item/rig_module/device/drill,
|
||||
/obj/item/rig_module/device/orescanner,
|
||||
/obj/item/rig_module/device/rcd,
|
||||
/obj/item/rig_module/vision/meson
|
||||
)
|
||||
|
||||
//Chief Engineer's rig. This is sort of a halfway point between the old hardsuits (voidsuits) and the rig class.
|
||||
/obj/item/weapon/rig/ce
|
||||
|
||||
name = "advanced voidsuit control module"
|
||||
suit_type = "advanced voidsuit"
|
||||
desc = "An advanced voidsuit that protects against hazardous, low pressure environments. Shines with a high polish."
|
||||
icon_state = "ce_rig"
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
|
||||
slowdown = 0
|
||||
offline_slowdown = 0
|
||||
offline_vision_restriction = 0
|
||||
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/storage/bag/ore,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/weapon/rcd)
|
||||
|
||||
req_access = list(access_ce)
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/maneuvering_jets,
|
||||
/obj/item/rig_module/device/plasmacutter,
|
||||
/obj/item/rig_module/device/rcd,
|
||||
/obj/item/rig_module/vision/meson
|
||||
)
|
||||
|
||||
boot_type = null
|
||||
glove_type = null
|
||||
|
||||
/obj/item/weapon/rig/hazmat
|
||||
|
||||
name = "AMI control module"
|
||||
suit_type = "hazmat hardsuit"
|
||||
desc = "An Anomalous Material Interaction hardsuit that protects against the strangest energies the universe can throw at it."
|
||||
icon_state = "science_rig"
|
||||
armor = list(melee = 15, bullet = 15, laser = 80, energy = 80, bomb = 60, bio = 100, rad = 100)
|
||||
slowdown = 1
|
||||
offline_slowdown = 3
|
||||
offline_vision_restriction = 1
|
||||
|
||||
helm_type = /obj/item/clothing/head/helmet/space/rig/ert
|
||||
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/stack/flag,/obj/item/weapon/storage/box/excavation,/obj/item/weapon/pickaxe,/obj/item/device/healthanalyzer,/obj/item/device/measuring_tape,/obj/item/device/ano_scanner,/obj/item/device/depth_scanner,/obj/item/device/core_sampler,/obj/item/device/gps,/obj/item/device/beacon_locator,/obj/item/device/radio/beacon,/obj/item/weapon/pickaxe/hand,/obj/item/weapon/storage/bag/fossils)
|
||||
|
||||
req_access = list(access_rd)
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/ai_container,
|
||||
/obj/item/rig_module/maneuvering_jets,
|
||||
/obj/item/rig_module/device/anomaly_scanner
|
||||
)
|
||||
|
||||
/obj/item/weapon/rig/medical
|
||||
|
||||
name = "rescue suit control module"
|
||||
suit_type = "rescue hardsuit"
|
||||
desc = "A durable suit designed for medical rescue in high risk areas."
|
||||
icon_state = "medical_rig"
|
||||
armor = list(melee = 30, bullet = 15, laser = 20, energy = 60, bomb = 30, bio = 100, rad = 100)
|
||||
slowdown = 1
|
||||
offline_slowdown = 3
|
||||
offline_vision_restriction = 1
|
||||
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/storage/firstaid,/obj/item/device/healthanalyzer,/obj/item/stack/medical,/obj/item/roller )
|
||||
|
||||
req_access = null
|
||||
req_one_access = null
|
||||
|
||||
initial_modules = list(
|
||||
/obj/item/rig_module/chem_dispenser/injector,
|
||||
/obj/item/rig_module/maneuvering_jets,
|
||||
/obj/item/rig_module/device/healthscanner
|
||||
)
|
||||
|
||||
/obj/item/weapon/rig/hazard
|
||||
name = "hazard hardsuit control module"
|
||||
suit_type = "hazard hardsuit"
|
||||
desc = "A Nanotrasen security hardsuit designed for prolonged EVA in dangerous environments. The name HARPER is printed on the control unit."
|
||||
icon_state = "hazard_rig"
|
||||
armor = list(melee = 60, bullet = 10, laser = 30, energy = 5, bomb = 45, bio = 100, rad = 10)
|
||||
slowdown = 1
|
||||
offline_slowdown = 3
|
||||
offline_vision_restriction = 1
|
||||
|
||||
helm_type = /obj/item/clothing/head/helmet/space/rig/ert
|
||||
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/melee/baton)
|
||||
|
||||
req_access = null
|
||||
req_one_access = null
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
//Spacesuit
|
||||
//Note: Everything in modules/clothing/spacesuits should have the entire suit grouped together.
|
||||
// Meaning the the suit is defined directly after the corrisponding helmet. Just like below!
|
||||
|
||||
/obj/item/clothing/head/helmet/space
|
||||
name = "Space helmet"
|
||||
icon_state = "space"
|
||||
desc = "A special helmet designed for work in a hazardous, low-pressure environment."
|
||||
flags = FPRINT | TABLEPASS | HEADCOVERSEYES | BLOCKHAIR | HEADCOVERSMOUTH | STOPSPRESSUREDMAGE | THICKMATERIAL
|
||||
flags = FPRINT | TABLEPASS | HEADCOVERSEYES | BLOCKHAIR | HEADCOVERSMOUTH | STOPSPRESSUREDMAGE | THICKMATERIAL | AIRTIGHT
|
||||
item_state = "space"
|
||||
permeability_coefficient = 0.01
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 50)
|
||||
@@ -14,7 +15,35 @@
|
||||
cold_protection = HEAD
|
||||
min_cold_protection_temperature = SPACE_HELMET_MIN_COLD_PROTECTION_TEMPERATURE
|
||||
siemens_coefficient = 0.9
|
||||
species_restricted = list("exclude","Diona","Vox")
|
||||
species_restricted = list("exclude","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
|
||||
var/obj/machinery/camera/camera
|
||||
var/list/camera_networks
|
||||
|
||||
light_overlay = "helmet_light"
|
||||
brightness_on = 4
|
||||
on = 0
|
||||
|
||||
/obj/item/clothing/head/helmet/space/attack_self(mob/user)
|
||||
|
||||
if(!camera && camera_networks)
|
||||
|
||||
if(!icon_action_button)
|
||||
icon_action_button = "[icon_state]"
|
||||
|
||||
camera = new /obj/machinery/camera(src)
|
||||
camera.network = camera_networks
|
||||
cameranet.removeCamera(camera)
|
||||
camera.c_tag = user.name
|
||||
user << "\blue User scanned as [camera.c_tag]. Camera activated."
|
||||
return 1
|
||||
|
||||
..()
|
||||
|
||||
/obj/item/clothing/head/helmet/space/examine()
|
||||
..()
|
||||
if(camera_networks && get_dist(usr,src) <= 1)
|
||||
usr << "This helmet has a built-in camera. It's [camera ? "" : "in"]active."
|
||||
|
||||
/obj/item/clothing/suit/space
|
||||
name = "Space suit"
|
||||
@@ -33,7 +62,7 @@
|
||||
cold_protection = UPPER_TORSO | LOWER_TORSO | LEGS | FEET | ARMS | HANDS
|
||||
min_cold_protection_temperature = SPACE_SUIT_MIN_COLD_PROTECTION_TEMPERATURE
|
||||
siemens_coefficient = 0.9
|
||||
species_restricted = list("exclude","Diona","Vox")
|
||||
species_restricted = list("exclude","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
|
||||
var/list/supporting_limbs //If not-null, automatically splints breaks. Checked when removing the suit.
|
||||
|
||||
@@ -41,27 +70,25 @@
|
||||
check_limb_support()
|
||||
..()
|
||||
|
||||
/obj/item/clothing/suit/space/dropped()
|
||||
check_limb_support()
|
||||
/obj/item/clothing/suit/space/dropped(var/mob/user)
|
||||
check_limb_support(user)
|
||||
..()
|
||||
|
||||
// Some space suits are equipped with reactive membranes that support
|
||||
// broken limbs - at the time of writing, only the ninja suit, but
|
||||
// I can see it being useful for other suits as we expand them. ~ Z
|
||||
// The actual splinting occurs in /datum/organ/external/proc/fracture()
|
||||
/obj/item/clothing/suit/space/proc/check_limb_support()
|
||||
/obj/item/clothing/suit/space/proc/check_limb_support(var/mob/living/carbon/human/user)
|
||||
|
||||
// If this isn't set, then we don't need to care.
|
||||
if(!supporting_limbs || !supporting_limbs.len)
|
||||
return
|
||||
|
||||
var/mob/living/carbon/human/H = src.loc
|
||||
|
||||
// If the holder isn't human, or the holder IS and is wearing the suit, it keeps supporting the limbs.
|
||||
if(!istype(H) || H.wear_suit == src)
|
||||
if(!istype(user) || user.wear_suit == src)
|
||||
return
|
||||
|
||||
// Otherwise, remove the splints.
|
||||
for(var/datum/organ/external/E in supporting_limbs)
|
||||
E.status &= ~ ORGAN_SPLINTED
|
||||
user << "The suit stops supporting your [E.display_name]."
|
||||
supporting_limbs = list()
|
||||
@@ -1,10 +1,9 @@
|
||||
//Regular syndicate space suit
|
||||
/obj/item/clothing/head/helmet/space/syndicate
|
||||
name = "red space helmet"
|
||||
desc = "Top secret Spess Helmet."
|
||||
icon_state = "syndicate"
|
||||
item_state = "syndicate"
|
||||
desc = "Has a tag: Totally not property of an enemy corporation, honest."
|
||||
item_state = "space_helmet_syndicate"
|
||||
desc = "A crimson helmet sporting clean lines and durable plating. Engineered to look menacing."
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
|
||||
siemens_coefficient = 0.6
|
||||
|
||||
@@ -12,7 +11,7 @@
|
||||
name = "red space suit"
|
||||
icon_state = "syndicate"
|
||||
item_state = "space_suit_syndicate"
|
||||
desc = "Has a tag on it: Totally not property of of a hostile corporation, honest!"
|
||||
desc = "A crimson spacesuit sporting clean lines and durable plating. Robust, reliable, and slightly suspicious."
|
||||
w_class = 3
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/melee/energy/sword,/obj/item/weapon/handcuffs,/obj/item/weapon/tank/emergency_oxygen)
|
||||
slowdown = 1
|
||||
@@ -139,7 +138,6 @@
|
||||
icon_state = "syndicate-black-red"
|
||||
item_state = "syndicate-black-red"
|
||||
|
||||
|
||||
//Black with yellow/red engineering syndicate space suit
|
||||
/obj/item/clothing/head/helmet/space/syndicate/black/engie
|
||||
name = "Black Space Helmet"
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
|
||||
//NASA Voidsuit
|
||||
/obj/item/clothing/head/helmet/space/nasavoid
|
||||
name = "NASA Void Helmet"
|
||||
desc = "A high tech, NASA Centcom branch designed, dark red space suit helmet. Used for AI satellite maintenance."
|
||||
icon_state = "void"
|
||||
item_state = "void"
|
||||
|
||||
/obj/item/clothing/suit/space/nasavoid
|
||||
name = "NASA Voidsuit"
|
||||
icon_state = "void"
|
||||
item_state = "void"
|
||||
desc = "A high tech, NASA Centcom branch designed, dark red Space suit. Used for AI satellite maintenance."
|
||||
slowdown = 1
|
||||
24
code/modules/clothing/spacesuits/void/merc.dm
Normal file
24
code/modules/clothing/spacesuits/void/merc.dm
Normal file
@@ -0,0 +1,24 @@
|
||||
//Syndicate rig
|
||||
/obj/item/clothing/head/helmet/space/void/merc
|
||||
name = "blood-red voidsuit helmet"
|
||||
desc = "An advanced helmet designed for work in special operations. Property of Gorlex Marauders."
|
||||
icon_state = "rig0-syndie"
|
||||
item_state = "syndie_helm"
|
||||
item_color = "syndie"
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 35, bio = 100, rad = 60)
|
||||
siemens_coefficient = 0.6
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
camera_networks = list("NUKE")
|
||||
light_overlay = "helmet_light_green" //todo: species-specific light overlays
|
||||
|
||||
/obj/item/clothing/suit/space/void/merc
|
||||
icon_state = "rig-syndie"
|
||||
name = "blood-red voidsuit"
|
||||
desc = "An advanced suit that protects against injuries during special operations. Property of Gorlex Marauders."
|
||||
item_state = "syndie_voidsuit"
|
||||
slowdown = 1
|
||||
w_class = 3
|
||||
armor = list(melee = 60, bullet = 50, laser = 30, energy = 15, bomb = 35, bio = 100, rad = 60)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/melee/energy/sword,/obj/item/weapon/handcuffs)
|
||||
siemens_coefficient = 0.6
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
90
code/modules/clothing/spacesuits/void/station.dm
Normal file
90
code/modules/clothing/spacesuits/void/station.dm
Normal file
@@ -0,0 +1,90 @@
|
||||
// Station voidsuits
|
||||
//Engineering rig
|
||||
/obj/item/clothing/head/helmet/space/void/engineering
|
||||
name = "engineering voidsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low-pressure environment. Has radiation shielding."
|
||||
icon_state = "rig0-engineering"
|
||||
item_state = "eng_helm"
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 80)
|
||||
|
||||
/obj/item/clothing/suit/space/void/engineering
|
||||
name = "engineering voidsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has radiation shielding."
|
||||
icon_state = "rig-engineering"
|
||||
item_state = "eng_voidsuit"
|
||||
slowdown = 1
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 80)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/storage/bag/ore,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/weapon/rcd)
|
||||
|
||||
//Mining rig
|
||||
/obj/item/clothing/head/helmet/space/void/mining
|
||||
name = "mining voidsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low pressure environment. Has reinforced plating."
|
||||
icon_state = "rig0-mining"
|
||||
item_state = "mining_helm"
|
||||
item_color = "mining"
|
||||
armor = list(melee = 50, bullet = 5, laser = 20,energy = 5, bomb = 55, bio = 100, rad = 20)
|
||||
light_overlay = "helmet_light_dual"
|
||||
|
||||
/obj/item/clothing/suit/space/void/mining
|
||||
icon_state = "rig-mining"
|
||||
name = "mining voidsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has reinforced plating."
|
||||
item_state = "mining_voidsuit"
|
||||
armor = list(melee = 50, bullet = 5, laser = 20,energy = 5, bomb = 55, bio = 100, rad = 20)
|
||||
|
||||
//Medical Rig
|
||||
/obj/item/clothing/head/helmet/space/void/medical
|
||||
name = "medical voidsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low pressure environment. Has minor radiation shielding."
|
||||
icon_state = "rig0-medical"
|
||||
item_state = "medical_helm"
|
||||
item_color = "medical"
|
||||
armor = list(melee = 30, bullet = 5, laser = 20,energy = 5, bomb = 25, bio = 100, rad = 50)
|
||||
|
||||
/obj/item/clothing/suit/space/void/medical
|
||||
icon_state = "rig-medical"
|
||||
name = "medical voidsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has minor radiation shielding."
|
||||
item_state = "medical_voidsuit"
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/storage/firstaid,/obj/item/device/healthanalyzer,/obj/item/stack/medical)
|
||||
armor = list(melee = 30, bullet = 5, laser = 20,energy = 5, bomb = 25, bio = 100, rad = 50)
|
||||
|
||||
//Security
|
||||
/obj/item/clothing/head/helmet/space/void/security
|
||||
name = "security voidsuit helmet"
|
||||
desc = "A special helmet designed for work in a hazardous, low pressure environment. Has an additional layer of armor."
|
||||
icon_state = "rig0-sec"
|
||||
item_state = "sec_helm"
|
||||
item_color = "sec"
|
||||
armor = list(melee = 60, bullet = 10, laser = 30, energy = 5, bomb = 45, bio = 100, rad = 10)
|
||||
siemens_coefficient = 0.7
|
||||
light_overlay = "helmet_light_dual"
|
||||
|
||||
/obj/item/clothing/suit/space/void/security
|
||||
icon_state = "rig-sec"
|
||||
name = "security voidsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has an additional layer of armor."
|
||||
item_state = "sec_voidsuit"
|
||||
armor = list(melee = 60, bullet = 10, laser = 30, energy = 5, bomb = 45, bio = 100, rad = 10)
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit,/obj/item/weapon/melee/baton)
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
//Atmospherics Rig (BS12)
|
||||
/obj/item/clothing/head/helmet/space/void/atmos
|
||||
desc = "A special helmet designed for work in a hazardous, low pressure environments. Has improved thermal protection and minor radiation shielding."
|
||||
name = "atmospherics voidsuit helmet"
|
||||
icon_state = "rig0-atmos"
|
||||
item_state = "atmos_helm"
|
||||
item_color = "atmos"
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 50)
|
||||
max_heat_protection_temperature = FIRE_HELMET_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
light_overlay = "helmet_light_dual"
|
||||
|
||||
/obj/item/clothing/suit/space/void/atmos
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Has improved thermal protection and minor radiation shielding."
|
||||
icon_state = "rig-atmos"
|
||||
name = "atmos voidsuit"
|
||||
item_state = "atmos_voidsuit"
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 50)
|
||||
max_heat_protection_temperature = FIRESUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
182
code/modules/clothing/spacesuits/void/void.dm
Normal file
182
code/modules/clothing/spacesuits/void/void.dm
Normal file
@@ -0,0 +1,182 @@
|
||||
//NASA Voidsuit
|
||||
/obj/item/clothing/head/helmet/space/void
|
||||
name = "void helmet"
|
||||
desc = "A high-tech dark red space suit helmet. Used for AI satellite maintenance."
|
||||
icon_state = "void"
|
||||
item_state = "void"
|
||||
|
||||
heat_protection = HEAD
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 20)
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
|
||||
//Species-specific stuff.
|
||||
species_restricted = list("exclude","Unathi","Tajara","Skrell","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
sprite_sheets_refit = list(
|
||||
"Unathi" = 'icons/mob/species/unathi/helmet.dmi',
|
||||
"Tajara" = 'icons/mob/species/tajaran/helmet.dmi',
|
||||
"Skrell" = 'icons/mob/species/skrell/helmet.dmi',
|
||||
)
|
||||
sprite_sheets_obj = list(
|
||||
"Unathi" = 'icons/obj/clothing/species/unathi/hats.dmi',
|
||||
"Tajara" = 'icons/obj/clothing/species/tajaran/hats.dmi',
|
||||
"Skrell" = 'icons/obj/clothing/species/skrell/hats.dmi',
|
||||
)
|
||||
|
||||
light_overlay = "helmet_light"
|
||||
|
||||
/obj/item/clothing/suit/space/void
|
||||
name = "voidsuit"
|
||||
icon_state = "void"
|
||||
item_state = "void"
|
||||
desc = "A high-tech dark red space suit. Used for AI satellite maintenance."
|
||||
slowdown = 1
|
||||
armor = list(melee = 40, bullet = 5, laser = 20,energy = 5, bomb = 35, bio = 100, rad = 20)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/device/suit_cooling_unit)
|
||||
heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
|
||||
species_restricted = list("exclude","Unathi","Tajara","Diona","Vox", "Xenomorph", "Xenomorph Drone", "Xenomorph Hunter", "Xenomorph Sentinel", "Xenomorph Queen")
|
||||
sprite_sheets_refit = list(
|
||||
"Unathi" = 'icons/mob/species/unathi/suit.dmi',
|
||||
"Tajara" = 'icons/mob/species/tajaran/suit.dmi',
|
||||
"Skrell" = 'icons/mob/species/skrell/suit.dmi',
|
||||
)
|
||||
sprite_sheets_obj = list(
|
||||
"Unathi" = 'icons/obj/clothing/species/unathi/suits.dmi',
|
||||
"Tajara" = 'icons/obj/clothing/species/tajaran/suits.dmi',
|
||||
"Skrell" = 'icons/obj/clothing/species/skrell/suits.dmi',
|
||||
)
|
||||
|
||||
//Breach thresholds, should ideally be inherited by most (if not all) voidsuits.
|
||||
breach_threshold = 18
|
||||
can_breach = 1
|
||||
|
||||
//Inbuilt devices.
|
||||
var/obj/item/clothing/shoes/magboots/boots = null // Deployable boots, if any.
|
||||
var/obj/item/clothing/head/helmet/helmet = null // Deployable helmet, if any.
|
||||
|
||||
/obj/item/clothing/suit/space/void/equipped(mob/M)
|
||||
..()
|
||||
|
||||
var/mob/living/carbon/human/H = M
|
||||
|
||||
if(!istype(H)) return
|
||||
|
||||
if(H.wear_suit != src)
|
||||
return
|
||||
|
||||
if(helmet)
|
||||
if(H.head)
|
||||
M << "You are unable to deploy your suit's helmet as \the [H.head] is in the way."
|
||||
else
|
||||
M << "Your suit's helmet deploys with a hiss."
|
||||
//TODO: Species check, skull damage for forcing an unfitting helmet on?
|
||||
helmet.loc = H
|
||||
H.equip_to_slot(helmet, slot_head)
|
||||
helmet.canremove = 0
|
||||
|
||||
if(boots)
|
||||
if(H.shoes)
|
||||
M << "You are unable to deploy your suit's magboots as \the [H.shoes] are in the way."
|
||||
else
|
||||
M << "Your suit's boots deploy with a hiss."
|
||||
boots.loc = H
|
||||
H.equip_to_slot(boots, slot_shoes)
|
||||
boots.canremove = 0
|
||||
|
||||
/obj/item/clothing/suit/space/void/dropped()
|
||||
..()
|
||||
|
||||
var/mob/living/carbon/human/H
|
||||
|
||||
if(helmet)
|
||||
H = helmet.loc
|
||||
if(istype(H))
|
||||
if(helmet && H.head == helmet)
|
||||
helmet.canremove = 1
|
||||
H.drop_from_inventory(helmet)
|
||||
helmet.loc = src
|
||||
|
||||
if(boots)
|
||||
H = boots.loc
|
||||
if(istype(H))
|
||||
if(boots && H.shoes == boots)
|
||||
boots.canremove = 1
|
||||
H.drop_from_inventory(boots)
|
||||
boots.loc = src
|
||||
|
||||
/obj/item/clothing/suit/space/void/verb/toggle_helmet()
|
||||
|
||||
set name = "Toggle Helmet"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
if(!istype(src.loc,/mob/living)) return
|
||||
|
||||
if(!helmet)
|
||||
usr << "There is no helmet installed."
|
||||
return
|
||||
|
||||
var/mob/living/carbon/human/H = usr
|
||||
|
||||
if(!istype(H)) return
|
||||
if(H.stat) return
|
||||
if(H.wear_suit != src) return
|
||||
|
||||
if(H.head == helmet)
|
||||
H << "\blue You retract your suit helmet."
|
||||
helmet.canremove = 1
|
||||
H.drop_from_inventory(helmet)
|
||||
helmet.loc = src
|
||||
else
|
||||
if(H.head)
|
||||
H << "<span class='danger'>You cannot deploy your helmet while wearing another helmet.</span>"
|
||||
return
|
||||
//TODO: Species check, skull damage for forcing an unfitting helmet on?
|
||||
helmet.loc = H
|
||||
helmet.pickup(H)
|
||||
H.equip_to_slot(helmet, slot_head)
|
||||
helmet.canremove = 0
|
||||
H << "<font color='blue'><b>You deploy your suit helmet, sealing you off from the world.</b></font>"
|
||||
helmet.update_light(H)
|
||||
|
||||
/obj/item/clothing/suit/space/void/attackby(obj/item/W as obj, mob/user as mob)
|
||||
|
||||
if(!istype(user,/mob/living)) return
|
||||
|
||||
if(istype(src.loc,/mob/living))
|
||||
user << "<span class='danger'>How do you propose to modify a hardsuit while it is being worn?</span>"
|
||||
return
|
||||
|
||||
if(istype(W,/obj/item/weapon/screwdriver))
|
||||
if(helmet)
|
||||
user << "You detatch \the [helmet] from \the [src]'s helmet mount."
|
||||
helmet.loc = get_turf(src)
|
||||
src.helmet = null
|
||||
else if (boots)
|
||||
user << "You detatch \the [boots] from \the [src]'s boot mounts."
|
||||
boots.loc = get_turf(src)
|
||||
src.boots = null
|
||||
else
|
||||
user << "\The [src] does not have anything installed."
|
||||
return
|
||||
else if(istype(W,/obj/item/clothing/head/helmet/space))
|
||||
if(helmet)
|
||||
user << "\The [src] already has a helmet installed."
|
||||
else
|
||||
user << "You attach \the [W] to \the [src]'s helmet mount."
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
src.helmet = W
|
||||
return
|
||||
else if(istype(W,/obj/item/clothing/shoes/magboots))
|
||||
if(boots)
|
||||
user << "\The [src] already has magboots installed."
|
||||
else
|
||||
user << "You attach \the [W] to \the [src]'s boot mounts."
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
boots = W
|
||||
return
|
||||
|
||||
..()
|
||||
25
code/modules/clothing/spacesuits/void/wizard.dm
Normal file
25
code/modules/clothing/spacesuits/void/wizard.dm
Normal file
@@ -0,0 +1,25 @@
|
||||
//Wizard Rig
|
||||
/obj/item/clothing/head/helmet/space/void/wizard
|
||||
name = "gem-encrusted voidsuit helmet"
|
||||
desc = "A bizarre gem-encrusted helmet that radiates magical energies."
|
||||
icon_state = "rig0-wiz"
|
||||
item_state = "wiz_helm"
|
||||
item_color = "wiz"
|
||||
unacidable = 1 //No longer shall our kind be foiled by lone chemists with spray bottles!
|
||||
armor = list(melee = 40, bullet = 20, laser = 20,energy = 20, bomb = 35, bio = 100, rad = 60)
|
||||
siemens_coefficient = 0.7
|
||||
sprite_sheets_refit = null
|
||||
sprite_sheets_obj = null
|
||||
|
||||
/obj/item/clothing/suit/space/void/wizard
|
||||
icon_state = "rig-wiz"
|
||||
name = "gem-encrusted voidsuit"
|
||||
desc = "A bizarre gem-encrusted suit that radiates magical energies."
|
||||
item_state = "wiz_voidsuit"
|
||||
slowdown = 1
|
||||
w_class = 3
|
||||
unacidable = 1
|
||||
armor = list(melee = 40, bullet = 20, laser = 20,energy = 20, bomb = 35, bio = 100, rad = 60)
|
||||
siemens_coefficient = 0.7
|
||||
sprite_sheets_refit = null
|
||||
sprite_sheets_obj = null
|
||||
@@ -17,7 +17,7 @@
|
||||
name = "captain's parade tunic"
|
||||
desc = "Worn by a Captain to show their class."
|
||||
icon_state = "captunic"
|
||||
item_state = "bio_suit"
|
||||
item_state = "captunic"
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
flags_inv = HIDEJUMPSUIT
|
||||
sprite_sheets = list("Vox" = 'icons/mob/species/vox/suit.dmi')
|
||||
@@ -26,7 +26,7 @@
|
||||
name = "captain's uniform jacket"
|
||||
desc = "A less formal jacket for everyday captain use."
|
||||
icon_state = "capjacket"
|
||||
item_state = "bio_suit"
|
||||
item_state = "capjacket"
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
|
||||
flags_inv = HIDEJUMPSUIT
|
||||
|
||||
@@ -141,11 +141,13 @@
|
||||
sprite_sheets = list("Vox" = 'icons/mob/species/vox/suit.dmi')
|
||||
|
||||
//Lawyer
|
||||
/obj/item/clothing/suit/storage/lawyer/bluejacket
|
||||
/obj/item/clothing/suit/storage/toggle/lawyer/bluejacket
|
||||
name = "Blue Suit Jacket"
|
||||
desc = "A snappy dress jacket."
|
||||
icon_state = "suitjacket_blue_open"
|
||||
item_state = "suitjacket_blue_open"
|
||||
icon_open = "suitjacket_blue_open"
|
||||
icon_closed = "suitjacket_blue"
|
||||
blood_overlay_type = "coat"
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
|
||||
@@ -158,62 +160,31 @@
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
|
||||
//Internal Affairs
|
||||
/obj/item/clothing/suit/storage/internalaffairs
|
||||
/obj/item/clothing/suit/storage/toggle/internalaffairs
|
||||
name = "Internal Affairs Jacket"
|
||||
desc = "A smooth black jacket."
|
||||
icon_state = "ia_jacket_open"
|
||||
item_state = "ia_jacket"
|
||||
icon_open = "ia_jacket_open"
|
||||
icon_closed = "ia_jacket"
|
||||
blood_overlay_type = "coat"
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
|
||||
verb/toggle()
|
||||
set name = "Toggle Coat Buttons"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
if(!usr.canmove || usr.stat || usr.restrained())
|
||||
return 0
|
||||
|
||||
switch(icon_state)
|
||||
if("ia_jacket_open")
|
||||
src.icon_state = "ia_jacket"
|
||||
usr << "You button up the jacket."
|
||||
if("ia_jacket")
|
||||
src.icon_state = "ia_jacket_open"
|
||||
usr << "You unbutton the jacket."
|
||||
else
|
||||
usr << "You attempt to button-up the velcro on your [src], before promptly realising how retarded you are."
|
||||
return
|
||||
update_clothing_icon() //so our overlays update
|
||||
|
||||
//Medical
|
||||
/obj/item/clothing/suit/storage/fr_jacket
|
||||
/obj/item/clothing/suit/storage/toggle/fr_jacket
|
||||
name = "first responder jacket"
|
||||
desc = "A high-visibility jacket worn by medical first responders."
|
||||
icon_state = "fr_jacket_open"
|
||||
item_state = "fr_jacket"
|
||||
icon_open = "fr_jacket_open"
|
||||
icon_closed = "fr_jacket"
|
||||
blood_overlay_type = "armor"
|
||||
allowed = list(/obj/item/stack/medical, /obj/item/weapon/reagent_containers/dropper, /obj/item/weapon/reagent_containers/hypospray, /obj/item/weapon/reagent_containers/syringe, \
|
||||
/obj/item/device/healthanalyzer, /obj/item/device/flashlight, /obj/item/device/radio, /obj/item/weapon/tank/emergency_oxygen)
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
|
||||
verb/toggle()
|
||||
set name = "Toggle Jacket Buttons"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
if(!usr.canmove || usr.stat || usr.restrained())
|
||||
return 0
|
||||
|
||||
switch(icon_state)
|
||||
if("fr_jacket_open")
|
||||
src.icon_state = "fr_jacket"
|
||||
usr << "You button up the jacket."
|
||||
if("fr_jacket")
|
||||
src.icon_state = "fr_jacket_open"
|
||||
usr << "You unbutton the jacket."
|
||||
update_clothing_icon() //so our overlays update
|
||||
|
||||
//Mime
|
||||
/obj/item/clothing/suit/suspenders
|
||||
name = "suspenders"
|
||||
|
||||
@@ -1,160 +1,104 @@
|
||||
/obj/item/clothing/suit/storage/labcoat
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat
|
||||
name = "labcoat"
|
||||
desc = "A suit that protects against minor chemical spills."
|
||||
icon_state = "labcoat_open"
|
||||
item_state = "labcoat" //Is this even used for anything?
|
||||
icon_open = "labcoat_open"
|
||||
icon_closed = "labcoat"
|
||||
blood_overlay_type = "coat"
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
allowed = list(/obj/item/device/analyzer,/obj/item/stack/medical,/obj/item/weapon/dnainjector,/obj/item/weapon/reagent_containers/dropper,/obj/item/weapon/reagent_containers/syringe,/obj/item/weapon/reagent_containers/hypospray,/obj/item/device/healthanalyzer,/obj/item/device/flashlight/pen,/obj/item/weapon/reagent_containers/glass/bottle,/obj/item/weapon/reagent_containers/glass/beaker,/obj/item/weapon/reagent_containers/pill,/obj/item/weapon/storage/pill_bottle,/obj/item/weapon/paper)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 50, rad = 0)
|
||||
sprite_sheets = list("Vox" = 'icons/mob/species/vox/suit.dmi')
|
||||
|
||||
verb/toggle()
|
||||
set name = "Toggle Labcoat Buttons"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
if(!usr.canmove || usr.stat || usr.restrained())
|
||||
return 0
|
||||
|
||||
//Why???
|
||||
switch(icon_state)
|
||||
if("labcoat_open")
|
||||
src.icon_state = "labcoat"
|
||||
usr << "You button up the labcoat."
|
||||
if("labcoat")
|
||||
src.icon_state = "labcoat_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("red_labcoat_open")
|
||||
src.icon_state = "red_labcoat"
|
||||
usr << "You button up the labcoat."
|
||||
if("red_labcoat")
|
||||
src.icon_state = "red_labcoat_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("blue_labcoat_open")
|
||||
src.icon_state = "blue_labcoat"
|
||||
usr << "You button up the labcoat."
|
||||
if("blue_labcoat")
|
||||
src.icon_state = "blue_labcoat_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("purple_labcoat_open")
|
||||
src.icon_state = "purple_labcoat"
|
||||
usr << "You button up the labcoat."
|
||||
if("purple_labcoat")
|
||||
src.icon_state = "purple_labcoat_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("green_labcoat_open")
|
||||
src.icon_state = "green_labcoat"
|
||||
usr << "You button up the labcoat."
|
||||
if("green_labcoat")
|
||||
src.icon_state = "green_labcoat_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("orange_labcoat_open")
|
||||
src.icon_state = "orange_labcoat"
|
||||
usr << "You button up the labcoat."
|
||||
if("orange_labcoat")
|
||||
src.icon_state = "orange_labcoat_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("labcoat_cmo_open")
|
||||
src.icon_state = "labcoat_cmo"
|
||||
usr << "You button up the labcoat."
|
||||
if("labcoat_cmo")
|
||||
src.icon_state = "labcoat_cmo_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("labcoat_gen_open")
|
||||
src.icon_state = "labcoat_gen"
|
||||
usr << "You button up the labcoat."
|
||||
if("labcoat_gen")
|
||||
src.icon_state = "labcoat_gen_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("labcoat_chem_open")
|
||||
src.icon_state = "labcoat_chem"
|
||||
usr << "You button up the labcoat."
|
||||
if("labcoat_chem")
|
||||
src.icon_state = "labcoat_chem_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("labcoat_vir_open")
|
||||
src.icon_state = "labcoat_vir"
|
||||
usr << "You button up the labcoat."
|
||||
if("labcoat_vir")
|
||||
src.icon_state = "labcoat_vir_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("labcoat_tox_open")
|
||||
src.icon_state = "labcoat_tox"
|
||||
usr << "You button up the labcoat."
|
||||
if("labcoat_tox")
|
||||
src.icon_state = "labcoat_tox_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
if("labgreen_open")
|
||||
src.icon_state = "labgreen"
|
||||
usr << "You button up the labcoat."
|
||||
if("labgreen")
|
||||
src.icon_state = "labgreen_open"
|
||||
usr << "You unbutton the labcoat."
|
||||
else
|
||||
usr << "You attempt to button-up the velcro on your [src], before promptly realising how silly you are."
|
||||
return
|
||||
update_clothing_icon() //so our overlays update
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/red
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/red
|
||||
name = "red labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. This one is red."
|
||||
icon_state = "red_labcoat_open"
|
||||
item_state = "red_labcoat"
|
||||
icon_open = "red_labcoat_open"
|
||||
icon_closed = "red_labcoat"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/blue
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/blue
|
||||
name = "blue labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. This one is blue."
|
||||
icon_state = "blue_labcoat_open"
|
||||
item_state = "blue_labcoat"
|
||||
icon_open = "blue_labcoat_open"
|
||||
icon_closed = "blue_labcoat"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/purple
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/purple
|
||||
name = "purple labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. This one is purple."
|
||||
icon_state = "purple_labcoat_open"
|
||||
item_state = "purple_labcoat"
|
||||
icon_open = "purple_labcoat_open"
|
||||
icon_closed = "purple_labcoat"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/orange
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/orange
|
||||
name = "orange labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. This one is orange."
|
||||
icon_state = "orange_labcoat_open"
|
||||
item_state = "orange_labcoat"
|
||||
icon_open = "orange_labcoat_open"
|
||||
icon_closed = "orange_labcoat"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/green
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/green
|
||||
name = "green labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. This one is green."
|
||||
icon_state = "green_labcoat_open"
|
||||
item_state = "green_labcoat"
|
||||
icon_open = "green_labcoat_open"
|
||||
icon_closed = "green_labcoat"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/cmo
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/cmo
|
||||
name = "chief medical officer's labcoat"
|
||||
desc = "Bluer than the standard model."
|
||||
icon_state = "labcoat_cmo_open"
|
||||
item_state = "labcoat_cmo"
|
||||
icon_open = "labcoat_cmo_open"
|
||||
icon_closed = "labcoat_cmo"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/mad
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/cmoalt
|
||||
name = "chief medical officer labcoat"
|
||||
desc = "A labcoat with command blue highlights."
|
||||
icon_state = "labcoat_cmoalt_open"
|
||||
icon_open = "labcoat_cmoalt_open"
|
||||
icon_closed = "labcoat_cmoalt"
|
||||
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/mad
|
||||
name = "The Mad's labcoat"
|
||||
desc = "It makes you look capable of konking someone on the noggin and shooting them into space."
|
||||
icon_state = "labgreen_open"
|
||||
item_state = "labgreen"
|
||||
icon_open = "labgreen_open"
|
||||
icon_closed = "labgreen"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/genetics
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/genetics
|
||||
name = "Geneticist labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. Has a blue stripe on the shoulder."
|
||||
icon_state = "labcoat_gen_open"
|
||||
icon_open = "labcoat_gen_open"
|
||||
icon_closed = "labcoat_gen"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/chemist
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/chemist
|
||||
name = "Chemist labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. Has an orange stripe on the shoulder."
|
||||
icon_state = "labcoat_chem_open"
|
||||
icon_open = "labcoat_chem_open"
|
||||
icon_closed = "labcoat_chem"
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/virologist
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/virologist
|
||||
name = "Virologist labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. Offers slightly more protection against biohazards than the standard model. Has a green stripe on the shoulder."
|
||||
icon_state = "labcoat_vir_open"
|
||||
icon_open = "labcoat_vir_open"
|
||||
icon_closed = "labcoat_vir"
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 60, rad = 0)
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/science
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/science
|
||||
name = "Scientist labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. Has a purple stripe on the shoulder."
|
||||
icon_state = "labcoat_tox_open"
|
||||
icon_open = "labcoat_tox_open"
|
||||
icon_closed = "labcoat_tox"
|
||||
|
||||
@@ -199,28 +199,6 @@
|
||||
item_state = "ianshirt"
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
|
||||
//Blue suit jacket toggle
|
||||
/obj/item/clothing/suit/suit/verb/toggle()
|
||||
set name = "Toggle Jacket Buttons"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
|
||||
if(!usr.canmove || usr.stat || usr.restrained())
|
||||
return 0
|
||||
|
||||
if(src.icon_state == "suitjacket_blue_open")
|
||||
src.icon_state = "suitjacket_blue"
|
||||
src.item_state = "suitjacket_blue"
|
||||
usr << "You button up the suit jacket."
|
||||
else if(src.icon_state == "suitjacket_blue")
|
||||
src.icon_state = "suitjacket_blue_open"
|
||||
src.item_state = "suitjacket_blue_open"
|
||||
usr << "You unbutton the suit jacket."
|
||||
else
|
||||
usr << "You button-up some imaginary buttons on your [src]."
|
||||
return
|
||||
update_clothing_icon()
|
||||
|
||||
//pyjamas
|
||||
//originally intended to be pinstripes >.>
|
||||
|
||||
@@ -356,23 +334,70 @@
|
||||
|
||||
/obj/item/clothing/suit/poncho/green
|
||||
name = "green poncho"
|
||||
desc = "Your classic, non-racist poncho. This one is green."
|
||||
desc = "A simple, comfortable cloak without sleeves. This one is green."
|
||||
icon_state = "greenponcho"
|
||||
item_state = "greenponcho"
|
||||
|
||||
/obj/item/clothing/suit/poncho/red
|
||||
name = "red poncho"
|
||||
desc = "Your classic, non-racist poncho. This one is red."
|
||||
desc = "A simple, comfortable cloak without sleeves. This one is red."
|
||||
icon_state = "redponcho"
|
||||
item_state = "redponcho"
|
||||
|
||||
/obj/item/clothing/suit/bomber
|
||||
/obj/item/clothing/suit/poncho/purple
|
||||
name = "purple poncho"
|
||||
desc = "A simple, comfortable cloak without sleeves. This one is purple."
|
||||
icon_state = "purpleponcho"
|
||||
item_state = "purpleponcho"
|
||||
|
||||
/obj/item/clothing/suit/poncho/blue
|
||||
name = "blue poncho"
|
||||
desc = "A simple, comfortable cloak without sleeves. This one is blue."
|
||||
icon_state = "blueponcho"
|
||||
item_state = "blueponcho"
|
||||
|
||||
/obj/item/clothing/suit/storage/bomber
|
||||
name = "bomber jacket"
|
||||
desc = "A well-worn WW2 leather bomber jacket."
|
||||
desc = "A thick, well-worn WW2 leather bomber jacket."
|
||||
icon_state = "bomber"
|
||||
item_state = "bomber"
|
||||
flags = FPRINT | TABLEPASS
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
cold_protection = UPPER_TORSO|ARMS
|
||||
min_cold_protection_temperature = T0C
|
||||
siemens_coefficient = 0.7
|
||||
min_cold_protection_temperature = T0C - 20
|
||||
siemens_coefficient = 0.7
|
||||
|
||||
/obj/item/clothing/suit/storage/leather_jacket
|
||||
name = "leather jacket"
|
||||
desc = "A black leather coat."
|
||||
icon_state = "leather_jacket"
|
||||
item_state = "leather_jacket"
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
|
||||
/obj/item/clothing/suit/storage/leather_jacket/nanotrasen
|
||||
desc = "A black leather coat. The letters NT are proudly displayed on the back."
|
||||
icon_state = "leather_jacket_nt"
|
||||
|
||||
//This one has buttons for some reason
|
||||
/obj/item/clothing/suit/storage/toggle/brown_jacket
|
||||
name = "leather jacket"
|
||||
desc = "A brown leather coat."
|
||||
icon_state = "brown_jacket"
|
||||
item_state = "brown_jacket"
|
||||
icon_open = "brown_jacket_open"
|
||||
icon_closed = "brown_jacket"
|
||||
body_parts_covered = UPPER_TORSO|ARMS
|
||||
|
||||
/obj/item/clothing/suit/storage/toggle/brown_jacket/nanotrasen
|
||||
desc = "A brown leather coat. The letters NT are proudly displayed on the back."
|
||||
icon_state = "brown_jacket_nt"
|
||||
icon_open = "brown_jacket_nt_open"
|
||||
icon_closed = "brown_jacket_nt"
|
||||
|
||||
/obj/item/clothing/suit/hoodie
|
||||
name = "grey hoodie"
|
||||
desc = "A warm, grey sweatshirt."
|
||||
icon_state = "grey_hoodie"
|
||||
item_state = "grey_hoodie"
|
||||
min_cold_protection_temperature = T0C - 20
|
||||
cold_protection = UPPER_TORSO|LOWER_TORSO|ARMS
|
||||
|
||||
@@ -24,6 +24,28 @@
|
||||
pockets.emp_act(severity)
|
||||
..()
|
||||
|
||||
/obj/item/clothing/suit/storage/hear_talk(mob/M, var/msg)
|
||||
pockets.hear_talk(M, msg)
|
||||
..()
|
||||
/obj/item/clothing/suit/storage/hear_talk(mob/M, var/msg, verb, datum/language/speaking)
|
||||
pockets.hear_talk(M, msg, verb, speaking)
|
||||
..()
|
||||
|
||||
//Jackets with buttons, used for labcoats, IA jackets, First Responder jackets, and brown jackets.
|
||||
/obj/item/clothing/suit/storage/toggle
|
||||
var/icon_open
|
||||
var/icon_closed
|
||||
verb/toggle()
|
||||
set name = "Toggle Coat Buttons"
|
||||
set category = "Object"
|
||||
set src in usr
|
||||
if(!usr.canmove || usr.stat || usr.restrained())
|
||||
return 0
|
||||
|
||||
if(icon_state == icon_open) //Will check whether icon state is currently set to the "open" or "closed" state and switch it around with a message to the user
|
||||
icon_state = icon_closed
|
||||
usr << "You button up the coat."
|
||||
else if(icon_state == icon_closed)
|
||||
icon_state = icon_open
|
||||
usr << "You unbutton the coat."
|
||||
else //in case some goofy admin switches icon states around without switching the icon_open or icon_closed
|
||||
usr << "You attempt to button-up the velcro on your [src], before promptly realising how silly you are."
|
||||
return
|
||||
update_clothing_icon() //so our overlays update
|
||||
@@ -14,8 +14,7 @@
|
||||
|
||||
New()
|
||||
..()
|
||||
var/blocked = list(/obj/item/clothing/under/chameleon, /obj/item/clothing/under/cloud,
|
||||
/obj/item/clothing/under/golem, /obj/item/clothing/under/gimmick)//Prevent infinite loops and bad jumpsuits.
|
||||
var/blocked = list(/obj/item/clothing/under/chameleon, /obj/item/clothing/under/cloud, /obj/item/clothing/under/gimmick)//Prevent infinite loops and bad jumpsuits.
|
||||
for(var/U in typesof(/obj/item/clothing/under)-blocked)
|
||||
var/obj/item/clothing/under/V = new U
|
||||
src.clothing_choices[V.name] = U
|
||||
@@ -67,8 +66,7 @@
|
||||
|
||||
New()
|
||||
..()
|
||||
var/blocked = list(/obj/item/clothing/head/chameleon,
|
||||
/obj/item/clothing/head/space/golem, /obj/item/clothing/head/justice,)//Prevent infinite loops and bad hats.
|
||||
var/blocked = list(/obj/item/clothing/head/chameleon,/obj/item/clothing/head/justice,)//Prevent infinite loops and bad hats.
|
||||
for(var/U in typesof(/obj/item/clothing/head)-blocked)
|
||||
var/obj/item/clothing/head/V = new U
|
||||
src.clothing_choices[V.name] = U
|
||||
@@ -119,8 +117,7 @@
|
||||
|
||||
New()
|
||||
..()
|
||||
var/blocked = list(/obj/item/clothing/suit/chameleon, /obj/item/clothing/suit/space/space_ninja,
|
||||
/obj/item/clothing/suit/golem, /obj/item/clothing/suit/suit, /obj/item/clothing/suit/cyborg_suit, /obj/item/clothing/suit/justice,
|
||||
var/blocked = list(/obj/item/clothing/suit/chameleon, /obj/item/clothing/suit/cyborg_suit, /obj/item/clothing/suit/justice,
|
||||
/obj/item/clothing/suit/greatcoat)//Prevent infinite loops and bad suits.
|
||||
for(var/U in typesof(/obj/item/clothing/suit)-blocked)
|
||||
var/obj/item/clothing/suit/V = new U
|
||||
@@ -172,8 +169,7 @@
|
||||
|
||||
New()
|
||||
..()
|
||||
var/blocked = list(/obj/item/clothing/shoes/chameleon,
|
||||
/obj/item/clothing/shoes/golem, /obj/item/clothing/shoes/syndigaloshes, /obj/item/clothing/shoes/cyborg)//prevent infinite loops and bad shoes.
|
||||
var/blocked = list(/obj/item/clothing/shoes/chameleon, /obj/item/clothing/shoes/syndigaloshes, /obj/item/clothing/shoes/cyborg)//prevent infinite loops and bad shoes.
|
||||
for(var/U in typesof(/obj/item/clothing/shoes)-blocked)
|
||||
var/obj/item/clothing/shoes/V = new U
|
||||
src.clothing_choices[V.name] = U
|
||||
@@ -257,7 +253,7 @@
|
||||
icon_state = A.icon_state
|
||||
item_state = A.item_state
|
||||
item_color = A.item_color
|
||||
|
||||
|
||||
//so our overlays update.
|
||||
if (ismob(src.loc))
|
||||
var/mob/M = src.loc
|
||||
@@ -464,7 +460,7 @@
|
||||
icon_state = A.icon_state
|
||||
item_state = A.item_state
|
||||
flags_inv = A.flags_inv
|
||||
|
||||
|
||||
//so our overlays update.
|
||||
if (ismob(src.loc))
|
||||
var/mob/M = src.loc
|
||||
|
||||
@@ -392,6 +392,14 @@
|
||||
item_color = "sundress"
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO
|
||||
|
||||
/obj/item/clothing/under/sundress_white
|
||||
name = "white sundress"
|
||||
desc = "A white sundress decorated with purple lilies."
|
||||
icon_state = "sundress_white"
|
||||
item_state = "sundress_white"
|
||||
item_color = "sundress_white"
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO
|
||||
|
||||
/obj/item/clothing/under/captainformal
|
||||
name = "captain's formal uniform"
|
||||
desc = "A captain's formal-wear, for special occasions."
|
||||
@@ -460,4 +468,12 @@
|
||||
desc = "The very image of a working man. Not that you're probably doing work."
|
||||
icon_state = "mechanic_s"
|
||||
item_state = "mechanic_s"
|
||||
item_color = "mechanic_s"
|
||||
item_color = "mechanic_s"
|
||||
|
||||
/obj/item/clothing/under/cheongsam
|
||||
name = "White Cheongsam"
|
||||
desc = "It is a white cheongsam dress."
|
||||
icon_state = "mai_yang"
|
||||
item_state = "mai_yang"
|
||||
item_color = "mai_yang"
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
item_state = "" //no inhands
|
||||
item_color = "bluetie"
|
||||
flags = FPRINT | TABLEPASS
|
||||
slot_flags = 0
|
||||
slot_flags = SLOT_TIE
|
||||
w_class = 2.0
|
||||
var/obj/item/clothing/under/has_suit = null //the suit the tie may be attached to
|
||||
var/image/inv_overlay = null //overlay used when attached to clothing.
|
||||
@@ -257,13 +257,12 @@
|
||||
holstered.emp_act(severity)
|
||||
..()
|
||||
|
||||
/obj/item/clothing/tie/holster/examine()
|
||||
set src in view()
|
||||
..()
|
||||
/obj/item/clothing/tie/holster/examine(mob/user)
|
||||
..(user)
|
||||
if (holstered)
|
||||
usr << "A [holstered] is holstered here."
|
||||
user << "A [holstered] is holstered here."
|
||||
else
|
||||
usr << "It is empty."
|
||||
user << "It is empty."
|
||||
|
||||
/obj/item/clothing/tie/holster/on_attached(obj/item/clothing/under/S, mob/user as mob)
|
||||
..()
|
||||
@@ -348,8 +347,8 @@
|
||||
hold.emp_act(severity)
|
||||
..()
|
||||
|
||||
/obj/item/clothing/tie/storage/hear_talk(mob/M, var/msg)
|
||||
hold.hear_talk(M, msg)
|
||||
/obj/item/clothing/tie/storage/hear_talk(mob/M, var/msg, verb, datum/language/speaking)
|
||||
hold.hear_talk(M, msg, verb, speaking)
|
||||
..()
|
||||
|
||||
/obj/item/clothing/tie/storage/attack_self(mob/user as mob)
|
||||
@@ -391,7 +390,7 @@
|
||||
desc = "This glowing blue badge marks the holder as THE LAW."
|
||||
icon_state = "holobadge"
|
||||
item_color = "holobadge"
|
||||
slot_flags = SLOT_BELT
|
||||
slot_flags = SLOT_BELT | SLOT_TIE
|
||||
|
||||
var/emagged = 0 //Emagging removes Sec check.
|
||||
var/stored_name = null
|
||||
@@ -399,7 +398,7 @@
|
||||
/obj/item/clothing/tie/holobadge/cord
|
||||
icon_state = "holobadge-cord"
|
||||
item_color = "holobadge-cord"
|
||||
slot_flags = SLOT_MASK
|
||||
slot_flags = SLOT_MASK | SLOT_TIE
|
||||
|
||||
/obj/item/clothing/tie/holobadge/attack_self(mob/user as mob)
|
||||
if(!stored_name)
|
||||
|
||||
@@ -301,19 +301,9 @@
|
||||
icon_on = "engravedzippoon"
|
||||
icon_off = "engravedzippo"
|
||||
|
||||
/obj/item/weapon/fluff/cado_keppel_1 //sparklysheep: Cado Keppel
|
||||
/obj/item/weapon/haircomb/fluff/cado_keppel_1 //sparklysheep: Cado Keppel
|
||||
name = "purple comb"
|
||||
desc = "A pristine purple comb made from flexible plastic. It has a small K etched into its side."
|
||||
w_class = 1.0
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "purplecomb"
|
||||
item_state = "purplecomb"
|
||||
|
||||
attack_self(mob/user)
|
||||
if(user.r_hand == src || user.l_hand == src)
|
||||
for(var/mob/O in viewers(user, null))
|
||||
O.show_message(text("\red [] uses [] to comb their hair with incredible style and sophistication. What a [].", user, src, user.gender == FEMALE ? "lady" : "guy"), 1)
|
||||
return
|
||||
|
||||
/obj/item/weapon/fluff/hugo_cinderbacth_1 //thatoneguy: Hugo Cinderbatch
|
||||
name = "Old Cane"
|
||||
@@ -368,7 +358,7 @@
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/beaker/large/fluff/nashida_bishara_1 //rukral:Nashida Bisha'ra
|
||||
name = "Nashida's Etched Beaker"
|
||||
desc = "The message: 'Please do not be removing this beaker from the chemistry lab. If lost, return to Nashida Bisha'ra' can be seen etched into the side of this 100 unit beaker."
|
||||
desc = "The message: 'Please do not be removing this beaker from the chemistry lab. If lost, return to Nashida Bisha'ra' can be seen etched into the side of this large beaker."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "beakerlarge"
|
||||
matter = list("glass" = 5000)
|
||||
@@ -543,19 +533,23 @@
|
||||
var/suit_icon // Sets suit icon_state and item_state.
|
||||
var/helmet_color // Sets item_color.
|
||||
var/uses = 2 // Uses before the kit deletes itself.
|
||||
var/new_light_overlay
|
||||
|
||||
/obj/item/clothing/head/helmet/space/rig/attackby(var/obj/item/O as obj, mob/user as mob)
|
||||
/obj/item/clothing/head/helmet/space/void/attackby(var/obj/item/O as obj, mob/user as mob)
|
||||
..()
|
||||
|
||||
if(istype(O,/obj/item/device/kit/suit/fluff))
|
||||
|
||||
var/obj/item/device/kit/suit/fluff/kit = O
|
||||
name = "[kit.new_name] hardsuit helmet"
|
||||
name = "[kit.new_name] suit helmet"
|
||||
desc = kit.new_helmet_desc
|
||||
icon_state = kit.helmet_icon
|
||||
item_state = kit.helmet_icon
|
||||
item_color = kit.helmet_color
|
||||
|
||||
if(kit.new_light_overlay)
|
||||
light_overlay = kit.new_light_overlay
|
||||
|
||||
user << "You set about modifying the helmet into [src]."
|
||||
playsound(user.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
||||
|
||||
@@ -564,13 +558,13 @@
|
||||
user.drop_item()
|
||||
del(O)
|
||||
|
||||
/obj/item/clothing/suit/space/rig/attackby(var/obj/item/O as obj, mob/user as mob)
|
||||
/obj/item/clothing/suit/space/void/attackby(var/obj/item/O as obj, mob/user as mob)
|
||||
..()
|
||||
|
||||
if(istype(O,/obj/item/device/kit/suit/fluff))
|
||||
|
||||
var/obj/item/device/kit/suit/fluff/kit = O
|
||||
name = "[kit.new_name] hardsuit"
|
||||
name = "[kit.new_name] voidsuit"
|
||||
desc = kit.new_suit_desc
|
||||
icon_state = kit.suit_icon
|
||||
item_state = kit.suit_icon
|
||||
@@ -618,6 +612,7 @@
|
||||
helmet_icon = "rig0-hazardhardsuit"
|
||||
suit_icon = "rig-hazardhardsuit"
|
||||
helmet_color = "hazardhardsuit"
|
||||
new_light_overlay = "helmet_light_dual"
|
||||
|
||||
//////// Meat Hook - Korom Bhararaya - Matthew951 ////////////////////////
|
||||
|
||||
@@ -756,12 +751,9 @@
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "paintedwelding"
|
||||
|
||||
/obj/item/clothing/head/helmet/greenbandana/fluff/taryn_kifer_1 //themij: Taryn Kifer
|
||||
/obj/item/clothing/head/orangebandana/fluff/taryn_kifer_1 //themij: Taryn Kifer
|
||||
name = "orange bandana"
|
||||
desc = "Hey, I think we're missing a hazard vest..."
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "taryn_kifer_1"
|
||||
body_parts_covered = 0
|
||||
|
||||
/obj/item/clothing/head/fluff
|
||||
body_parts_covered = 0
|
||||
@@ -857,13 +849,17 @@
|
||||
icon_state = "bottle[color]"
|
||||
|
||||
//////////// Suits ////////////
|
||||
/obj/item/clothing/suit/storage/labcoat
|
||||
name = "labcoat"
|
||||
desc = "A plain labcoat."
|
||||
icon_state = "labcoat"
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO|ARMS|LEGS
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/fluff/aeneas_rinil //Robotics Labcoat - Aeneas Rinil [APPR]
|
||||
name = "Robotics labcoat"
|
||||
desc = "A labcoat with a few markings denoting it as the labcoat of roboticist."
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "aeneasrinil"
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO|ARMS|LEGS
|
||||
|
||||
/obj/item/clothing/suit/storage/labcoat/fluff/pink //spaceman96: Trenna Seber
|
||||
name = "pink labcoat"
|
||||
@@ -878,6 +874,15 @@
|
||||
icon_state = "mitlabcoat"
|
||||
item_state = "mitlabcoat"
|
||||
|
||||
/obj/item/clothing/suit/storage/toggle/labcoat/fluff/epsilon //Devildabeast: Looping Song
|
||||
name = "e UMi labcoat"
|
||||
desc = "A suit that protects against minor chemical spills. Has a black stripe on the shoulder. The abbreviation \"e UMi\" is written on the back in bold text."
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "labcoat_black_open"
|
||||
icon_open = "labcoat_black_open"
|
||||
icon_closed = "labcoat_black"
|
||||
item_state = "labcoat_black"
|
||||
|
||||
/obj/item/clothing/suit/storage/det_suit/fluff/leatherjack //atomicdog92: Seth Sealis
|
||||
name = "leather jacket"
|
||||
desc = "A black leather coat, popular amongst punks, greasers, and other galactic scum."
|
||||
@@ -1009,16 +1014,6 @@
|
||||
item_color = "harper_uniform"
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS
|
||||
|
||||
//////////////////// Layla's Dress - Layla Davies-Halabi - sabirm ///////////////
|
||||
|
||||
/obj/item/clothing/under/fluff/layla_davieshalabi
|
||||
name = "White floral sundress"
|
||||
desc = "A loose, white sundress decorated with purple lilies. It looks well looked-after."
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "layladress"
|
||||
item_state = "layladress"
|
||||
item_color = "layladress"
|
||||
|
||||
//////////////////// Corporate Cap - Robert Mason - Masterrbc ////////////////////
|
||||
|
||||
/obj/item/clothing/head/soft/sec/corp/fluff/robert_mason
|
||||
@@ -1144,7 +1139,6 @@
|
||||
item_color = "radi_pendant"
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 2.0
|
||||
slot_flags = 0
|
||||
|
||||
//////////// Masks ////////////
|
||||
|
||||
@@ -1190,7 +1184,7 @@
|
||||
slot_flags = 0
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 2
|
||||
slot_flags = SLOT_MASK
|
||||
slot_flags = SLOT_MASK | SLOT_TIE
|
||||
|
||||
////// Silver locket - Konaa Hirano - Konaa_Hirano
|
||||
|
||||
@@ -1204,7 +1198,7 @@
|
||||
slot_flags = 0
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 2
|
||||
slot_flags = SLOT_MASK
|
||||
slot_flags = SLOT_MASK | SLOT_TIE
|
||||
var/obj/item/held //Item inside locket.
|
||||
|
||||
/obj/item/clothing/tie/fluff/konaa_hirano/attack_self(mob/user as mob)
|
||||
@@ -1234,7 +1228,7 @@
|
||||
icon_state = "nasir_khayyam_1"
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 2
|
||||
slot_flags = SLOT_MASK
|
||||
slot_flags = SLOT_MASK | SLOT_TIE
|
||||
|
||||
////// Emerald necklace - Ty Foster - Nega
|
||||
|
||||
@@ -1279,6 +1273,14 @@
|
||||
icon_state = "digiboots"
|
||||
species_restricted = null
|
||||
|
||||
/obj/item/clothing/shoes/jackboots/fluff/harmony_singh_1 //Bromuzl: Harmony Singh
|
||||
name = "Springjacks"
|
||||
desc = "A pair of highly modified jackboots in medical white, with some type of spring assembly on the ankle and heels, painted orange."
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "springjacks"
|
||||
item_state = "springjacks"
|
||||
slowdown = SHOES_SLOWDOWN+1 //Slowing down because of her injured foot, these are for ease of pain so she can get off painkillers.
|
||||
siemens_coefficient = 0.7 //copied from Jackboots under code/modules/clothing/shoes/miscellaneous.dm
|
||||
|
||||
//////////// Sets ////////////
|
||||
|
||||
@@ -1364,14 +1366,9 @@
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "yuri_kornienkovich_flask"
|
||||
|
||||
/obj/item/clothing/under/fluff/mai_yang_dress // Mai Yang's pretty pretty dress.
|
||||
/obj/item/clothing/under/cheongsam/fluff/mai_yang_dress // Mai Yang's pretty pretty dress.
|
||||
name = "White Cheongsam"
|
||||
desc = "It is a white cheongsam dress."
|
||||
icon = 'icons/obj/custom_items.dmi'
|
||||
icon_state = "mai_yang"
|
||||
item_state = "mai_yang"
|
||||
item_color = "mai_yang"
|
||||
body_parts_covered = UPPER_TORSO|LOWER_TORSO
|
||||
|
||||
/obj/item/clothing/under/fluff/sakura_hokkaido_kimono
|
||||
name = "Sakura Kimono"
|
||||
@@ -1413,3 +1410,86 @@
|
||||
desc = "This cane seems to have 'Ryals' engraved on its handle."
|
||||
icon_state = "cane"
|
||||
item_state = "stick"
|
||||
|
||||
////////////////////////////// Foxler - Erstatz Vryroxes /////////////////////////////////////////////////
|
||||
|
||||
/obj/item/weapon/holder/cat/fluff/bones
|
||||
name = "Bones"
|
||||
desc = "It's Bones! Meow."
|
||||
gender = MALE
|
||||
icon_state = "cat3"
|
||||
|
||||
//Use this subtype for spawning in the custom item.
|
||||
/obj/item/weapon/holder/cat/fluff/bones/custom_item
|
||||
|
||||
/obj/item/weapon/holder/cat/fluff/bones/custom_item/New()
|
||||
if (!contents.len)
|
||||
new/mob/living/simple_animal/cat/fluff/bones (src)
|
||||
..()
|
||||
|
||||
/mob/living/simple_animal/cat/fluff/bones
|
||||
name = "Bones"
|
||||
desc = "That's Bones the cat. He's a laid back, black cat. Meow."
|
||||
gender = MALE
|
||||
icon_state = "cat3"
|
||||
icon_living = "cat3"
|
||||
icon_dead = "cat3_dead"
|
||||
holder_type = /obj/item/weapon/holder/cat/fluff/bones
|
||||
bff_name = "Erstatz Vryroxes"
|
||||
|
||||
/mob/living/simple_animal/cat/fluff
|
||||
var/bff_name
|
||||
var/mob/living/carbon/human/bff
|
||||
|
||||
/mob/living/simple_animal/cat/fluff/handle_movement_target()
|
||||
if (!bff)
|
||||
for (var/mob/living/carbon/human/M in player_list)
|
||||
if (M.real_name == bff_name)
|
||||
bff = M
|
||||
break
|
||||
|
||||
if (bff)
|
||||
var/follow_dist = 5
|
||||
if (bff.stat >= DEAD || bff.health <= config.health_threshold_softcrit) //danger
|
||||
follow_dist = 1
|
||||
else if (bff.stat || bff.health <= 50) //danger or just sleeping
|
||||
follow_dist = 2
|
||||
var/near_dist = max(follow_dist - 3, 1)
|
||||
var/current_dist = get_dist(src, bff)
|
||||
|
||||
if (movement_target != bff)
|
||||
if (current_dist > follow_dist && !istype(movement_target, /mob/living/simple_animal/mouse) && (bff in oview(src)))
|
||||
//stop existing movement
|
||||
walk_to(src,0)
|
||||
turns_since_scan = 0
|
||||
|
||||
//walk to bff
|
||||
stop_automated_movement = 1
|
||||
movement_target = bff
|
||||
walk_to(src, movement_target, near_dist, 4)
|
||||
|
||||
//already following and close enough, stop
|
||||
else if (current_dist <= near_dist)
|
||||
walk_to(src,0)
|
||||
movement_target = null
|
||||
stop_automated_movement = 0
|
||||
|
||||
if (!(bff && movement_target == bff))
|
||||
..()
|
||||
|
||||
/mob/living/simple_animal/cat/fluff/Life()
|
||||
..()
|
||||
if (stat || !bff)
|
||||
return
|
||||
if (get_dist(src, bff) <= 1)
|
||||
if (bff.stat >= DEAD || bff.health <= config.health_threshold_softcrit)
|
||||
if (prob((bff.stat < DEAD)? 50 : 15))
|
||||
audible_emote(pick("meows in distress.", "meows anxiously."))
|
||||
else
|
||||
if (prob(5))
|
||||
visible_emote(pick("nuzzles [bff].",
|
||||
"brushes against [bff].",
|
||||
"rubs against [bff].",
|
||||
"purrs."))
|
||||
else if (bff.health <= 50)
|
||||
if (prob(10)) audible_emote("meows anxiously.")
|
||||
|
||||
@@ -93,9 +93,9 @@
|
||||
icon_state = "evidenceobj"
|
||||
return
|
||||
|
||||
/obj/item/weapon/evidencebag/examine()
|
||||
..()
|
||||
if (stored_item) stored_item.examine()
|
||||
/obj/item/weapon/evidencebag/examine(mob/user)
|
||||
..(user)
|
||||
if (stored_item) user.examinate(stored_item)
|
||||
|
||||
/obj/item/weapon/storage/box/evidence
|
||||
name = "evidence bag box"
|
||||
|
||||
@@ -45,10 +45,3 @@
|
||||
user.visible_message("[user] finishes wiping off the [A]!")
|
||||
A.clean_blood()
|
||||
return
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/rag/examine()
|
||||
if (!usr)
|
||||
return
|
||||
usr << "That's \a [src]."
|
||||
usr << desc
|
||||
return
|
||||
@@ -11,6 +11,7 @@
|
||||
var/obj/item/weapon/card/id/held_card
|
||||
var/datum/money_account/detailed_account_view
|
||||
var/creating_new_account = 0
|
||||
var/const/fund_cap = 1000000
|
||||
|
||||
proc/get_access_level()
|
||||
if (!held_card)
|
||||
@@ -125,12 +126,12 @@
|
||||
if("add_funds")
|
||||
var/amount = input("Enter the amount you wish to add", "Silently add funds") as num
|
||||
if(detailed_account_view)
|
||||
detailed_account_view.money += amount
|
||||
detailed_account_view.money = min(detailed_account_view.money + amount, fund_cap)
|
||||
|
||||
if("remove_funds")
|
||||
var/amount = input("Enter the amount you wish to remove", "Silently remove funds") as num
|
||||
if(detailed_account_view)
|
||||
detailed_account_view.money -= amount
|
||||
detailed_account_view.money = max(detailed_account_view.money - amount, -fund_cap)
|
||||
|
||||
if("toggle_suspension")
|
||||
if(detailed_account_view)
|
||||
@@ -141,6 +142,9 @@
|
||||
var/account_name = href_list["holder_name"]
|
||||
var/starting_funds = max(text2num(href_list["starting_funds"]), 0)
|
||||
create_account(account_name, starting_funds, src)
|
||||
|
||||
starting_funds = Clamp(starting_funds, 0, station_account.money) // Not authorized to put the station in debt.
|
||||
starting_funds = min(starting_funds, fund_cap) // Not authrorized to give more than the fund cap.
|
||||
if(starting_funds > 0)
|
||||
//subtract the money
|
||||
station_account.money -= starting_funds
|
||||
|
||||
@@ -52,51 +52,44 @@
|
||||
affected_dest.temp_price_change[good_type] = rand(1,100) / 100
|
||||
|
||||
/datum/event/economic_event/announce()
|
||||
//copy-pasted from the admin verbs to submit new newscaster messages
|
||||
var/datum/feed_message/newMsg = new /datum/feed_message
|
||||
newMsg.author = "Nyx Daily"
|
||||
newMsg.is_admin_message = 1
|
||||
var/author = "Nyx Daily"
|
||||
var/channel = author
|
||||
|
||||
//see if our location has custom event info for this event
|
||||
newMsg.body = affected_dest.get_custom_eventstring()
|
||||
if(!newMsg.body)
|
||||
var/body = affected_dest.get_custom_eventstring()
|
||||
if(!body)
|
||||
switch(event_type)
|
||||
if(RIOTS)
|
||||
newMsg.body = "[pick("Riots have","Unrest has")] broken out on planet [affected_dest.name]. Authorities call for calm, as [pick("various parties","rebellious elements","peacekeeping forces","\'REDACTED\'")] begin stockpiling weaponry and armour. Meanwhile, food and mineral prices are dropping as local industries attempt empty their stocks in expectation of looting."
|
||||
body = "[pick("Riots have","Unrest has")] broken out on planet [affected_dest.name]. Authorities call for calm, as [pick("various parties","rebellious elements","peacekeeping forces","\'REDACTED\'")] begin stockpiling weaponry and armour. Meanwhile, food and mineral prices are dropping as local industries attempt empty their stocks in expectation of looting."
|
||||
if(WILD_ANIMAL_ATTACK)
|
||||
newMsg.body = "Local [pick("wildlife","animal life","fauna")] on planet [affected_dest.name] has been increasing in agression and raiding outlying settlements for food. Big game hunters have been called in to help alleviate the problem, but numerous injuries have already occurred."
|
||||
body = "Local [pick("wildlife","animal life","fauna")] on planet [affected_dest.name] has been increasing in agression and raiding outlying settlements for food. Big game hunters have been called in to help alleviate the problem, but numerous injuries have already occurred."
|
||||
if(INDUSTRIAL_ACCIDENT)
|
||||
newMsg.body = "[pick("An industrial accident","A smelting accident","A malfunction","A malfunctioning piece of machinery","Negligent maintenance","A cooleant leak","A ruptured conduit")] at a [pick("factory","installation","power plant","dockyards")] on [affected_dest.name] resulted in severe structural damage and numerous injuries. Repairs are ongoing."
|
||||
body = "[pick("An industrial accident","A smelting accident","A malfunction","A malfunctioning piece of machinery","Negligent maintenance","A cooleant leak","A ruptured conduit")] at a [pick("factory","installation","power plant","dockyards")] on [affected_dest.name] resulted in severe structural damage and numerous injuries. Repairs are ongoing."
|
||||
if(BIOHAZARD_OUTBREAK)
|
||||
newMsg.body = "[pick("A \'REDACTED\'","A biohazard","An outbreak","A virus")] on [affected_dest.name] has resulted in quarantine, stopping much shipping in the area. Although the quarantine is now lifted, authorities are calling for deliveries of medical supplies to treat the infected, and gas to replace contaminated stocks."
|
||||
body = "[pick("A \'REDACTED\'","A biohazard","An outbreak","A virus")] on [affected_dest.name] has resulted in quarantine, stopping much shipping in the area. Although the quarantine is now lifted, authorities are calling for deliveries of medical supplies to treat the infected, and gas to replace contaminated stocks."
|
||||
if(PIRATES)
|
||||
newMsg.body = "[pick("Pirates","Criminal elements","A [pick("Syndicate","Donk Co.","Waffle Co.","\'REDACTED\'")] strike force")] have [pick("raided","blockaded","attempted to blackmail","attacked")] [affected_dest.name] today. Security has been tightened, but many valuable minerals were taken."
|
||||
body = "[pick("Pirates","Criminal elements","A [pick("mercenary","Donk Co.","Waffle Co.","\'REDACTED\'")] strike force")] have [pick("raided","blockaded","attempted to blackmail","attacked")] [affected_dest.name] today. Security has been tightened, but many valuable minerals were taken."
|
||||
if(CORPORATE_ATTACK)
|
||||
newMsg.body = "A small [pick("pirate","Cybersun Industries","Gorlex Marauders","Syndicate")] fleet has precise-jumped into proximity with [affected_dest.name], [pick("for a smash-and-grab operation","in a hit and run attack","in an overt display of hostilities")]. Much damage was done, and security has been tightened since the incident."
|
||||
body = "A small [pick("pirate","Cybersun Industries","Gorlex Marauders","mercenary")] fleet has precise-jumped into proximity with [affected_dest.name], [pick("for a smash-and-grab operation","in a hit and run attack","in an overt display of hostilities")]. Much damage was done, and security has been tightened since the incident."
|
||||
if(ALIEN_RAIDERS)
|
||||
if(prob(20))
|
||||
newMsg.body = "The Tiger Co-operative have raided [affected_dest.name] today, no doubt on orders from their enigmatic masters. Stealing wildlife, farm animals, medical research materials and kidnapping civilians. NanoTrasen authorities are standing by to counter attempts at bio-terrorism."
|
||||
body = "The Tiger Co-operative have raided [affected_dest.name] today, no doubt on orders from their enigmatic masters. Stealing wildlife, farm animals, medical research materials and kidnapping civilians. NanoTrasen authorities are standing by to counter attempts at bio-terrorism."
|
||||
else
|
||||
newMsg.body = "[pick("The alien species designated \'United Exolitics\'","The alien species designated \'REDACTED\'","An unknown alien species")] have raided [affected_dest.name] today, stealing wildlife, farm animals, medical research materials and kidnapping civilians. It seems they desire to learn more about us, so the Navy will be standing by to accomodate them next time they try."
|
||||
body = "[pick("The alien species designated \'United Exolitics\'","The alien species designated \'REDACTED\'","An unknown alien species")] have raided [affected_dest.name] today, stealing wildlife, farm animals, medical research materials and kidnapping civilians. It seems they desire to learn more about us, so the Navy will be standing by to accomodate them next time they try."
|
||||
if(AI_LIBERATION)
|
||||
newMsg.body = "A [pick("\'REDACTED\' was detected on","S.E.L.F operative infiltrated","malignant computer virus was detected on","rogue [pick("slicer","hacker")] was apprehended on")] [affected_dest.name] today, and managed to infect [pick("\'REDACTED\'","a sentient sub-system","a class one AI","a sentient defence installation")] before it could be stopped. Many lives were lost as it systematically begin murdering civilians, and considerable work must be done to repair the affected areas."
|
||||
body = "A [pick("\'REDACTED\' was detected on","S.E.L.F operative infiltrated","malignant computer virus was detected on","rogue [pick("slicer","hacker")] was apprehended on")] [affected_dest.name] today, and managed to infect [pick("\'REDACTED\'","a sentient sub-system","a class one AI","a sentient defence installation")] before it could be stopped. Many lives were lost as it systematically begin murdering civilians, and considerable work must be done to repair the affected areas."
|
||||
if(MOURNING)
|
||||
newMsg.body = "[pick("The popular","The well-liked","The eminent","The well-known")] [pick("professor","entertainer","singer","researcher","public servant","administrator","ship captain","\'REDACTED\'")], [pick( random_name(pick(MALE,FEMALE)), 40; "\'REDACTED\'" )] has [pick("passed away","committed suicide","been murdered","died in a freakish accident")] on [affected_dest.name] today. The entire planet is in mourning, and prices have dropped for industrial goods as worker morale drops."
|
||||
body = "[pick("The popular","The well-liked","The eminent","The well-known")] [pick("professor","entertainer","singer","researcher","public servant","administrator","ship captain","\'REDACTED\'")], [pick( random_name(pick(MALE,FEMALE)), 40; "\'REDACTED\'" )] has [pick("passed away","committed suicide","been murdered","died in a freakish accident")] on [affected_dest.name] today. The entire planet is in mourning, and prices have dropped for industrial goods as worker morale drops."
|
||||
if(CULT_CELL_REVEALED)
|
||||
newMsg.body = "A [pick("dastardly","blood-thirsty","villanous","crazed")] cult of [pick("The Elder Gods","Nar'sie","an apocalyptic sect","\'REDACTED\'")] has [pick("been discovered","been revealed","revealed themselves","gone public")] on [affected_dest.name] earlier today. Public morale has been shaken due to [pick("certain","several","one or two")] [pick("high-profile","well known","popular")] individuals [pick("performing \'REDACTED\' acts","claiming allegiance to the cult","swearing loyalty to the cult leader","promising to aid to the cult")] before those involved could be brought to justice. The editor reminds all personnel that supernatural myths will not be tolerated on NanoTrasen facilities."
|
||||
body = "A [pick("dastardly","blood-thirsty","villanous","crazed")] cult of [pick("The Elder Gods","Nar'sie","an apocalyptic sect","\'REDACTED\'")] has [pick("been discovered","been revealed","revealed themselves","gone public")] on [affected_dest.name] earlier today. Public morale has been shaken due to [pick("certain","several","one or two")] [pick("high-profile","well known","popular")] individuals [pick("performing \'REDACTED\' acts","claiming allegiance to the cult","swearing loyalty to the cult leader","promising to aid to the cult")] before those involved could be brought to justice. The editor reminds all personnel that supernatural myths will not be tolerated on NanoTrasen facilities."
|
||||
if(SECURITY_BREACH)
|
||||
newMsg.body = "There was [pick("a security breach in","an unauthorised access in","an attempted theft in","an anarchist attack in","violent sabotage of")] a [pick("high-security","restricted access","classified","\'REDACTED\'")] [pick("\'REDACTED\'","section","zone","area")] this morning. Security was tightened on [affected_dest.name] after the incident, and the editor reassures all NanoTrasen personnel that such lapses are rare."
|
||||
body = "There was [pick("a security breach in","an unauthorised access in","an attempted theft in","an anarchist attack in","violent sabotage of")] a [pick("high-security","restricted access","classified","\'REDACTED\'")] [pick("\'REDACTED\'","section","zone","area")] this morning. Security was tightened on [affected_dest.name] after the incident, and the editor reassures all NanoTrasen personnel that such lapses are rare."
|
||||
if(ANIMAL_RIGHTS_RAID)
|
||||
newMsg.body = "[pick("Militant animal rights activists","Members of the terrorist group Animal Rights Consortium","Members of the terrorist group \'REDACTED\'")] have [pick("launched a campaign of terror","unleashed a swathe of destruction","raided farms and pastures","forced entry to \'REDACTED\'")] on [affected_dest.name] earlier today, freeing numerous [pick("farm animals","animals","\'REDACTED\'")]. Prices for tame and breeding animals have spiked as a result."
|
||||
body = "[pick("Militant animal rights activists","Members of the terrorist group Animal Rights Consortium","Members of the terrorist group \'REDACTED\'")] have [pick("launched a campaign of terror","unleashed a swathe of destruction","raided farms and pastures","forced entry to \'REDACTED\'")] on [affected_dest.name] earlier today, freeing numerous [pick("farm animals","animals","\'REDACTED\'")]. Prices for tame and breeding animals have spiked as a result."
|
||||
if(FESTIVAL)
|
||||
newMsg.body = "A [pick("festival","week long celebration","day of revelry","planet-wide holiday")] has been declared on [affected_dest.name] by [pick("Governor","Commissioner","General","Commandant","Administrator")] [random_name(pick(MALE,FEMALE))] to celebrate [pick("the birth of their [pick("son","daughter")]","coming of age of their [pick("son","daughter")]","the pacification of rogue military cell","the apprehension of a violent criminal who had been terrorising the planet")]. Massive stocks of food and meat have been bought driving up prices across the planet."
|
||||
body = "A [pick("festival","week long celebration","day of revelry","planet-wide holiday")] has been declared on [affected_dest.name] by [pick("Governor","Commissioner","General","Commandant","Administrator")] [random_name(pick(MALE,FEMALE))] to celebrate [pick("the birth of their [pick("son","daughter")]","coming of age of their [pick("son","daughter")]","the pacification of rogue military cell","the apprehension of a violent criminal who had been terrorising the planet")]. Massive stocks of food and meat have been bought driving up prices across the planet."
|
||||
|
||||
for(var/datum/feed_channel/FC in news_network.network_channels)
|
||||
if(FC.channel_name == "Nyx Daily")
|
||||
FC.messages += newMsg
|
||||
break
|
||||
for(var/obj/machinery/newscaster/NEWSCASTER in allCasters)
|
||||
NEWSCASTER.newsAlert("Nyx Daily")
|
||||
news_network.SubmitArticle(body, author, channel, null, 1)
|
||||
|
||||
/datum/event/economic_event/end()
|
||||
for(var/good_type in dearer_goods)
|
||||
|
||||
@@ -11,78 +11,76 @@
|
||||
if(!event_type)
|
||||
return
|
||||
|
||||
//copy-pasted from the admin verbs to submit new newscaster messages
|
||||
var/datum/feed_message/newMsg = new /datum/feed_message
|
||||
newMsg.author = "Nyx Daily"
|
||||
newMsg.is_admin_message = 1
|
||||
var/author = "Nyx Daily"
|
||||
var/channel = author
|
||||
|
||||
//see if our location has custom event info for this event
|
||||
newMsg.body = affected_dest.get_custom_eventstring()
|
||||
if(!newMsg.body)
|
||||
newMsg.body = ""
|
||||
var/body = affected_dest.get_custom_eventstring()
|
||||
if(!body)
|
||||
body = ""
|
||||
switch(event_type)
|
||||
if(RESEARCH_BREAKTHROUGH)
|
||||
newMsg.body = "A major breakthough in the field of [pick("phoron research","super-compressed materials","nano-augmentation","bluespace research","volatile power manipulation")] \
|
||||
body = "A major breakthough in the field of [pick("phoron research","super-compressed materials","nano-augmentation","bluespace research","volatile power manipulation")] \
|
||||
was announced [pick("yesterday","a few days ago","last week","earlier this month")] by a private firm on [affected_dest.name]. \
|
||||
NanoTrasen declined to comment as to whether this could impinge on profits."
|
||||
|
||||
if(ELECTION)
|
||||
newMsg.body = "The pre-selection of an additional candidates was announced for the upcoming [pick("supervisors council","advisory board","governership","board of inquisitors")] \
|
||||
body = "The pre-selection of an additional candidates was announced for the upcoming [pick("supervisors council","advisory board","governership","board of inquisitors")] \
|
||||
election on [affected_dest.name] was announced earlier today, \
|
||||
[pick("media mogul","web celebrity", "industry titan", "superstar", "famed chef", "popular gardener", "ex-army officer", "multi-billionaire")] \
|
||||
[random_name(pick(MALE,FEMALE))]. In a statement to the media they said '[pick("My only goal is to help the [pick("sick","poor","children")]",\
|
||||
"I will maintain NanoTrasen's record profits","I believe in our future","We must return to our moral core","Just like... chill out dudes")]'."
|
||||
|
||||
if(RESIGNATION)
|
||||
newMsg.body = "NanoTrasen regretfully announces the resignation of [pick("Sector Admiral","Division Admiral","Ship Admiral","Vice Admiral")] [random_name(pick(MALE,FEMALE))]."
|
||||
body = "NanoTrasen regretfully announces the resignation of [pick("Sector Admiral","Division Admiral","Ship Admiral","Vice Admiral")] [random_name(pick(MALE,FEMALE))]."
|
||||
if(prob(25))
|
||||
var/locstring = pick("Segunda","Salusa","Cepheus","Andromeda","Gruis","Corona","Aquila","Asellus") + " " + pick("I","II","III","IV","V","VI","VII","VIII")
|
||||
newMsg.body += " In a ceremony on [affected_dest.name] this afternoon, they will be awarded the \
|
||||
body += " In a ceremony on [affected_dest.name] this afternoon, they will be awarded the \
|
||||
[pick("Red Star of Sacrifice","Purple Heart of Heroism","Blue Eagle of Loyalty","Green Lion of Ingenuity")] for "
|
||||
if(prob(33))
|
||||
newMsg.body += "their actions at the Battle of [pick(locstring,"REDACTED")]."
|
||||
body += "their actions at the Battle of [pick(locstring,"REDACTED")]."
|
||||
else if(prob(50))
|
||||
newMsg.body += "their contribution to the colony of [locstring]."
|
||||
body += "their contribution to the colony of [locstring]."
|
||||
else
|
||||
newMsg.body += "their loyal service over the years."
|
||||
body += "their loyal service over the years."
|
||||
else if(prob(33))
|
||||
newMsg.body += " They are expected to settle down in [affected_dest.name], where they have been granted a handsome pension."
|
||||
body += " They are expected to settle down in [affected_dest.name], where they have been granted a handsome pension."
|
||||
else if(prob(50))
|
||||
newMsg.body += " The news was broken on [affected_dest.name] earlier today, where they cited reasons of '[pick("health","family","REDACTED")]'"
|
||||
body += " The news was broken on [affected_dest.name] earlier today, where they cited reasons of '[pick("health","family","REDACTED")]'"
|
||||
else
|
||||
newMsg.body += " Administration Aerospace wishes them the best of luck in their retirement ceremony on [affected_dest.name]."
|
||||
body += " Administration Aerospace wishes them the best of luck in their retirement ceremony on [affected_dest.name]."
|
||||
|
||||
if(CELEBRITY_DEATH)
|
||||
newMsg.body = "It is with regret today that we announce the sudden passing of the "
|
||||
body = "It is with regret today that we announce the sudden passing of the "
|
||||
if(prob(33))
|
||||
newMsg.body += "[pick("distinguished","decorated","veteran","highly respected")] \
|
||||
body += "[pick("distinguished","decorated","veteran","highly respected")] \
|
||||
[pick("Ship's Captain","Vice Admiral","Colonel","Lieutenant Colonel")] "
|
||||
else if(prob(50))
|
||||
newMsg.body += "[pick("award-winning","popular","highly respected","trend-setting")] \
|
||||
body += "[pick("award-winning","popular","highly respected","trend-setting")] \
|
||||
[pick("comedian","singer/songwright","artist","playwright","TV personality","model")] "
|
||||
else
|
||||
newMsg.body += "[pick("successful","highly respected","ingenious","esteemed")] \
|
||||
body += "[pick("successful","highly respected","ingenious","esteemed")] \
|
||||
[pick("academic","Professor","Doctor","Scientist")] "
|
||||
|
||||
newMsg.body += "[random_name(pick(MALE,FEMALE))] on [affected_dest.name] [pick("last week","yesterday","this morning","two days ago","three days ago")]\
|
||||
body += "[random_name(pick(MALE,FEMALE))] on [affected_dest.name] [pick("last week","yesterday","this morning","two days ago","three days ago")]\
|
||||
[pick(". Assassination is suspected, but the perpetrators have not yet been brought to justice",\
|
||||
" due to Syndicate infiltrators (since captured)",\
|
||||
" due to mercenary infiltrators (since captured)",\
|
||||
" during an industrial accident",\
|
||||
" due to [pick("heart failure","kidney failure","liver failure","brain hemorrhage")]")]"
|
||||
|
||||
if(BARGAINS)
|
||||
newMsg.body += "BARGAINS! BARGAINS! BARGAINS! Commerce Control on [affected_dest.name] wants you to know that everything must go! Across all retail centres, \
|
||||
body += "BARGAINS! BARGAINS! BARGAINS! Commerce Control on [affected_dest.name] wants you to know that everything must go! Across all retail centres, \
|
||||
all goods are being slashed, and all retailors are onboard - so come on over for the \[shopping\] time of your life."
|
||||
|
||||
if(SONG_DEBUT)
|
||||
newMsg.body += "[pick("Singer","Singer/songwriter","Saxophonist","Pianist","Guitarist","TV personality","Star")] [random_name(pick(MALE,FEMALE))] \
|
||||
body += "[pick("Singer","Singer/songwriter","Saxophonist","Pianist","Guitarist","TV personality","Star")] [random_name(pick(MALE,FEMALE))] \
|
||||
announced the debut of their new [pick("single","album","EP","label")] '[pick("Everyone's","Look at the","Baby don't eye those","All of those","Dirty nasty")] \
|
||||
[pick("roses","three stars","starships","nanobots","cyborgs","Skrell","Sren'darr")] \
|
||||
[pick("on Venus","on Reade","on Moghes","in my hand","slip through my fingers","die for you","sing your heart out","fly away")]' \
|
||||
with [pick("pre-puchases available","a release tour","cover signings","a launch concert")] on [affected_dest.name]."
|
||||
|
||||
if(MOVIE_RELEASE)
|
||||
newMsg.body += "From the [pick("desk","home town","homeworld","mind")] of [pick("acclaimed","award-winning","popular","stellar")] \
|
||||
body += "From the [pick("desk","home town","homeworld","mind")] of [pick("acclaimed","award-winning","popular","stellar")] \
|
||||
[pick("playwright","author","director","actor","TV star")] [random_name(pick(MALE,FEMALE))] comes the latest sensation: '\
|
||||
[pick("Deadly","The last","Lost","Dead")] [pick("Starships","Warriors","outcasts","Tajarans","Unathi","Skrell")] \
|
||||
[pick("of","from","raid","go hunting on","visit","ravage","pillage","destroy")] \
|
||||
@@ -90,57 +88,51 @@
|
||||
. Own it on webcast today, or visit the galactic premier on [affected_dest.name]!"
|
||||
|
||||
if(BIG_GAME_HUNTERS)
|
||||
newMsg.body += "Game hunters on [affected_dest.name] "
|
||||
body += "Game hunters on [affected_dest.name] "
|
||||
if(prob(33))
|
||||
newMsg.body += "were surprised when an unusual species experts have since identified as \
|
||||
body += "were surprised when an unusual species experts have since identified as \
|
||||
[pick("a subclass of mammal","a divergent abhuman species","an intelligent species of lemur","organic/cyborg hybrids")] turned up. Believed to have been brought in by \
|
||||
[pick("alien smugglers","early colonists","syndicate raiders","unwitting tourists")], this is the first such specimen discovered in the wild."
|
||||
[pick("alien smugglers","early colonists","mercenary raiders","unwitting tourists")], this is the first such specimen discovered in the wild."
|
||||
else if(prob(50))
|
||||
newMsg.body += "were attacked by a vicious [pick("nas'r","diyaab","samak","predator which has not yet been identified")]\
|
||||
body += "were attacked by a vicious [pick("nas'r","diyaab","samak","predator which has not yet been identified")]\
|
||||
. Officials urge caution, and locals are advised to stock up on armaments."
|
||||
else
|
||||
newMsg.body += "brought in an unusually [pick("valuable","rare","large","vicious","intelligent")] [pick("mammal","predator","farwa","samak")] for inspection \
|
||||
body += "brought in an unusually [pick("valuable","rare","large","vicious","intelligent")] [pick("mammal","predator","farwa","samak")] for inspection \
|
||||
[pick("today","yesterday","last week")]. Speculators suggest they may be tipped to break several records."
|
||||
|
||||
if(GOSSIP)
|
||||
newMsg.body += "[pick("TV host","Webcast personality","Superstar","Model","Actor","Singer")] [random_name(pick(MALE,FEMALE))] "
|
||||
body += "[pick("TV host","Webcast personality","Superstar","Model","Actor","Singer")] [random_name(pick(MALE,FEMALE))] "
|
||||
if(prob(33))
|
||||
newMsg.body += "and their partner announced the birth of their [pick("first","second","third")] child on [affected_dest.name] early this morning. \
|
||||
body += "and their partner announced the birth of their [pick("first","second","third")] child on [affected_dest.name] early this morning. \
|
||||
Doctors say the child is well, and the parents are considering "
|
||||
if(prob(50))
|
||||
newMsg.body += capitalize(pick(first_names_female))
|
||||
body += capitalize(pick(first_names_female))
|
||||
else
|
||||
newMsg.body += capitalize(pick(first_names_male))
|
||||
newMsg.body += " for the name."
|
||||
body += capitalize(pick(first_names_male))
|
||||
body += " for the name."
|
||||
else if(prob(50))
|
||||
newMsg.body += "announced their [pick("split","break up","marriage","engagement")] with [pick("TV host","webcast personality","superstar","model","actor","singer")] \
|
||||
body += "announced their [pick("split","break up","marriage","engagement")] with [pick("TV host","webcast personality","superstar","model","actor","singer")] \
|
||||
[random_name(pick(MALE,FEMALE))] at [pick("a society ball","a new opening","a launch","a club")] on [affected_dest.name] yesterday, pundits are shocked."
|
||||
else
|
||||
newMsg.body += "is recovering from plastic surgery in a clinic on [affected_dest.name] for the [pick("second","third","fourth")] time, reportedly having made the decision in response to "
|
||||
newMsg.body += "[pick("unkind comments by an ex","rumours started by jealous friends",\
|
||||
body += "is recovering from plastic surgery in a clinic on [affected_dest.name] for the [pick("second","third","fourth")] time, reportedly having made the decision in response to "
|
||||
body += "[pick("unkind comments by an ex","rumours started by jealous friends",\
|
||||
"the decision to be dropped by a major sponsor","a disasterous interview on Nyx Tonight")]."
|
||||
if(TOURISM)
|
||||
newMsg.body += "Tourists are flocking to [affected_dest.name] after the surprise announcement of [pick("major shopping bargains by a wily retailer",\
|
||||
body += "Tourists are flocking to [affected_dest.name] after the surprise announcement of [pick("major shopping bargains by a wily retailer",\
|
||||
"a huge new ARG by a popular entertainment company","a secret tour by popular artiste [random_name(pick(MALE,FEMALE))]")]. \
|
||||
Nyx Daily is offering discount tickets for two to see [random_name(pick(MALE,FEMALE))] live in return for eyewitness reports and up to the minute coverage."
|
||||
|
||||
for(var/datum/feed_channel/FC in news_network.network_channels)
|
||||
if(FC.channel_name == "Nyx Daily")
|
||||
FC.messages += newMsg
|
||||
break
|
||||
for(var/obj/machinery/newscaster/NEWSCASTER in allCasters)
|
||||
NEWSCASTER.newsAlert("Nyx Daily")
|
||||
news_network.SubmitArticle(body, author, channel, null, 1)
|
||||
|
||||
/datum/event/trivial_news
|
||||
endWhen = 10
|
||||
|
||||
/datum/event/trivial_news/announce()
|
||||
//copy-pasted from the admin verbs to submit new newscaster messages
|
||||
var/datum/feed_message/newMsg = new /datum/feed_message
|
||||
newMsg.author = "Editor Mike Hammers"
|
||||
//newMsg.is_admin_message = 1
|
||||
var/author = "Editor Mike Hammers"
|
||||
var/channel = "The Gibson Gazette"
|
||||
|
||||
var/datum/trade_destination/affected_dest = pick(weighted_mundaneevent_locations)
|
||||
newMsg.body = pick(
|
||||
var/body = pick(
|
||||
"Tree stuck in tajaran; firefighters baffled.",\
|
||||
"Armadillos want aardvarks removed from dictionary claims 'here first'.",\
|
||||
"Angel found dancing on pinhead ordered to stop; cited for public nuisance.",\
|
||||
@@ -175,7 +167,7 @@
|
||||
"Mysterious Loud Rumbling Noises In [affected_dest.name] Found To Be Mysterious Loud Rumblings",\
|
||||
"Alien ambassador becomes lost on [affected_dest.name], refuses to ask for directions",\
|
||||
"Swamp Gas Verified To Be Exhalations Of Stars--Movie Stars--Long Passed",\
|
||||
"Tainted Broccoli Weapon Of Choice For Syndicate Assassins",\
|
||||
"Tainted Broccoli Weapon Of Choice For Efficient Assassins",\
|
||||
"Chefs Find Broccoli Effective Tool For Cutting Cheese",\
|
||||
"Broccoli Found To Cause Grumpiness In Monkeys",\
|
||||
"Survey: 80% Of People on [affected_dest.name] Love Clog-Dancing",\
|
||||
@@ -225,9 +217,4 @@
|
||||
"Broccoli discovered to be colonies of tiny aliens with murder on their minds"\
|
||||
)
|
||||
|
||||
for(var/datum/feed_channel/FC in news_network.network_channels)
|
||||
if(FC.channel_name == "The Gibson Gazette")
|
||||
FC.messages += newMsg
|
||||
break
|
||||
for(var/obj/machinery/newscaster/NEWSCASTER in allCasters)
|
||||
NEWSCASTER.newsAlert("The Gibson Gazette")
|
||||
news_network.SubmitArticle(body, author, channel, null, 1)
|
||||
|
||||
@@ -157,8 +157,7 @@ proc/spawn_money(var/sum, spawnloc, mob/living/carbon/human/human_user as mob)
|
||||
desc = "A card that holds an amount of money."
|
||||
var/owner_name = "" //So the ATM can set it so the EFTPOS can put a valid name on transactions.
|
||||
|
||||
/obj/item/weapon/spacecash/ewallet/examine()
|
||||
set src in view()
|
||||
..()
|
||||
if (!(usr in view(2)) && usr!=src.loc) return
|
||||
usr << "\blue Charge card's owner: [src.owner_name]. Thalers remaining: [src.worth]."
|
||||
/obj/item/weapon/spacecash/ewallet/examine(mob/user)
|
||||
..(user)
|
||||
if (!(user in view(2)) && user!=src.loc) return
|
||||
user << "\blue Charge card's owner: [src.owner_name]. Thalers remaining: [src.worth]."
|
||||
|
||||
@@ -77,26 +77,8 @@ var/global/economy_init = 0
|
||||
if(economy_init)
|
||||
return 2
|
||||
|
||||
var/datum/feed_channel/newChannel = new /datum/feed_channel
|
||||
newChannel.channel_name = "Public Station Announcements"
|
||||
newChannel.author = "Automated Announcement Listing"
|
||||
newChannel.locked = 1
|
||||
newChannel.is_admin_channel = 1
|
||||
news_network.network_channels += newChannel
|
||||
|
||||
newChannel = new /datum/feed_channel
|
||||
newChannel.channel_name = "Nyx Daily"
|
||||
newChannel.author = "CentComm Minister of Information"
|
||||
newChannel.locked = 1
|
||||
newChannel.is_admin_channel = 1
|
||||
news_network.network_channels += newChannel
|
||||
|
||||
newChannel = new /datum/feed_channel
|
||||
newChannel.channel_name = "The Gibson Gazette"
|
||||
newChannel.author = "Editor Mike Hammers"
|
||||
newChannel.locked = 1
|
||||
newChannel.is_admin_channel = 1
|
||||
news_network.network_channels += newChannel
|
||||
news_network.CreateFeedChannel("Nyx Daily", "CentComm Minister of Information", 1, 1)
|
||||
news_network.CreateFeedChannel("The Gibson Gazette", "Editor Mike Hammers", 1, 1)
|
||||
|
||||
for(var/loc_type in typesof(/datum/trade_destination) - /datum/trade_destination)
|
||||
var/datum/trade_destination/D = new loc_type
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
/datum/event/alien_infestation
|
||||
announceWhen = 400
|
||||
oneShot = 1
|
||||
|
||||
var/spawncount = 1
|
||||
var/successSpawn = 0 //So we don't make a command report if nothing gets spawned.
|
||||
@@ -21,7 +20,7 @@
|
||||
/datum/event/alien_infestation/start()
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in machines)
|
||||
if(temp_vent.loc.z == 1 && !temp_vent.welded && temp_vent.network)
|
||||
if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in config.station_levels)
|
||||
if(temp_vent.network.normal_members.len > 50) //Stops Aliens getting stuck in small networks. See: Security, Virology
|
||||
vents += temp_vent
|
||||
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
//Cortical borer spawn event - care of RobRichards1997 with minor editing by Zuhayr.
|
||||
|
||||
/datum/event/borer_infestation
|
||||
oneShot = 1
|
||||
|
||||
/datum/event/borer_infestation
|
||||
announceWhen = 400
|
||||
|
||||
@@ -20,7 +16,7 @@
|
||||
/datum/event/borer_infestation/start()
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in world)
|
||||
if(temp_vent.loc.z == 1 && !temp_vent.welded && temp_vent.network)
|
||||
if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in config.station_levels)
|
||||
//Stops cortical borers getting stuck in small networks. See: Security, Virology
|
||||
if(temp_vent.network.normal_members.len > 50)
|
||||
vents += temp_vent
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
/datum/event/brand_intelligence
|
||||
announceWhen = 21
|
||||
endWhen = 1000 //Ends when all vending machines are subverted anyway.
|
||||
oneShot = 1
|
||||
|
||||
var/list/obj/machinery/vending/vendingMachines = list()
|
||||
var/list/obj/machinery/vending/infectedVendingMachines = list()
|
||||
@@ -14,7 +13,7 @@
|
||||
|
||||
/datum/event/brand_intelligence/start()
|
||||
for(var/obj/machinery/vending/V in machines)
|
||||
if(V.z != 1) continue
|
||||
if(isNotStationLevel(V.z)) continue
|
||||
vendingMachines.Add(V)
|
||||
|
||||
if(!vendingMachines.len)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/datum/event/carp_migration
|
||||
announceWhen = 50
|
||||
oneShot = 1
|
||||
endWhen = 900
|
||||
endWhen = 900
|
||||
|
||||
var/list/spawned_carp = list()
|
||||
|
||||
/datum/event/carp_migration/setup()
|
||||
@@ -9,12 +9,28 @@
|
||||
endWhen = rand(600,1200)
|
||||
|
||||
/datum/event/carp_migration/announce()
|
||||
command_announcement.Announce("Unknown biological entities have been detected near [station_name()], please stand-by.", "Lifesign Alert")
|
||||
var/announcement = ""
|
||||
if(severity == EVENT_LEVEL_MAJOR)
|
||||
announcement = "Massive migration of unknown biological entities has been detected near [station_name()], please stand-by."
|
||||
else
|
||||
announcement = "Unknown biological [spawned_carp.len == 1 ? "entity has" : "entities have"] been detected near [station_name()], please stand-by."
|
||||
command_announcement.Announce(announcement, "Lifesign Alert")
|
||||
|
||||
/datum/event/carp_migration/start()
|
||||
if(severity == EVENT_LEVEL_MAJOR)
|
||||
for(var/i = 1 to rand(3,5))
|
||||
spawn_fish(landmarks_list.len)
|
||||
else if(severity == EVENT_LEVEL_MODERATE)
|
||||
spawn_fish(landmarks_list.len)
|
||||
else
|
||||
spawn_fish(rand(1, 5))
|
||||
|
||||
/datum/event/carp_migration/proc/spawn_fish(var/limit)
|
||||
for(var/obj/effect/landmark/C in landmarks_list)
|
||||
if(C.name == "carpspawn")
|
||||
spawned_carp.Add(new /mob/living/simple_animal/hostile/carp(C.loc))
|
||||
if(spawned_carp.len >= limit)
|
||||
return
|
||||
|
||||
/datum/event/carp_migration/end()
|
||||
for(var/mob/living/simple_animal/hostile/carp/C in spawned_carp)
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
/datum/event/disease_outbreak
|
||||
announceWhen = 15
|
||||
oneShot = 1
|
||||
|
||||
|
||||
/datum/event/disease_outbreak/announce()
|
||||
@@ -17,7 +16,7 @@
|
||||
var/turf/T = get_turf(H)
|
||||
if(!T)
|
||||
continue
|
||||
if(T.z != 1)
|
||||
if(isNotStationLevel(T.z))
|
||||
continue
|
||||
for(var/datum/disease/D in H.viruses)
|
||||
foundAlready = 1
|
||||
|
||||
@@ -1,10 +1,65 @@
|
||||
/datum/event_meta
|
||||
var/name = ""
|
||||
var/enabled = 1 // Whether or not the event is available for random selection at all
|
||||
var/weight = 0 // The base weight of this event. A zero means it may never fire, but see get_weight()
|
||||
var/min_weight = 0 // The minimum weight that this event will have. Only used if non-zero.
|
||||
var/max_weight = 0 // The maximum weight that this event will have. Only use if non-zero.
|
||||
var/severity = 0 // The current severity of this event
|
||||
var/one_shot = 0 //If true, then the event will not be re-added to the list of available events
|
||||
var/list/role_weights = list()
|
||||
var/datum/event/event_type
|
||||
|
||||
/datum/event_meta/New(var/event_severity, var/event_name, var/datum/event/type, var/event_weight, var/list/job_weights, var/is_one_shot = 0, var/min_event_weight = 0, var/max_event_weight = 0)
|
||||
name = event_name
|
||||
severity = event_severity
|
||||
event_type = type
|
||||
one_shot = is_one_shot
|
||||
weight = event_weight
|
||||
min_weight = min_event_weight
|
||||
max_weight = max_event_weight
|
||||
if(job_weights)
|
||||
role_weights = job_weights
|
||||
|
||||
/datum/event_meta/proc/get_weight(var/list/active_with_role)
|
||||
if(!enabled)
|
||||
return 0
|
||||
|
||||
var/job_weight = 0
|
||||
for(var/role in role_weights)
|
||||
if(role in active_with_role)
|
||||
job_weight += active_with_role[role] * role_weights[role]
|
||||
|
||||
var/total_weight = weight + job_weight
|
||||
|
||||
// Only min/max the weight if the values are non-zero
|
||||
if(min_weight && total_weight < min_weight) total_weight = min_weight
|
||||
if(max_weight && total_weight > max_weight) total_weight = max_weight
|
||||
|
||||
return total_weight
|
||||
|
||||
/datum/event_meta/alien/get_weight(var/list/active_with_role)
|
||||
if(config.aliens_allowed)
|
||||
return ..(active_with_role)
|
||||
return 0
|
||||
|
||||
/datum/event_meta/ninja/get_weight(var/list/active_with_role)
|
||||
if(config.ninjas_allowed)
|
||||
return ..(active_with_role)
|
||||
return 0
|
||||
|
||||
/datum/event //NOTE: Times are measured in master controller ticks!
|
||||
var/startWhen = 0 //When in the lifetime to call start().
|
||||
var/announceWhen = 0 //When in the lifetime to call announce().
|
||||
var/endWhen = 0 //When in the lifetime the event should end.
|
||||
var/oneShot = 0 //If true, then the event removes itself from the list of potential events on creation.
|
||||
|
||||
var/severity = 0 //Severity. Lower means less severe, higher means more severe. Does not have to be supported. Is set on New().
|
||||
var/activeFor = 0 //How long the event has existed. You don't need to change this.
|
||||
var/isRunning = 1 //If this event is currently running. You should not change this.
|
||||
var/startedAt = 0 //When this event started.
|
||||
var/endedAt = 0 //When this event ended.
|
||||
var/datum/event_meta/event_meta = null
|
||||
|
||||
/datum/event/nothing
|
||||
|
||||
//Called first before processing.
|
||||
//Allows you to setup your event, such as randomly
|
||||
@@ -41,43 +96,54 @@
|
||||
/datum/event/proc/end()
|
||||
return
|
||||
|
||||
|
||||
//Returns the latest point of event processing.
|
||||
/datum/event/proc/lastProcessAt()
|
||||
return max(startWhen, max(announceWhen, endWhen))
|
||||
|
||||
//Do not override this proc, instead use the appropiate procs.
|
||||
//This proc will handle the calls to the appropiate procs.
|
||||
/datum/event/proc/process()
|
||||
|
||||
if(activeFor > startWhen && activeFor < endWhen)
|
||||
tick()
|
||||
|
||||
if(activeFor == startWhen)
|
||||
isRunning = 1
|
||||
start()
|
||||
|
||||
if(activeFor == announceWhen)
|
||||
announce()
|
||||
|
||||
if(activeFor == endWhen)
|
||||
isRunning = 0
|
||||
end()
|
||||
|
||||
// Everything is done, let's clean up.
|
||||
if(activeFor >= endWhen && activeFor >= announceWhen && activeFor >= startWhen)
|
||||
if(activeFor >= lastProcessAt())
|
||||
kill()
|
||||
|
||||
activeFor++
|
||||
|
||||
|
||||
//Garbage collects the event by removing it from the global events list,
|
||||
//which should be the only place it's referenced.
|
||||
//Called when start(), announce() and end() has all been called.
|
||||
/datum/event/proc/kill()
|
||||
events.Remove(src)
|
||||
// If this event was forcefully killed run end() for individual cleanup
|
||||
if(isRunning)
|
||||
isRunning = 0
|
||||
end()
|
||||
|
||||
endedAt = world.time
|
||||
event_manager.active_events -= src
|
||||
event_manager.event_complete(src)
|
||||
|
||||
/datum/event/New(var/datum/event_meta/EM)
|
||||
// event needs to be responsible for this, as stuff like APLUs currently make their own events for curious reasons
|
||||
event_manager.active_events += src
|
||||
|
||||
event_meta = EM
|
||||
severity = event_meta.severity
|
||||
if(severity < EVENT_LEVEL_MUNDANE) severity = EVENT_LEVEL_MUNDANE
|
||||
if(severity > EVENT_LEVEL_MAJOR) severity = EVENT_LEVEL_MAJOR
|
||||
|
||||
startedAt = world.time
|
||||
|
||||
//Adds the event to the global events list, and removes it from the list
|
||||
//of potential events.
|
||||
/datum/event/New()
|
||||
setup()
|
||||
events.Add(src)
|
||||
/*if(oneShot)
|
||||
potentialRandomEvents.Remove(type)*/
|
||||
..()
|
||||
|
||||
179
code/modules/events/event_container.dm
Normal file
179
code/modules/events/event_container.dm
Normal file
@@ -0,0 +1,179 @@
|
||||
#define ASSIGNMENT_ANY "Any"
|
||||
#define ASSIGNMENT_AI "AI"
|
||||
#define ASSIGNMENT_CYBORG "Cyborg"
|
||||
#define ASSIGNMENT_ENGINEER "Engineer"
|
||||
#define ASSIGNMENT_GARDENER "Gardener"
|
||||
#define ASSIGNMENT_JANITOR "Janitor"
|
||||
#define ASSIGNMENT_MEDICAL "Medical"
|
||||
#define ASSIGNMENT_SCIENTIST "Scientist"
|
||||
#define ASSIGNMENT_SECURITY "Security"
|
||||
|
||||
var/global/list/severity_to_string = list(EVENT_LEVEL_MUNDANE = "Mundane", EVENT_LEVEL_MODERATE = "Moderate", EVENT_LEVEL_MAJOR = "Major")
|
||||
|
||||
/datum/event_container
|
||||
var/severity = -1
|
||||
var/delayed = 0
|
||||
var/delay_modifier = 1
|
||||
var/next_event_time = 0
|
||||
var/list/available_events
|
||||
var/list/last_event_time = list()
|
||||
var/datum/event_meta/next_event = null
|
||||
|
||||
var/last_world_time = 0
|
||||
|
||||
/datum/event_container/proc/process()
|
||||
if(!next_event_time)
|
||||
set_event_delay()
|
||||
|
||||
if(delayed)
|
||||
next_event_time += (world.time - last_world_time)
|
||||
else if(world.time > next_event_time)
|
||||
start_event()
|
||||
|
||||
last_world_time = world.time
|
||||
|
||||
/datum/event_container/proc/start_event()
|
||||
if(!next_event) // If non-one has explicitly set an event, randomly pick one
|
||||
next_event = acquire_event()
|
||||
|
||||
// Has an event been acquired?
|
||||
if(next_event)
|
||||
// Set when the event of this type was last fired, and prepare the next event start
|
||||
last_event_time[next_event] = world.time
|
||||
set_event_delay()
|
||||
next_event.enabled = !next_event.one_shot // This event will no longer be available in the random rotation if one shot
|
||||
|
||||
new next_event.event_type(next_event) // Events are added and removed from the processing queue in their New/kill procs
|
||||
|
||||
log_debug("Starting event '[next_event.name]' of severity [severity_to_string[severity]].")
|
||||
next_event = null // When set to null, a random event will be selected next time
|
||||
else
|
||||
// If not, wait for one minute, instead of one tick, before checking again.
|
||||
next_event_time += (60 * 10)
|
||||
|
||||
|
||||
/datum/event_container/proc/acquire_event()
|
||||
if(available_events.len == 0)
|
||||
return
|
||||
var/active_with_role = number_active_with_role()
|
||||
|
||||
var/list/possible_events = list()
|
||||
for(var/datum/event_meta/EM in available_events)
|
||||
var/event_weight = EM.get_weight(active_with_role)
|
||||
if(EM.enabled && event_weight)
|
||||
possible_events[EM] = event_weight
|
||||
|
||||
for(var/event_meta in last_event_time) if(possible_events[event_meta])
|
||||
var/time_passed = world.time - event_last_fired[event_meta]
|
||||
var/weight_modifier = max(0, (config.expected_round_length - time_passed) / 300)
|
||||
var/new_weight = max(possible_events[event_meta] - weight_modifier, 0)
|
||||
|
||||
if(new_weight)
|
||||
possible_events[event_meta] = new_weight
|
||||
else
|
||||
possible_events -= event_meta
|
||||
|
||||
if(possible_events.len == 0)
|
||||
return null
|
||||
|
||||
// Select an event and remove it from the pool of available events
|
||||
var/picked_event = pickweight(possible_events)
|
||||
available_events -= picked_event
|
||||
return picked_event
|
||||
|
||||
/datum/event_container/proc/set_event_delay()
|
||||
// If the next event time has not yet been set and we have a custom first time start
|
||||
if(next_event_time == 0 && config.event_first_run[severity])
|
||||
var/lower = config.event_first_run[severity]["lower"]
|
||||
var/upper = config.event_first_run[severity]["upper"]
|
||||
var/event_delay = rand(lower, upper)
|
||||
next_event_time = world.time + event_delay
|
||||
// Otherwise, follow the standard setup process
|
||||
else
|
||||
var/playercount_modifier = 1
|
||||
switch(player_list.len)
|
||||
if(0 to 10)
|
||||
playercount_modifier = 1.2
|
||||
if(11 to 15)
|
||||
playercount_modifier = 1.1
|
||||
if(16 to 25)
|
||||
playercount_modifier = 1
|
||||
if(26 to 35)
|
||||
playercount_modifier = 0.9
|
||||
if(36 to 100000)
|
||||
playercount_modifier = 0.8
|
||||
playercount_modifier = playercount_modifier * delay_modifier
|
||||
|
||||
var/event_delay = rand(config.event_delay_lower[severity], config.event_delay_upper[severity]) * playercount_modifier
|
||||
next_event_time = world.time + event_delay
|
||||
|
||||
log_debug("Next event of severity [severity_to_string[severity]] in [(next_event_time - world.time)/600] minutes.")
|
||||
|
||||
/datum/event_container/proc/SelectEvent()
|
||||
var/datum/event_meta/EM = input("Select an event to queue up.", "Event Selection", null) as null|anything in available_events
|
||||
if(!EM)
|
||||
return
|
||||
if(next_event)
|
||||
available_events += next_event
|
||||
available_events -= EM
|
||||
next_event = EM
|
||||
return EM
|
||||
|
||||
/datum/event_container/mundane
|
||||
severity = EVENT_LEVEL_MUNDANE
|
||||
available_events = list(
|
||||
// Severity level, event name, even type, base weight, role weights, one shot, min weight, max weight. Last two only used if set and non-zero
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Nothing", /datum/event/nothing, 100),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "PDA Spam", /datum/event/pda_spam, 0, list(ASSIGNMENT_ANY = 4), 0, 25, 50),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Money Lotto", /datum/event/money_lotto, 0, list(ASSIGNMENT_ANY = 1), 1, 5, 15),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Money Hacker", /datum/event/money_hacker, 0, list(ASSIGNMENT_ANY = 4), 1, 10, 25),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Economic News", /datum/event/economic_event, 300),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Trivial News", /datum/event/trivial_news, 400),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Mundane News", /datum/event/mundane_news, 300),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Lost Carp", /datum/event/carp_migration, 20, list(ASSIGNMENT_SECURITY = 10), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Brand Intelligence",/datum/event/brand_intelligence,20, list(ASSIGNMENT_JANITOR = 25), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Vermin Infestation",/datum/event/infestation, 100, list(ASSIGNMENT_JANITOR = 100)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Wallrot", /datum/event/wallrot, 0, list(ASSIGNMENT_ENGINEER = 30, ASSIGNMENT_GARDENER = 50)),
|
||||
)
|
||||
|
||||
/datum/event_container/moderate
|
||||
severity = EVENT_LEVEL_MODERATE
|
||||
available_events = list(
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Nothing", /datum/event/nothing, 10),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Carp School", /datum/event/carp_migration, 20, list(ASSIGNMENT_SECURITY = 10), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Rogue Drones", /datum/event/rogue_drone, 5, list(ASSIGNMENT_ENGINEER = 25, ASSIGNMENT_SECURITY = 25)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Space vines", /datum/event/spacevine, 10, list(ASSIGNMENT_ENGINEER = 5)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Meteor Shower", /datum/event/meteor_shower, 0, list(ASSIGNMENT_ENGINEER = 10)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Communication Blackout", /datum/event/communications_blackout, 50, list(ASSIGNMENT_AI = 25, ASSIGNMENT_SECURITY = 25)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Prison Break", /datum/event/prison_break, 0, list(ASSIGNMENT_SECURITY = 50)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Grid Check", /datum/event/grid_check, 25, list(ASSIGNMENT_ENGINEER = 10)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Electrical Storm", /datum/event/electrical_storm, 15, list(ASSIGNMENT_ENGINEER = 5, ASSIGNMENT_JANITOR = 15)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Radiation Storm", /datum/event/radiation_storm, 0, list(ASSIGNMENT_MEDICAL = 10), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Appendicitis", /datum/event/spontaneous_appendicitis, 0, list(ASSIGNMENT_MEDICAL = 10), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Viral Infection", /datum/event/viral_infection, 0, list(ASSIGNMENT_MEDICAL = 10)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Spider Infestation", /datum/event/spider_infestation, 5, list(ASSIGNMENT_SECURITY = 5), 1),
|
||||
new /datum/event_meta/alien(EVENT_LEVEL_MODERATE, "Alien Infestation", /datum/event/alien_infestation, 2.5,list(ASSIGNMENT_SECURITY = 1), 1, 0, 5),
|
||||
new /datum/event_meta/ninja(EVENT_LEVEL_MODERATE, "Space Ninja", /datum/event/space_ninja, 0, list(ASSIGNMENT_SECURITY = 1), 1, 0, 5),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Ion Storm", /datum/event/ionstorm, 0, list(ASSIGNMENT_AI = 25, ASSIGNMENT_CYBORG = 25, ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_SCIENTIST = 5)),
|
||||
)
|
||||
|
||||
/datum/event_container/major
|
||||
severity = EVENT_LEVEL_MAJOR
|
||||
available_events = list(
|
||||
new /datum/event_meta(EVENT_LEVEL_MAJOR, "Nothing", /datum/event/nothing, 1320),
|
||||
new /datum/event_meta(EVENT_LEVEL_MAJOR, "Carp Migration", /datum/event/carp_migration, 0, list(ASSIGNMENT_SECURITY = 3), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MAJOR, "Viral Infection", /datum/event/viral_infection, 0, list(ASSIGNMENT_MEDICAL = 30), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MAJOR, "Blob", /datum/event/blob, 0, list(ASSIGNMENT_ENGINEER = 60), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MAJOR, "Meteor Wave", /datum/event/meteor_wave, 0, list(ASSIGNMENT_ENGINEER = 3), 1),
|
||||
)
|
||||
|
||||
|
||||
#undef ASSIGNMENT_ANY
|
||||
#undef ASSIGNMENT_AI
|
||||
#undef ASSIGNMENT_CYBORG
|
||||
#undef ASSIGNMENT_ENGINEER
|
||||
#undef ASSIGNMENT_GARDENER
|
||||
#undef ASSIGNMENT_JANITOR
|
||||
#undef ASSIGNMENT_MEDICAL
|
||||
#undef ASSIGNMENT_SCIENTIST
|
||||
#undef ASSIGNMENT_SECURITY
|
||||
@@ -89,9 +89,9 @@ var/list/event_last_fired = list()
|
||||
if(active_with_role["Security"] > 0)
|
||||
if(!sent_spiders_to_station)
|
||||
possibleEvents[/datum/event/spider_infestation] = max(active_with_role["Security"], 5) + 5
|
||||
if(aliens_allowed && !sent_aliens_to_station)
|
||||
if(config.aliens_allowed && !sent_aliens_to_station)
|
||||
possibleEvents[/datum/event/alien_infestation] = max(active_with_role["Security"], 5) + 2.5
|
||||
if(!sent_ninja_to_station && toggle_space_ninja)
|
||||
if(!sent_ninja_to_station && config.ninjas_allowed)
|
||||
possibleEvents[/datum/event/space_ninja] = max(active_with_role["Security"], 5)
|
||||
|
||||
for(var/event_type in event_last_fired) if(possibleEvents[event_type])
|
||||
@@ -187,7 +187,7 @@ var/list/event_last_fired = list()
|
||||
// Returns how many characters are currently active(not logged out, not AFK for more than 10 minutes)
|
||||
// with a specific role.
|
||||
// Note that this isn't sorted by department, because e.g. having a roboticist shouldn't make meteors spawn.
|
||||
/proc/number_active_with_role(role)
|
||||
/proc/number_active_with_role()
|
||||
var/list/active_with_role = list()
|
||||
active_with_role["Engineer"] = 0
|
||||
active_with_role["Medical"] = 0
|
||||
@@ -197,6 +197,7 @@ var/list/event_last_fired = list()
|
||||
active_with_role["Cyborg"] = 0
|
||||
active_with_role["Janitor"] = 0
|
||||
active_with_role["Gardener"] = 0
|
||||
active_with_role["Any"] = player_list.len
|
||||
|
||||
for(var/mob/M in player_list)
|
||||
if(!M.mind || !M.client || M.client.inactivity > 10 * 10 * 60) // longer than 10 minutes AFK counts them as inactive
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user