Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into pr/Max-023/173
Browse files Browse the repository at this point in the history
  • Loading branch information
morrowwolf committed Apr 6, 2024
2 parents 89a0cf7 + 75a1a15 commit 46177ec
Show file tree
Hide file tree
Showing 44 changed files with 75,705 additions and 79 deletions.
1 change: 1 addition & 0 deletions code/__DEFINES/__game.dm
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ block( \
#define MAP_RUNTIME "USS Runtime"
#define MAP_LV522_CHANCES_CLAIM "LV-522 Chance's Claim" // Highpop Only
#define MAP_NEW_VARADERO "New Varadero"//ice colony underground but as its own map
#define MAP_NEW_VARADERO_REPAIRED "New Varadero Repaired"
#define MAP_CHINOOK "Chinook 91 GSO" //admin level
#define MAP_DERELICT_ALMAYER "Derelict Almayer"

Expand Down
2 changes: 1 addition & 1 deletion code/__DEFINES/xeno_ai.dm
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#define VEHICLE_PENALTY 25
#define WINDOW_FRAME_PENALTY 25
#define BARRICADE_PENALTY 50
#define WALL_PENALTY 50
#define WALL_PENALTY 100

/*
PROBABILITY CALCULATIONS ARE HERE
Expand Down
6 changes: 6 additions & 0 deletions code/datums/ammo/bullet/special_ammo.dm
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,12 @@
shell_speed = 2*AMMO_SPEED_TIER_6
accuracy = HIT_ACCURACY_TIER_5

/datum/ammo/bullet/turret/upp
damage = 45
penetration = ARMOR_PENETRATION_TIER_2
accuracy_var_low = PROJECTILE_VARIANCE_TIER_2
accuracy_var_high = PROJECTILE_VARIANCE_TIER_2

/datum/ammo/bullet/turret/dumb
icon_state = "bullet"
flags_ammo_behavior = AMMO_BALLISTIC
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,22 +31,19 @@
qdel(src)
return FALSE

if(locate(/obj/structure/mineral_door/resin) in location)
qdel(src)
return FALSE

var/area/current_area = get_area(location)
if(!current_area.is_resin_allowed)
for(var/client/game_master in GLOB.game_masters)
to_chat(game_master, SPAN_XENOBOLDNOTICE("This area doesn't allow xenos to build here"))
to_chat(game_master, SPAN_XENOBOLDNOTICE("[current_area] doesn't allow xenos to build here"))

qdel(src)
return FALSE

if(distance > 10)
if(locate(/obj/structure/mineral_door/resin) in location)
qdel(src)
return FALSE

if(checked_xeno.current_target)
if(distance > 10)
return FALSE

if(!locate(/datum/action/xeno_action/activable/secrete_resin) in checked_xeno.actions)
Expand All @@ -55,7 +52,7 @@
if(checked_xeno.get_plasma_percentage() < PLASMA_RETREAT_PERCENTAGE)
var/turf/xeno_loc = get_turf(checked_xeno)
if(xeno_loc.weeds)
checked_xeno.set_resting(TRUE, FALSE, TRUE)
checked_xeno.set_resting(TRUE, FALSE)

return FALSE

Expand All @@ -75,19 +72,21 @@
var/turf/parent_turf = get_turf(parent)
var/distance = get_dist(processing_xeno, parent)

var/list/turfs_around = xeno_loc.AdjacentTurfs()
if(turfs_around && distance < 1) // We are gonna be stuck after building at our loc, let's step away
return processing_xeno.move_to_next_turf(pick(turfs_around))

var/is_diagonal = (get_dir(processing_xeno, parent_turf) in diagonals)
if(is_diagonal || distance > 1)
/// Is xeno adjacent to parent_turf?
if(distance > 1)
return processing_xeno.move_to_next_turf(parent_turf)

/// Xeno will be stuck after building at its loc, if so - we command droney to step away
if(distance < 1)
return processing_xeno.move_to_next_turf(pick(GLOB.cardinals))

/// If there is something that might block our resin - slash it
for(var/obj/structure/blocker in parent_turf.contents)
if(!blocker.unslashable && blocker.density || istype(blocker, /obj/structure/bed))
if(!blocker.unslashable && (blocker.density || istype(blocker, /obj/structure/bed)))
INVOKE_ASYNC(processing_xeno, TYPE_PROC_REF(/mob, do_click), blocker, "", list())
return TRUE

/// If no ground weeds present - command our xeno to plant one
if(!parent_turf.weeds)
var/datum/action/xeno_action/onclick/plant_weeds/weeds_action = locate() in processing_xeno.actions
INVOKE_ASYNC(weeds_action, TYPE_PROC_REF(/datum/action/xeno_action/onclick/plant_weeds, use_ability_wrapper))
Expand All @@ -96,24 +95,30 @@
var/list/resin_types = processing_xeno.resin_build_order
processing_xeno.selected_resin = locate(/datum/resin_construction/resin_turf/wall) in resin_types

var/wall_nearby = FALSE
var/blocked_turfs = 0
for(var/turf/blocked_turf in orange(1, parent_turf) - parent_turf.AdjacentTurfs())
blocked_turfs++
/// Let's decide whenever we are building a door or naw
var/build_door = FALSE
for(var/turf/blocked_turf in RANGE_TURFS(1, parent_turf) - parent_turf)
var/direction = get_dir(parent_turf, blocked_turf)
if(direction in diagonals)
continue

if(get_dir(blocked_turf, parent_turf) in diagonals)
if(!blocked_turf.density)
continue

if(blocked_turf.density)
wall_nearby = TRUE
/// Checking for any opposite walls on angles 135, 180, 225 respectfully
for(var/opposite_dir in reverse_nearby_direction(direction))
var/turf/opposite_turf = get_step(parent_turf, opposite_dir)
if(opposite_turf.density)
build_door = TRUE
break

var/obj/effect/alien/weeds/turf_weeds = blocked_turf.weeds
if(turf_weeds && turf_weeds.secreting)
wall_nearby = TRUE // Something is being constructed nearby, let's bet this is a new resin wall
var/obj/effect/alien/weeds/opposite_weeds = opposite_turf.weeds
if(opposite_weeds && opposite_weeds.secreting)
/// Something is being constructed nearby, let's bet this is a new resin wall
build_door = TRUE

if(wall_nearby)
if(prob(XENO_DOOR_BUILDING_CHANCE) || (wall_nearby && blocked_turfs > 1))
processing_xeno.selected_resin = locate(/datum/resin_construction/resin_obj/door) in resin_types
if(build_door || prob(XENO_DOOR_BUILDING_CHANCE))
processing_xeno.selected_resin = locate(/datum/resin_construction/resin_obj/door) in resin_types

var/datum/action/xeno_action/activable/secrete_resin/build_action = locate() in processing_xeno.actions
INVOKE_ASYNC(build_action, TYPE_PROC_REF(/datum/action/xeno_action/activable/secrete_resin, use_ability_wrapper), parent_turf)
Expand Down
14 changes: 0 additions & 14 deletions code/datums/skills/uscm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,6 @@ United States Colonial Marines
name = "Private"
//same as default

/datum/skills/pfc/crafty
name = "Crafty Private"
skills = list(
SKILL_CONSTRUCTION = SKILL_CONSTRUCTION_TRAINED,
SKILL_ENGINEER = SKILL_ENGINEER_TRAINED,
)

/datum/skills/combat_medic
name = "Combat Medic"
skills = list(
Expand All @@ -23,13 +16,6 @@ United States Colonial Marines
SKILL_JTAC = SKILL_JTAC_BEGINNER,
)

/datum/skills/combat_medic/crafty
name = "Crafty Combat Medic"
skills = list(
SKILL_CONSTRUCTION = SKILL_CONSTRUCTION_TRAINED,
SKILL_ENGINEER = SKILL_ENGINEER_TRAINED,
)

/datum/skills/combat_engineer
name = "Combat Engineer"
skills = list(
Expand Down
9 changes: 7 additions & 2 deletions code/game/objects/items/storage/large_holster.dm
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,17 @@
name = "\improper QH20 pattern M2100 custom machete scabbard"
desc = "A large leather scabbard used to carry a M2100 \"Ngájhe\" machete. It can be strapped to the back or the armor."
icon_state = "arnold-machete-pouch"
flags_equip_slot = SLOT_WAIST|SLOT_BACK
can_hold = list(/obj/item/weapon/sword/machete)

/obj/item/storage/large_holster/machete/arnold/full/fill_preset_inventory()
new /obj/item/weapon/sword/machete/arnold(src)

/obj/item/storage/large_holster/machete/arnold/weak
name = "\improper QH20 pattern M2100 machete scabbard"
desc = "A large leather scabbard used to carry a M2100 machete. It can be strapped to the back or the armor."

/obj/item/storage/large_holster/machete/arnold/weak/fill_preset_inventory()
new /obj/item/weapon/sword/machete/arnold/weak(src)

/obj/item/storage/large_holster/katana
name = "\improper katana scabbard"
desc = "A large, vibrantly colored katana scabbard used to carry a Japanese sword. It can be strapped to the back or worn at the belt. Because of the sturdy wood casing of the scabbard, it makes an okay defensive weapon in a pinch."
Expand Down
4 changes: 2 additions & 2 deletions code/game/objects/items/storage/misc.dm
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@
desc = "A small case containing the once-standard sidearm of the UPP, the Type 73, and two additional magazines. The contained sidearm is probably looted off a dead officer or from a captured stockpile, either way this thing is worth a pretty penny."
icon = 'icons/obj/items/storage.dmi'
icon_state = "matebacase"
w_class = SIZE_MEDIUM
w_class = SIZE_LARGE
max_w_class = SIZE_MEDIUM
storage_slots = 3

Expand All @@ -143,7 +143,7 @@
desc = "A relatively large storage case containing the 1911 and additional magazines. Purchased by enlisted or aspiring PMCs looking to carry a timeless classic"
icon = 'icons/obj/items/storage.dmi'
icon_state = "matebacase"
w_class = SIZE_MEDIUM
w_class = SIZE_LARGE
max_w_class = SIZE_MEDIUM
storage_slots = 3

Expand Down
8 changes: 7 additions & 1 deletion code/game/objects/items/weapons/blades.dm
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,16 @@

/obj/item/weapon/sword/machete/arnold
name = "\improper M2100 \"Ngájhe\" machete"
desc = "An older issue USCM machete, never left testing. Designed in the Central African Republic. The notching made it hard to clean, and as such the USCM refused to adopt it - despite the superior bludgeoning power offered. Difficult to carry with the usual kit."
desc = "An older issue USCM machete, never left testing. Designed in the Central African Republic. The notching made it hard to clean, and as such the USCM refused to adopt it - despite the superior bludgeoning power offered. Difficult to carry with the usual kit ."
icon_state = "arnold-machete"
item_state = "arnold-machete"
force = MELEE_FORCE_TIER_11

/obj/item/weapon/sword/machete/arnold/weak
name = "\improper M2100 machete"
desc = "An older issue USCM machete, never left testing. Designed in the Central African Republic. The notching made it hard to clean, and as such the USCM refused to adopt it - despite the superior bludgeoning power offered. This one has been poorly maintained and as such can't really outperform adopted M2132 machete."
force = MELEE_FORCE_STRONG

/obj/item/weapon/sword/hefa
name = "HEFA sword"
icon_state = "hefasword"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@
new /obj/item/ammo_magazine/smartgun(src)
new /obj/item/storage/belt/marine/smartgunner(src)
new /obj/item/storage/belt/gun/smartgunner(src)
new /obj/item/clothing/glasses/night/m56_goggles/no_nightvision(src)

/obj/structure/closet/secure_closet/smartgunner_forecon
name = "smartgunner locker"
Expand All @@ -162,3 +163,4 @@
new /obj/item/ammo_magazine/smartgun(src)
new /obj/item/storage/belt/marine/smartgunner/standard(src)
new /obj/item/storage/belt/gun/smartgunner/standard(src)
new /obj/item/clothing/glasses/night/m56_goggles/no_nightvision(src)
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
return ..()

/obj/structure/closet/secure_closet/marine_personal/allowed(mob/M)
if(owner == M.name)
if(owner == M.real_name)
return TRUE
return FALSE

Expand Down
5 changes: 5 additions & 0 deletions code/modules/client/preferences_gear.dm
Original file line number Diff line number Diff line change
Expand Up @@ -684,6 +684,11 @@ var/global/list/gear_datums_by_name = list()
path = /obj/item/storage/box/M1911_loadout
allowed_origins = USCM_ORIGINS

/datum/gear/weapon/m2100_machete
display_name = "M2100 Machete"
path = /obj/item/storage/large_holster/machete/arnold/weak
allowed_origins = USCM_ORIGINS

/datum/gear/drink
category = "Canned drinks"

Expand Down
7 changes: 7 additions & 0 deletions code/modules/clothing/glasses/night.dm
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@
actions_types = list(/datum/action/item_action/toggle, /datum/action/item_action/m56_goggles/far_sight)
vision_flags = SEE_TURFS
fullscreen_vision = null
eye_protection = EYE_PROTECTION_FLAVOR
req_skill = SKILL_SPEC_WEAPONS
req_skill_level = SKILL_SPEC_SMARTGUN

Expand Down Expand Up @@ -198,6 +199,12 @@
else
button.icon_state = "template"

/obj/item/clothing/glasses/night/m56_goggles/no_nightvision
actions_types = list(/datum/action/item_action/toggle)
darkness_view = 0
vision_flags = 0
lighting_alpha = 255

/obj/item/clothing/glasses/night/m56_goggles/whiteout
name = "\improper M56T head mounted sight"
desc = "A headset and goggles system for the M56T 'Terminator' Smartgun. Has a low-light vision processor as well as a system allowing detection of thermal signatures though solid surfaces."
Expand Down
1 change: 1 addition & 0 deletions code/modules/cm_marines/equipment/maps.dm
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ GLOBAL_LIST_INIT_TYPED(map_type_list, /obj/item/map, setup_all_maps())
MAP_KUTJEVO = new /obj/item/map/kutjevo_map(),
MAP_LV522_CHANCES_CLAIM = new /obj/item/map/lv522_map(),
MAP_NEW_VARADERO = new /obj/item/map/new_varadero(),
MAP_NEW_VARADERO_REPAIRED = new /obj/item/map/new_varadero(),
MAP_DERELICT_ALMAYER = new /obj/item/map/almayer(),
)

Expand Down
8 changes: 5 additions & 3 deletions code/modules/defenses/defenses.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
name = "Don't see this"
desc = "Call for help."
icon = 'icons/obj/structures/machinery/defenses/sentry.dmi'
icon_state = "defense_base_off"
icon_state = "defense_base"
var/icon_off = "defense_base_off"
var/icon_on = "defense_base"
anchored = TRUE
unacidable = TRUE
density = TRUE
Expand Down Expand Up @@ -69,9 +71,9 @@
if(!composite_icon)
icon_state = null
else if(turned_on)
icon_state = "defense_base"
icon_state = icon_on
else
icon_state = "defense_base_off"
icon_state = icon_off


/obj/structure/machinery/defenses/get_examine_text(mob/user)
Expand Down
2 changes: 1 addition & 1 deletion code/modules/defenses/handheld.dm
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,9 @@
/obj/item/defenses/handheld/sentry/upp
name = "handheld UPPA 32-H sentry gun"
desc = "A compact version of the UPPA defenses. Designed for quick deployment of the associated type in the field."
icon_state = "UPP uac_sentry_handheld"
defense_type = /obj/structure/machinery/defenses/sentry/upp


// FLAMER BASE AND UPGRADES
/obj/item/defenses/handheld/sentry/flamer
name = "handheld UA 42-F sentry flamer"
Expand Down
8 changes: 8 additions & 0 deletions code/modules/defenses/sentry.dm
Original file line number Diff line number Diff line change
Expand Up @@ -762,6 +762,9 @@
/obj/structure/machinery/defenses/sentry/upp
name = "\improper UPPA 32-H sentry gun"
desc = "A deployable, semi-automated turret with AI targeting capabilities. Armed with an AK-500 Autocannon and a 500-round drum magazine."
icon_state = "upp_defense_base"
icon_on = "upp_defense_base"
icon_off = "upp_defense_base_off"
choice_categories = list(
SENTRY_CATEGORY_IFF = list(FACTION_UPP, FACTION_HUMAN),
)
Expand All @@ -770,6 +773,11 @@
SENTRY_CATEGORY_IFF = FACTION_UPP,
)
start_up_message = "Sentry mounted and loaded. Glory to the UPP."
defense_type = "UPP"
handheld_type = /obj/item/defenses/handheld/sentry/upp
fire_delay = 1.2
firing_sound = 'sound/weapons/gun_m56d_auto.ogg'
ammo = new /obj/item/ammo_magazine/sentry/upp

#undef SENTRY_FIREANGLE
#undef SENTRY_RANGE
8 changes: 2 additions & 6 deletions code/modules/gear_presets/cmb.dm
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@
rank = JOB_SQUAD_MARINE
paygrade = "ME2"
role_comm_title = "A-RFN"
skills = /datum/skills/pfc/crafty
skills = /datum/skills/pfc
faction = FACTION_MARSHAL
faction_group = list(FACTION_MARSHAL, FACTION_MARINE)

Expand Down Expand Up @@ -590,10 +590,6 @@
new_human.equip_to_slot_or_del(new /obj/item/reagent_container/hypospray/autoinjector/emergency, WEAR_IN_BELT)
new_human.equip_to_slot_or_del(new /obj/item/reagent_container/hypospray/autoinjector/emergency, WEAR_IN_BELT)
new_human.equip_to_slot_or_del(new /obj/item/bodybag/cryobag, WEAR_IN_BELT)
if(new_human.disabilities & NEARSIGHTED)
new_human.equip_to_slot_or_del(new /obj/item/clothing/glasses/hud/health/prescription, WEAR_EYES)
else
new_human.equip_to_slot_or_del(new /obj/item/clothing/glasses/hud/health, WEAR_EYES)
new_human.equip_to_slot_or_del(new /obj/item/clothing/gloves/marine, WEAR_HANDS)
new_human.equip_to_slot_or_del(new /obj/item/clothing/shoes/marine/knife, WEAR_FEET)
new_human.equip_to_slot_or_del(new /obj/item/storage/box/MRE, WEAR_IN_BACK)
Expand Down Expand Up @@ -639,4 +635,4 @@
new_human.equip_to_slot_or_del(new /obj/item/storage/belt/marine/smartgunner/full/, WEAR_WAIST)
new_human.equip_to_slot_or_del(new /obj/item/clothing/head/headband/red, WEAR_HEAD)
new_human.equip_to_slot_or_del(new /obj/item/device/radio/headset/almayer/marine/cryo, WEAR_L_EAR)
new_human.equip_to_slot_or_del(new /obj/item/clothing/glasses/night/m56_goggles, WEAR_EYES)
new_human.equip_to_slot_or_del(new /obj/item/clothing/glasses/night/m56_goggles/no_nightvision, WEAR_EYES)
3 changes: 2 additions & 1 deletion code/modules/gear_presets/dust_raider.dm
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
rank = JOB_SQUAD_MARINE
paygrade = "ME2"
role_comm_title = "RFN"
skills = /datum/skills/pfc/crafty
skills = /datum/skills/pfc

/datum/equipment_preset/dust_raider/private/load_gear(mob/living/carbon/human/new_human)
//TODO: add backpacks and satchels
Expand Down Expand Up @@ -88,6 +88,7 @@
//Backup SMG Weapon
new_human.equip_to_slot_or_del(new /obj/item/storage/belt/gun/smartgunner/full(new_human), WEAR_WAIST)
new_human.equip_to_slot_or_del(new /obj/item/clothing/head/helmet/marine(new_human), WEAR_HEAD)
new_human.equip_to_slot_or_del(new /obj/item/clothing/glasses/night/m56_goggles/no_nightvision(new_human), WEAR_EYES)
new_human.equip_to_slot_or_del(new /obj/item/storage/pouch/magazine/large/pmc_m39(new_human), WEAR_L_STORE)

//*****************************************************************************************************/
Expand Down
Loading

0 comments on commit 46177ec

Please sign in to comment.