Skip to content

Commit

Permalink
Merge branch 'master' into Infection_Announcement_Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben10083 authored Jul 25, 2023
2 parents de12b76 + 6367a5f commit 9c95822
Show file tree
Hide file tree
Showing 60 changed files with 595 additions and 248 deletions.
10 changes: 7 additions & 3 deletions code/controllers/subsystem/mapping.dm
Original file line number Diff line number Diff line change
Expand Up @@ -123,10 +123,14 @@ SUBSYSTEM_DEF(mapping)
++i

// load the maps
for (var/P in parsed_maps)
var/datum/parsed_map/pm = P
if (!pm.load(1, 1, start_z + parsed_maps[P], no_changeturf = TRUE))
for (var/datum/parsed_map/pm as anything in parsed_maps)
var/cur_z = start_z + parsed_maps[pm]
if (!pm.load(1, 1, cur_z, no_changeturf = TRUE))
errorList |= pm.original_path
if(istype(z_list[cur_z], /datum/space_level))
var/datum/space_level/cur_level = z_list[cur_z]
cur_level.x_bounds = pm.bounds[MAP_MAXX]
cur_level.y_bounds = pm.bounds[MAP_MAXY]
if(!silent)
INIT_ANNOUNCE("Loaded [name] in [(REALTIMEOFDAY - start_time)/10]s!")
return parsed_maps
Expand Down
46 changes: 23 additions & 23 deletions code/datums/factions/uscm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
name = "United States Colonial Marines"
faction_tag = FACTION_MARINE

/datum/faction/uscm/modify_hud_holder(image/holder, mob/living/carbon/human/H)
var/datum/squad/squad = H.assigned_squad
/datum/faction/uscm/modify_hud_holder(image/holder, mob/living/carbon/human/current_human)
var/datum/squad/squad = current_human.assigned_squad
if(istype(squad))
var/squad_clr = squad_colors[H.assigned_squad.color]
var/squad_clr = current_human.assigned_squad.equipment_color
var/marine_rk
var/obj/item/card/id/I = H.get_idcard()
var/obj/item/card/id/I = current_human.get_idcard()
var/_role
if(H.job)
_role = H.job
if(current_human.job)
_role = current_human.job
else if(I)
_role = I.rank
switch(GET_DEFAULT_ROLE(_role))
Expand All @@ -29,42 +29,42 @@
if(JOB_MARINE_RAIDER) marine_rk = "soc"
if(JOB_MARINE_RAIDER_SL) marine_rk = "soctl"
if(JOB_MARINE_RAIDER_CMD) marine_rk = "soccmd"
if(squad.squad_leader == H)
if(squad.squad_leader == current_human)
switch(squad.squad_type)
if("Squad") marine_rk = "leader_a"
if("Team") marine_rk = "soctl_a"

H.langchat_styles = "langchat_bolded" // bold text for bold leaders
current_human.langchat_styles = "langchat_bolded" // bold text for bold leaders
else
H.langchat_styles = initial(H.langchat_styles)
current_human.langchat_styles = initial(current_human.langchat_styles)

H.langchat_color = squad_colors_chat[H.assigned_squad.color]
current_human.langchat_color = current_human.assigned_squad.chat_color

if(!marine_rk) marine_rk = H.rank_fallback
if(!marine_rk) marine_rk = current_human.rank_fallback
if(marine_rk)
var/image/IMG = image('icons/mob/hud/marine_hud.dmi', H, "hudsquad")
var/image/IMG = image('icons/mob/hud/marine_hud.dmi', current_human, "hudsquad")
if(squad_clr)
IMG.color = squad_clr
else
IMG.color = "#5A934A"
holder.overlays += IMG
holder.overlays += image('icons/mob/hud/marine_hud.dmi', H, "hudsquad_[marine_rk]")
if(H.assigned_squad && H.assigned_fireteam)
var/image/IMG2 = image('icons/mob/hud/marine_hud.dmi', H, "hudsquad_[H.assigned_fireteam]")
holder.overlays += image('icons/mob/hud/marine_hud.dmi', current_human, "hudsquad_[marine_rk]")
if(current_human.assigned_squad && current_human.assigned_fireteam)
var/image/IMG2 = image('icons/mob/hud/marine_hud.dmi', current_human, "hudsquad_[current_human.assigned_fireteam]")
IMG2.color = squad_clr
holder.overlays += IMG2
if(H.assigned_squad.fireteam_leaders[H.assigned_fireteam] == H)
var/image/IMG3 = image('icons/mob/hud/marine_hud.dmi', H, "hudsquad_ftl")
if(current_human.assigned_squad.fireteam_leaders[current_human.assigned_fireteam] == current_human)
var/image/IMG3 = image('icons/mob/hud/marine_hud.dmi', current_human, "hudsquad_ftl")
IMG3.color = squad_clr
holder.overlays += IMG3
else
var/marine_rk
var/border_rk
var/icon_prefix = "hudsquad_"
var/obj/item/card/id/ID = H.get_idcard()
var/obj/item/card/id/ID = current_human.get_idcard()
var/_role
if(H.mind)
_role = H.job
if(current_human.mind)
_role = current_human.job
else if(ID)
_role = ID.rank
switch(_role)
Expand Down Expand Up @@ -188,9 +188,9 @@
icon_prefix = "cmb_"

if(marine_rk)
var/image/I = image('icons/mob/hud/marine_hud.dmi', H, "hudsquad")
var/image/I = image('icons/mob/hud/marine_hud.dmi', current_human, "hudsquad")
I.color = "#5A934A"
holder.overlays += I
holder.overlays += image('icons/mob/hud/marine_hud.dmi', H, "[icon_prefix][marine_rk]")
holder.overlays += image('icons/mob/hud/marine_hud.dmi', current_human, "[icon_prefix][marine_rk]")
if(border_rk)
holder.overlays += image('icons/mob/hud/marine_hud.dmi', H, "hudmarineborder[border_rk]")
holder.overlays += image('icons/mob/hud/marine_hud.dmi', current_human, "hudmarineborder[border_rk]")
2 changes: 1 addition & 1 deletion code/datums/recipe.dm
Original file line number Diff line number Diff line change
Expand Up @@ -769,7 +769,7 @@
/datum/recipe/syntikabob
items = list(
/obj/item/stack/rods,
/obj/item/reagent_container/food/snacks/meat/syntiflesh,
/obj/item/reagent_container/food/snacks/meat/synthmeat,
)
result = /obj/item/reagent_container/food/snacks/monkeykabob

Expand Down
4 changes: 2 additions & 2 deletions code/datums/supply_packs/operations.dm
Original file line number Diff line number Diff line change
Expand Up @@ -94,15 +94,15 @@
group = "Operations"

/datum/supply_packs/nuclearbomb
name = "Operational Nuke"
name = "Decrypted Operational Nuke"
cost = 0
containertype = /obj/structure/machinery/nuclearbomb
buyable = 0
group = "Operations"
iteration_needed = null

/datum/supply_packs/technuclearbomb
name = "Intel Operational Nuke"
name = "Encrypted Operational Nuke"
cost = 0
containertype = /obj/structure/machinery/nuclearbomb/tech
buyable = 0
Expand Down
10 changes: 5 additions & 5 deletions code/game/jobs/job/marine/marine.dm
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
spawn_positions = 8
allow_additional = 1

/datum/job/marine/generate_entry_message(mob/living/carbon/human/H)
if(H.assigned_squad)
entry_message_intro = "You are a [title]!<br>You have been assigned to: <b><font size=3 color=[squad_colors[H.assigned_squad.color]]>[lowertext(H.assigned_squad.name)] squad</font></b>.[Check_WO() ? "" : " Make your way to the cafeteria for some post-cryosleep chow, and then get equipped in your squad's prep room." ]"
/datum/job/marine/generate_entry_message(mob/living/carbon/human/current_human)
if(current_human.assigned_squad)
entry_message_intro = "You are a [title]!<br>You have been assigned to: <b><font size=3 color=[current_human.assigned_squad.equipment_color]>[lowertext(current_human.assigned_squad.name)] squad</font></b>.[Check_WO() ? "" : " Make your way to the cafeteria for some post-cryosleep chow, and then get equipped in your squad's prep room." ]"
return ..()

/datum/job/marine/generate_entry_conditions(mob/living/carbon/human/H)
/datum/job/marine/generate_entry_conditions(mob/living/carbon/human/current_human)
..()
if(!Check_WO())
H.nutrition = rand(NUTRITION_VERYLOW, NUTRITION_LOW) //Start hungry for the default marine.
current_human.nutrition = rand(NUTRITION_VERYLOW, NUTRITION_LOW) //Start hungry for the default marine.

/datum/timelock/squad
name = "Squad Roles"
Expand Down
2 changes: 1 addition & 1 deletion code/game/jobs/job/marine/squad_info.dm
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
update_squad_leader()
var/list/data = squad_info_data.Copy()
data["squad"] = name
data["squad_color"] = squad_colors[color]
data["squad_color"] = equipment_color
data["is_lead"] = get_leadership(user)
data["objective"] = list(
"primary" = primary_objective,
Expand Down
100 changes: 68 additions & 32 deletions code/game/jobs/job/marine/squads.dm
Original file line number Diff line number Diff line change
Expand Up @@ -25,29 +25,51 @@
sub_leader = "Strike Leader"

/datum/squad
var/name //Name of the squad
/// Name of the squad
var/name
/// Squads ID that is set on New()
var/tracking_id = null //Used for the tracking subsystem
var/max_positions = -1 //Maximum number allowed in a squad. Defaults to infinite
var/color = 0 //Color for helmets, etc.
var/list/access = list() //Which special access do we grant them
var/omni_squad_vendor = FALSE /// Can use any squad vendor regardless of squad connection
var/max_engineers = 3 //maximum # of engineers allowed in squad
var/max_medics = 4 //Ditto, squad medics
/// Maximum number allowed in a squad. Defaults to infinite
var/max_positions = -1
/// Color for the squad marines gear overlays
var/equipment_color = "#FFFFFF"
/// The alpha for the armor overlay used by equipment color
var/armor_alpha = 125
/// Color for the squad marines langchat
var/chat_color = "#FFFFFF"
/// Which special access do we grant them
var/list/access = list()
/// Can use any squad vendor regardless of squad connection
var/omni_squad_vendor = FALSE
/// maximum # of engineers allowed in the squad
var/max_engineers = 3
/// maximum # of squad medics allowed in the squad
var/max_medics = 4
/// maximum # of specs allowed in the squad
var/max_specialists = 1
/// maximum # of fireteam leaders allowed in the suqad
var/max_tl = 2
/// maximum # of smartgunners allowed in the squad
var/max_smartgun = 1
/// maximum # of squad leaders allowed in the squad
var/max_leaders = 1
var/radio_freq = 1461 //Squad radio headset frequency.

///Variables for showing up in various places
var/usable = FALSE //Is it used in-game?
var/roundstart = TRUE /// Whether this squad can be picked at roundstart
var/locked = FALSE //Is it available for squad management?
var/active = FALSE //Is it visible in overwatch?
var/faction = FACTION_MARINE //What faction runs the squad?

///Squad Type Specifics
/// Squad headsets default radio frequency
var/radio_freq = 1461

/// Whether this squad can be used by marines
var/usable = FALSE
/// Whether this squad can be picked at roundstart
var/roundstart = TRUE
// Whether the squad is available for squad management
var/locked = FALSE
/// Whether it is visible in overwatch
var/active = FALSE
/// Which faction the squad is in
var/faction = FACTION_MARINE

/// What will the assistant squad leader be called
var/squad_type = "Squad" //Referenced for aSL details. Squad/Team/Cell etc.
/// Squad leaders icon
var/lead_icon //Referenced for SL's 'L' icon. If nulled, won't override icon for aSLs.

//vvv Do not set these in squad defines
Expand Down Expand Up @@ -96,35 +118,40 @@

/datum/squad/marine/alpha
name = SQUAD_MARINE_1
color = 1
equipment_color = "#e61919"
chat_color = "#e67d7d"
access = list(ACCESS_MARINE_ALPHA)
radio_freq = ALPHA_FREQ
minimap_color = MINIMAP_SQUAD_ALPHA

/datum/squad/marine/bravo
name = SQUAD_MARINE_2
color = 2
equipment_color = "#ffc32d"
chat_color = "#ffe650"
access = list(ACCESS_MARINE_BRAVO)
radio_freq = BRAVO_FREQ
minimap_color = MINIMAP_SQUAD_BRAVO

/datum/squad/marine/charlie
name = SQUAD_MARINE_3
color = 3
equipment_color = "#c864c8"
chat_color = "#ff96ff"
access = list(ACCESS_MARINE_CHARLIE)
radio_freq = CHARLIE_FREQ
minimap_color = MINIMAP_SQUAD_CHARLIE

/datum/squad/marine/delta
name = SQUAD_MARINE_4
color = 4
equipment_color = "#4148c8"
chat_color = "#828cff"
access = list(ACCESS_MARINE_DELTA)
radio_freq = DELTA_FREQ
minimap_color = MINIMAP_SQUAD_DELTA

/datum/squad/marine/echo
name = SQUAD_MARINE_5
color = 5
equipment_color = "#67d692"
chat_color = "#67d692"
access = list(ACCESS_MARINE_ALPHA, ACCESS_MARINE_BRAVO, ACCESS_MARINE_CHARLIE, ACCESS_MARINE_DELTA)
radio_freq = ECHO_FREQ
omni_squad_vendor = TRUE
Expand All @@ -136,7 +163,8 @@

/datum/squad/marine/cryo
name = SQUAD_MARINE_CRYO
color = 6
equipment_color = "#c47a50"
chat_color = "#c47a50"
access = list(ACCESS_MARINE_ALPHA, ACCESS_MARINE_BRAVO, ACCESS_MARINE_CHARLIE, ACCESS_MARINE_DELTA)
minimap_color = MINIMAP_SQUAD_FOXTROT

Expand All @@ -149,7 +177,8 @@

/datum/squad/marine/sof
name = SQUAD_SOF
color = 7
equipment_color = "#400000"
chat_color = "#400000"
radio_freq = SOF_FREQ
squad_type = "Team"
lead_icon = "soctl"
Expand All @@ -168,23 +197,28 @@

/datum/squad/upp/one
name = "UPPS1"
color = 1
equipment_color = "#e61919"
chat_color = "#e67d7d"

/datum/squad/upp/twp
name = "UPPS2"
color = 2
equipment_color = "#ffc32d"
chat_color = "#ffe650"

/datum/squad/upp/three
name = "UPPS3"
color = 3
equipment_color = "#c864c8"
chat_color = "#ff96ff"

/datum/squad/upp/four
name = "UPPS4"
color = 4
equipment_color = "#4148c8"
chat_color = "#828cff"

/datum/squad/upp/kdo
name = "UPPKdo"
color = 6
equipment_color = "#c47a50"
chat_color = "#c47a50"
squad_type = "Team"
locked = TRUE
//###############################
Expand All @@ -197,11 +231,13 @@

/datum/squad/pmc/one
name = "Team Upsilon"
color = 3
equipment_color = "#c864c8"
chat_color = "#ff96ff"

/datum/squad/pmc/two
name = "Team Gamma"
color = 6
equipment_color = "#c47a50"
chat_color = "#c47a50"

/datum/squad/pmc/wo
name = "Taskforce White"
Expand Down Expand Up @@ -331,7 +367,7 @@

/// Displays a message to squad members directly on the game map
/datum/squad/proc/send_maptext(text = "", title_text = "", only_leader = 0)
var/message_colour = squad_colors_chat[color]
var/message_colour = chat_color
if(only_leader)
if(squad_leader)
var/mob/living/carbon/human/SL = squad_leader
Expand Down
3 changes: 2 additions & 1 deletion code/game/machinery/nuclearbomb.dm
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ var/bomb_set = FALSE
var/timing = FALSE
var/deployable = FALSE
var/explosion_time = null
var/timeleft = 4800
var/timeleft = 8 MINUTES
var/safety = TRUE
var/being_used = FALSE
var/end_round = TRUE
Expand Down Expand Up @@ -152,6 +152,7 @@ var/bomb_set = FALSE
data["command_lockout"] = command_lockout
data["allowed"] = allowed
data["being_used"] = being_used
data["decryption_complete"] = TRUE //this is overriden by techweb nuke UI_data later, this just makes it default to true

return data

Expand Down
4 changes: 4 additions & 0 deletions code/game/objects/items/reagent_containers/food.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
/// Food.
////////////////////////////////////////////////////////////////////////////////
/obj/item/reagent_container/food
item_icons = list(
WEAR_L_HAND = 'icons/mob/humans/onmob/items_lefthand_1.dmi',
WEAR_R_HAND = 'icons/mob/humans/onmob/items_righthand_1.dmi'
)
possible_transfer_amounts = null
volume = 50 //Sets the default container amount for all food items.
flags_atom = CAN_BE_SYRINGED
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
var/gut_icon_state = null
var/gut_time = 3
var/initial_desc = ""
var/list/guttable_atoms = list(/obj/item/reagent_container/food/snacks/meat, /obj/item/reagent_container/food/snacks/meat/syntiflesh)//placeholders, for now
var/list/guttable_atoms = list(/obj/item/reagent_container/food/snacks/meat, /obj/item/reagent_container/food/snacks/meat/synthmeat)//placeholders, for now
var/base_gut_meat = /obj/item/reagent_container/food/snacks/meat
//slice_path = null//
//slices_num
Expand Down
Loading

0 comments on commit 9c95822

Please sign in to comment.