April sync (#360)

* Maps and things no code/icons

* helpers defines globalvars

* Onclick world.dm orphaned_procs

* subsystems

Round vote and shuttle autocall done here too

* datums

* Game folder

* Admin - chatter modules

* clothing - mining

* modular computers - zambies

* client

* mob level 1

* mob stage 2 + simple_animal

* silicons n brains

* mob stage 3 + Alien/Monkey

* human mobs

* icons updated

* some sounds

* emitter y u no commit

* update tgstation.dme

* compile fixes

* travis fixes

Also removes Fast digest mode, because reasons.

* tweaks for travis Mentors are broke again

Also fixes Sizeray guns

* oxygen loss fix for vore code.

* removes unused code

* some code updates

* bulk fixes

* further fixes

* outside things

* whoops.

* Maint bar ported

* GLOBs.
This commit is contained in:
Poojawa
2017-04-13 23:37:00 -05:00
committed by GitHub
parent cdc32c98fa
commit 7e9b96a00f
1322 changed files with 174827 additions and 23888 deletions
+7 -6
View File
@@ -25,6 +25,7 @@
#define ui_lingstingdisplay "WEST:6,CENTER-3:11"
#define ui_crafting "12:-10,1:5"
#define ui_building "12:-10,1:21"
#define ui_language_menu "11:6,2:-11"
#define ui_devilsouldisplay "WEST:6,CENTER-1:15"
@@ -61,16 +62,16 @@
#define ui_borg_store "CENTER+2:16,SOUTH:5" //borgs
#define ui_borg_camera "CENTER+3:21,SOUTH:5" //borgs
#define ui_borg_album "CENTER+4:21,SOUTH:5" //borgs
#define ui_borg_talk_wheel "CENTER+4:21,SOUTH+1:5" //borgs
#define ui_borg_language_menu "CENTER+4:21,SOUTH+1:5" //borgs
#define ui_monkey_head "CENTER-4:13,SOUTH:5" //monkey
#define ui_monkey_mask "CENTER-3:14,SOUTH:5" //monkey
#define ui_monkey_neck "CENTER-2:15,SOUTH:5" //monkey
#define ui_monkey_back "CENTER-1:16,SOUTH:5" //monkey
#define ui_monkey_head "CENTER-5:13,SOUTH:5" //monkey
#define ui_monkey_mask "CENTER-4:14,SOUTH:5" //monkey
#define ui_monkey_neck "CENTER-3:15,SOUTH:5" //monkey
#define ui_monkey_back "CENTER-2:16,SOUTH:5" //monkey
#define ui_alien_storage_l "CENTER-2:14,SOUTH:5"//alien
#define ui_alien_storage_r "CENTER+1:18,SOUTH:5"//alien
#define ui_alien_talk_wheel "EAST-3:26,SOUTH:5" //alien
#define ui_alien_language_menu "EAST-3:26,SOUTH:5" //alien
#define ui_drone_drop "CENTER+1:18,SOUTH:5" //maintenance drones
#define ui_drone_pull "CENTER+2:2,SOUTH:5" //maintenance drones
+6 -1
View File
@@ -53,7 +53,7 @@
if(..())
return
var/mob/living/silicon/ai/AI = usr
crewmonitor.show(AI)
GLOB.crewmonitor.show(AI)
/obj/screen/ai/crew_manifest
name = "Crew Manifest"
@@ -167,6 +167,11 @@
..()
var/obj/screen/using
// Language menu
using = new /obj/screen/language_menu
using.screen_loc = ui_borg_language_menu
static_inventory += using
//AI core
using = new /obj/screen/ai/aicore()
using.screen_loc = ui_ai_core
+19 -22
View File
@@ -276,7 +276,7 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
return ..()
/obj/screen/alert/clockwork/scripture_reqs/process()
if(clockwork_gateway_activated)
if(GLOB.clockwork_gateway_activated)
qdel(src)
return
var/current_state
@@ -288,7 +288,7 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
icon_state = "no"
if(!current_state)
name = "Current Objective"
for(var/obj/structure/destructible/clockwork/massive/celestial_gateway/G in all_clockwork_objects)
for(var/obj/structure/destructible/clockwork/massive/celestial_gateway/G in GLOB.all_clockwork_objects)
var/area/gate_area = get_area(G)
desc = "<b>Protect the Ark at [gate_area.map_name]!</b>"
return
@@ -298,7 +298,7 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
name = "Next Tier Requirements"
var/validservants = 0
var/unconverted_ais_exist = get_unconverted_ais()
for(var/mob/living/L in living_mob_list)
for(var/mob/living/L in GLOB.living_mob_list)
if(is_servant_of_ratvar(L) && (ishuman(L) || issilicon(L)))
validservants++
var/req_servants = 0
@@ -328,14 +328,14 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
icon_state += "-servants" //in this manner, generate an icon key based on what we're missing
else
textlist += ": <b><font color=#5A6068>\[CHECK\]</font></b>"
textlist += "<br><b>[clockwork_caches]/[req_caches]</b> Tinkerer's Caches"
if(clockwork_caches < req_caches)
textlist += "<br><b>[GLOB.clockwork_caches]/[req_caches]</b> Tinkerer's Caches"
if(GLOB.clockwork_caches < req_caches)
icon_state += "-caches"
else
textlist += ": <b><font color=#5A6068>\[CHECK\]</font></b>"
if(req_cv) //cv only shows up if the tier requires it
textlist += "<br><b>[clockwork_construction_value]/[req_cv]</b> Construction Value"
if(clockwork_construction_value < req_cv)
textlist += "<br><b>[GLOB.clockwork_construction_value]/[req_cv]</b> Construction Value"
if(GLOB.clockwork_construction_value < req_cv)
icon_state += "-cv"
else
textlist += ": <b><font color=#5A6068>\[CHECK\]</font></b>"
@@ -356,7 +356,7 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
icon_state = "clockinfo"
/obj/screen/alert/clockwork/infodump/MouseEntered(location,control,params)
if(ratvar_awakens)
if(GLOB.ratvar_awakens)
desc = "<font size=3><b>CHETR<br>NYY<br>HAGEHUGF-NAQ-UBABE<br>RATVAR.</b></font>"
else
var/servants = 0
@@ -364,7 +364,7 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
var/unconverted_ais_exist = get_unconverted_ais()
var/list/scripture_states = scripture_unlock_check()
var/list/textlist
for(var/mob/living/L in living_mob_list)
for(var/mob/living/L in GLOB.living_mob_list)
if(is_servant_of_ratvar(L))
servants++
if(ishuman(L) || issilicon(L))
@@ -376,13 +376,13 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
textlist = list("<b>[servants]</b> Servants, [validservants ? "<b>[validservants]</b> of which counts":"none of which count"] towards scripture.<br>")
else
textlist = list("<b>[servants]</b> Servant, who [validservants ? "counts":"does not count"] towards scripture.<br>")
textlist += "<b>[clockwork_caches ? "[clockwork_caches]</b> Tinkerer's Caches.":"No Tinkerer's Caches, construct one!</b>"]<br>\
<b>[clockwork_construction_value]</b> Construction Value.<br>"
if(clockwork_daemons)
textlist += "<b>[clockwork_daemons]</b> Tinkerer's Daemons: <b>[servants * 0.2 < clockwork_daemons ? "DISABLED":"ACTIVE"]</b><br>"
textlist += "<b>[GLOB.clockwork_caches ? "[GLOB.clockwork_caches]</b> Tinkerer's Caches.":"No Tinkerer's Caches, construct one!</b>"]<br>\
<b>[GLOB.clockwork_construction_value]</b> Construction Value.<br>"
if(GLOB.clockwork_daemons)
textlist += "<b>[GLOB.clockwork_daemons]</b> Tinkerer's Daemons: <b>[servants * 0.2 < GLOB.clockwork_daemons ? "DISABLED":"ACTIVE"]</b><br>"
else
textlist += "No Tinkerer's Daemons.<br>"
for(var/obj/structure/destructible/clockwork/massive/celestial_gateway/G in all_clockwork_objects)
for(var/obj/structure/destructible/clockwork/massive/celestial_gateway/G in GLOB.all_clockwork_objects)
var/area/gate_area = get_area(G)
textlist += "Ark Location: <b>[uppertext(gate_area.map_name)]</b><br>"
if(G.still_needs_components())
@@ -392,20 +392,17 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
textlist += "<b><font color=[get_component_color_bright(i)]>[G.required_components[i]]</font></b> "
textlist += "<br>"
else
if(G.ratvar_portal)
textlist += "Seconds until Ratvar's arrival: <b>[G.get_arrival_text(TRUE)]</b><br>"
else
textlist += "Seconds until Proselytization: <b>[G.get_arrival_text(TRUE)]</b><br>"
textlist += "Seconds until Ratvar's arrival: <b>[G.get_arrival_text(TRUE)]</b><br>"
if(unconverted_ais_exist)
if(unconverted_ais_exist > 1)
textlist += "<b>[unconverted_ais_exist] unconverted AIs exist!</b><br>"
else
textlist += "<b>An unconverted AI exists!</b><br>"
if(scripture_states[SCRIPTURE_REVENANT])
var/inathneq_available = clockwork_generals_invoked["inath-neq"] <= world.time
var/sevtug_available = clockwork_generals_invoked["sevtug"] <= world.time
var/nezbere_available = clockwork_generals_invoked["nezbere"] <= world.time
var/nezcrentr_available = clockwork_generals_invoked["nzcrentr"] <= world.time
var/inathneq_available = GLOB.clockwork_generals_invoked["inath-neq"] <= world.time
var/sevtug_available = GLOB.clockwork_generals_invoked["sevtug"] <= world.time
var/nezbere_available = GLOB.clockwork_generals_invoked["nezbere"] <= world.time
var/nezcrentr_available = GLOB.clockwork_generals_invoked["nzcrentr"] <= world.time
if(inathneq_available || sevtug_available || nezbere_available || nezcrentr_available)
textlist += "Generals available:<b>[inathneq_available ? "<br><font color=#1E8CE1>INATH-NEQ</font>":""][sevtug_available ? "<br><font color=#AF0AAF>SEVTUG</font>":""]\
[nezbere_available ? "<br><font color=#5A6068>NEZBERE</font>":""][nezcrentr_available ? "<br><font color=#DAAA18>NZCRENTR</font>":""]</b><br>"
+2 -3
View File
@@ -63,9 +63,8 @@
H.leap_icon.screen_loc = ui_alien_storage_r
static_inventory += H.leap_icon
using = new/obj/screen/wheel/talk
using.screen_loc = ui_alien_talk_wheel
wheels += using
using = new/obj/screen/language_menu
using.screen_loc = ui_alien_language_menu
static_inventory += using
using = new /obj/screen/drop()
+2 -3
View File
@@ -18,9 +18,8 @@
pull_icon.screen_loc = ui_pull_resist
hotkeybuttons += pull_icon
using = new/obj/screen/wheel/talk
using.screen_loc = ui_alien_talk_wheel
wheels += using
using = new/obj/screen/language_menu
using.screen_loc = ui_alien_language_menu
static_inventory += using
zone_select = new /obj/screen/zone_sel/alien()
+5 -19
View File
@@ -33,8 +33,6 @@
var/obj/screen/throw_icon
var/obj/screen/module_store_icon
var/list/wheels = list() //list of the wheel screen objects
var/list/static_inventory = list() //the screen objects which are static
var/list/toggleable_inventory = list() //the screen objects which can be hidden
var/list/obj/screen/hotkeybuttons = list() //the buttons that can be used via hotkeys
@@ -78,8 +76,6 @@
qdel(module_store_icon)
module_store_icon = null
wheels = null //all wheels are also in static_inventory
if(static_inventory.len)
for(var/thing in static_inventory)
qdel(thing)
@@ -136,15 +132,15 @@
/mob/proc/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud(src)
update_sight()
//Version denotes which style should be displayed. blank or 0 means "next version"
/datum/hud/proc/show_hud(version = 0,mob/viewmob)
if(!ismob(mymob))
return 0
if(!mymob.client)
return 0
var/mob/screenmob = viewmob || mymob
if(!screenmob.client)
return 0
screenmob.client.screen = list()
@@ -166,7 +162,7 @@
if(infodisplay.len)
screenmob.client.screen += infodisplay
mymob.client.screen += hide_actions_toggle
screenmob.client.screen += hide_actions_toggle
if(action_intent)
action_intent.screen_loc = initial(action_intent.screen_loc) //Restore intent selection to the original position
@@ -210,7 +206,7 @@
mymob.update_action_buttons(1)
reorganize_alerts()
mymob.reload_fullscreen()
create_parallax()
update_parallax_pref(screenmob)
/datum/hud/human/show_hud(version = 0,mob/viewmob)
@@ -227,16 +223,6 @@
/datum/hud/proc/persistent_inventory_update(mob/viewer)
if(!mymob)
return
var/mob/living/L = mymob
var/mob/screenmob = viewer || L
for(var/X in wheels)
var/obj/screen/wheel/W = X
if(W.toggled)
screenmob.client.screen |= W.buttons_list
else
screenmob.client.screen -= W.buttons_list
//Triggered when F12 is pressed (Unless someone changed something in the DMF)
/mob/verb/button_pressed_F12()
+1 -2
View File
@@ -96,9 +96,8 @@
using.icon = ui_style
static_inventory += using
using = new/obj/screen/wheel/talk
using = new/obj/screen/language_menu
using.icon = ui_style
wheels += using
static_inventory += using
using = new /obj/screen/area_creator
+3 -5
View File
@@ -15,9 +15,8 @@
using.screen_loc = ui_movi
static_inventory += using
using = new/obj/screen/wheel/talk
using = new/obj/screen/language_menu
using.icon = ui_style
wheels += using
static_inventory += using
using = new /obj/screen/drop()
@@ -70,8 +69,7 @@
inv_box.name = "back"
inv_box.icon = ui_style
inv_box.icon_state = "back"
inv_box.icon_full = "template_small"
inv_box.screen_loc = ui_back
inv_box.screen_loc = ui_monkey_back
inv_box.slot_id = slot_back
static_inventory += inv_box
@@ -124,7 +122,7 @@
if(hud_shown)
if(M.back)
M.back.screen_loc = ui_back
M.back.screen_loc = ui_monkey_back
M.client.screen += M.back
if(M.wear_mask)
M.wear_mask.screen_loc = ui_monkey_mask
+21 -12
View File
@@ -11,9 +11,10 @@
var/parallax_layers_max = 3
var/parallax_animate_timer
/datum/hud/proc/create_parallax()
var/client/C = mymob.client
if (!apply_parallax_pref())
/datum/hud/proc/create_parallax(mob/viewmob)
var/mob/screenmob = viewmob || mymob
var/client/C = screenmob.client
if (!apply_parallax_pref(viewmob)) //don't want shit computers to crash when specing someone with insane parallax, so use the viewer's pref
return
if(!length(C.parallax_layers_cached))
@@ -27,7 +28,10 @@
C.parallax_layers.len = C.parallax_layers_max
C.screen |= (C.parallax_layers)
var/obj/screen/plane_master/PM = plane_masters["[PLANE_SPACE]"]
var/obj/screen/plane_master/PM = screenmob.hud_used.plane_masters["[PLANE_SPACE]"]
if(screenmob != mymob)
C.screen -= locate(/obj/screen/plane_master/parallax_white) in C.screen
C.screen += PM
PM.color = list(
0, 0, 0, 0,
0, 0, 0, 0,
@@ -37,15 +41,20 @@
)
/datum/hud/proc/remove_parallax()
var/client/C = mymob.client
/datum/hud/proc/remove_parallax(mob/viewmob)
var/mob/screenmob = viewmob || mymob
var/client/C = screenmob.client
C.screen -= (C.parallax_layers_cached)
var/obj/screen/plane_master/PM = plane_masters["[PLANE_SPACE]"]
var/obj/screen/plane_master/PM = screenmob.hud_used.plane_masters["[PLANE_SPACE]"]
if(screenmob != mymob)
C.screen -= locate(/obj/screen/plane_master/parallax_white) in C.screen
C.screen += PM
PM.color = initial(PM.color)
C.parallax_layers = null
/datum/hud/proc/apply_parallax_pref()
var/client/C = mymob.client
/datum/hud/proc/apply_parallax_pref(mob/viewmob)
var/mob/screenmob = viewmob || mymob
var/client/C = screenmob.client
if(C.prefs)
var/pref = C.prefs.parallax
if (isnull(pref))
@@ -75,9 +84,9 @@
C.parallax_layers_max = 3
return TRUE
/datum/hud/proc/update_parallax_pref()
remove_parallax()
create_parallax()
/datum/hud/proc/update_parallax_pref(mob/viewmob)
remove_parallax(viewmob)
create_parallax(viewmob)
// This sets which way the current shuttle is moving (returns true if the shuttle has stopped moving so the caller can append their animation)
/datum/hud/proc/set_parallax_movedir(new_parallax_movedir, skip_windups)
+8 -5
View File
@@ -3,6 +3,14 @@
icon_state = "blank"
appearance_flags = PLANE_MASTER|NO_CLIENT_COLOR
blend_mode = BLEND_OVERLAY
var/show_alpha = 255
var/hide_alpha = 0
/obj/screen/plane_master/proc/Show(override)
alpha = override || show_alpha
/obj/screen/plane_master/proc/Hide(override)
alpha = override || hide_alpha
//Why do plane masters need a backdrop sometimes? Read http://www.byond.com/forum/?post=2141928
//Trust me, you need one. Period. If you don't think you do, you're doing something extremely wrong.
@@ -19,11 +27,6 @@
blend_mode = BLEND_MULTIPLY
mouse_opacity = 0
/obj/screen/plane_master/lighting/proc/params2color(params)
color = params2list(params)
/obj/screen/plane_master/lighting/proc/basecolor()
color = LIGHTING_BASE_MATRIX
/obj/screen/plane_master/parallax
name = "parallax plane master"
plane = PLANE_SPACE_PARALLAX
+2 -3
View File
@@ -96,9 +96,8 @@
var/mob/living/silicon/robot/mymobR = mymob
var/obj/screen/using
using = new/obj/screen/wheel/talk
using.screen_loc = ui_borg_talk_wheel
wheels += using
using = new/obj/screen/language_menu
using.screen_loc = ui_borg_language_menu
static_inventory += using
//Radio
+25 -143
View File
@@ -84,6 +84,18 @@
return 1
create_area(usr)
/obj/screen/language_menu
name = "language menu"
icon = 'icons/mob/screen_midnight.dmi'
icon_state = "talk_wheel"
screen_loc = ui_language_menu
/obj/screen/language_menu/Click()
var/mob/living/L = usr
if(!istype(L))
return
L.open_language_menu(usr)
/obj/screen/inventory
var/slot_id // The indentifier for the slot. It has nothing to do with ID cards.
var/icon_empty // Icon when empty. For now used only by humans.
@@ -529,145 +541,8 @@
name = "health doll"
screen_loc = ui_healthdoll
/obj/screen/wheel
name = "wheel"
layer = HUD_LAYER
plane = HUD_PLANE
icon_state = ""
screen_loc = null //if you make a new wheel, remember to give it a screen_loc
var/list/buttons_names = list() //list of the names for each button, its length is the amount of buttons.
var/toggled = 0 //wheel is hidden/shown
var/wheel_buttons_type //the type of buttons used with this wheel.
var/list/buttons_list = list()
/obj/screen/wheel/New()
..()
build_options()
//we create the buttons for the wheel and place them in a square spiral fashion.
/obj/screen/wheel/proc/build_options()
var/obj/screen/wheel_button/close_wheel/CW = new ()
buttons_list += CW //the close option
CW.wheel = src
var/list/offset_x_list = list()
var/list/offset_y_list = list()
var/num = 1
var/N = 1
var/M = 0
var/sign = -1
my_loop:
while(offset_y_list.len < buttons_names.len)
for(var/i=1, i<=num, i++)
offset_y_list += N
offset_x_list += M
if(offset_y_list.len == buttons_names.len)
break my_loop
if(N != 0)
N = 0
M = -sign
else
N = sign
M = 0
sign = -sign
num++
var/screenx = 8
var/screeny = 8
for(var/i = 1, i <= buttons_names.len, i++)
var/obj/screen/wheel_button/WB = new wheel_buttons_type()
WB.wheel = src
buttons_list += WB
screenx += offset_x_list[i]
screeny += offset_y_list[i]
WB.screen_loc = "[screenx], [screeny]"
set_button(WB, i)
/obj/screen/wheel/proc/set_button(obj/screen/wheel_button/WB, button_number)
WB.name = buttons_names[button_number]
return
/obj/screen/wheel/Destroy()
for(var/obj/screen/S in buttons_list)
qdel(S)
return ..()
/obj/screen/wheel/Click()
if(world.time <= usr.next_move)
return
if(usr.stat)
return
if(isliving(usr))
var/mob/living/L = usr
if(toggled)
L.client.screen -= buttons_list
else
L.client.screen |= buttons_list
toggled = !toggled
/obj/screen/wheel/talk
name = "talk wheel"
icon_state = "talk_wheel"
screen_loc = "11:6,2:-11"
wheel_buttons_type = /obj/screen/wheel_button/talk
buttons_names = list("help","hello","bye","stop","thanks","come","out", "yes", "no")
var/list/word_messages = list(list("Help!","Help me!"), list("Hello.", "Hi."), list("Bye.", "Goodbye."),\
list("Stop!", "Halt!"), list("Thanks.", "Thanks!", "Thank you."), \
list("Come.", "Follow me."), list("Out!", "Go away!", "Get out!"), \
list("Yes.", "Affirmative."), list("No.", "Negative"))
/obj/screen/wheel/talk/set_button(obj/screen/wheel_button/WB, button_number)
..()
var/obj/screen/wheel_button/talk/T = WB //we already know what type the button is exactly.
T.icon_state = "talk_[T.name]"
T.word_messages = word_messages[button_number]
/obj/screen/wheel_button
name = "default wheel button"
screen_loc = "8,8"
layer = HUD_LAYER
plane = HUD_PLANE
mouse_opacity = 2
var/obj/screen/wheel/wheel
/obj/screen/wheel_button/Destroy()
wheel = null
return ..()
/obj/screen/wheel_button/close_wheel
name = "close wheel"
icon_state = "x3"
/obj/screen/wheel_button/close_wheel/Click()
if(isliving(usr))
var/mob/living/L = usr
L.client.screen -= wheel.buttons_list
wheel.toggled = !wheel.toggled
/obj/screen/wheel_button/talk
name = "talk option"
icon_state = "talk_help"
var/talk_cooldown = 0
var/list/word_messages = list()
/obj/screen/wheel_button/talk/Click(location, control,params)
if(isliving(usr))
var/mob/living/L = usr
if(L.stat)
return
if(word_messages.len && talk_cooldown < world.time)
talk_cooldown = world.time + 10
L.say(pick(word_messages))
/obj/screen/splash
icon = 'config/title_screens/images/title1.dmi'
icon = 'config/title_screens/images/blank.png'
icon_state = ""
screen_loc = "1,1"
layer = SPLASHSCREEN_LAYER
@@ -679,16 +554,23 @@
if(!visible)
alpha = 0
if(SStitle.title_screen)
icon = SStitle.title_screen.icon
if(!use_previous_title)
if(SStitle.icon)
icon = SStitle.icon
else
if(!SStitle.previous_icon)
qdel(src)
return
icon = SStitle.previous_icon
holder.screen += src
if(use_previous_title && !SSmapping.previous_map_config.defaulted)
holder.screen -= src //Yell at Cyberboss to finish this
..()
/obj/screen/splash/proc/Fade(out, qdel_after = TRUE)
if(QDELETED(src))
return
if(out)
animate(src, alpha = 0, time = 30)
else
@@ -701,4 +583,4 @@
if(holder)
holder.screen -= src
holder = null
return ..()
return ..()