Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds the M579 Aerial-Defence System Carrier (AKA, the AA-APC, or LAV-AD of the future) #429

Open
wants to merge 37 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 27 commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
e9f063f
Adds the M579 ADS-C
BonniePandora Sep 3, 2024
d4b7269
Update cupola_ammo.dm
BonniePandora Sep 3, 2024
be2b1b0
Update tow_ammo.dm
BonniePandora Sep 3, 2024
37a0ece
AA cannon
BonniePandora Sep 3, 2024
80d03a1
AA VLS array
BonniePandora Sep 3, 2024
f3ceff7
Update special_ammo.dm
BonniePandora Sep 3, 2024
5b1573d
Update gun_rack.dm
BonniePandora Sep 3, 2024
4925d81
Update rocket.dm
BonniePandora Sep 3, 2024
ae9cb7f
Update viewports.dm
BonniePandora Sep 3, 2024
722603e
Update areas.dm
BonniePandora Sep 3, 2024
addac33
Update vehicles.dm
BonniePandora Sep 3, 2024
8fa69e8
AA APC placeholder sprites added
BonniePandora Sep 3, 2024
d278081
Placeholder obj sprites for AA apc weapons
BonniePandora Sep 3, 2024
452ec1f
'New' interior sprites
BonniePandora Sep 3, 2024
e555729
New viewport console icon added
BonniePandora Sep 3, 2024
b233e60
AA apc turf icon
BonniePandora Sep 3, 2024
f6d6a8c
Modification of ARC ammo sprite for AA-APC
BonniePandora Sep 3, 2024
f641438
Interior for AA-APC
BonniePandora Sep 3, 2024
7c28b83
Adds the new files to the .dme
BonniePandora Sep 3, 2024
5f7bf16
Oh god please will this work
BonniePandora Sep 3, 2024
15484da
Merge branch 'master' into AA-APC
Pandoras-Alt Sep 22, 2024
5dfbdfa
Update
BonniePandora Sep 22, 2024
87a5d31
Interior .dmm fix? Here's hoping
BonniePandora Sep 22, 2024
b74ea62
I hate mapping I hate mapping
BonniePandora Sep 22, 2024
da6344d
Oh my god I hate this
BonniePandora Sep 22, 2024
67fdd7b
I may be stupid
BonniePandora Sep 22, 2024
80e6217
Awawawawa
BonniePandora Sep 22, 2024
b6b73bd
Area repathing
BonniePandora Sep 23, 2024
17c3104
Quad cannon damaged sprites done
BonniePandora Sep 27, 2024
1faaf94
Merge branch 'master' into AA-APC
BonniePandora Sep 27, 2024
15d680b
VLS array states finished
BonniePandora Sep 27, 2024
2937bad
Merge branch 'master' into AA-APC
BonniePandora Sep 27, 2024
d000b59
Requested corrections
BonniePandora Sep 27, 2024
92b68e2
Merge branch 'AA-APC' of https://github.com/BonniePandora/pandora-cms…
BonniePandora Sep 27, 2024
7375d91
Muzzle-flash offsets
BonniePandora Sep 27, 2024
af40c61
Requested changes
BonniePandora Sep 28, 2024
ef2a6c0
Merge branch 'master' into AA-APC
BonniePandora Sep 28, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions code/datums/ammo/bullet/special_ammo.dm
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,16 @@
damage = 35
penetration = ARMOR_PENETRATION_TIER_1

/datum/ammo/bullet/smartgun/aa //The base smartgun-bullet is kinda a woeful stand-in for AA cannon rounds, this should beef it up a bit more without being too OTT
name = "anti-aircraft bullet"
icon_state = "redbullet"
flags_ammo_behavior = AMMO_BALLISTIC

max_range = 18
accuracy = HIT_ACCURACY_TIER_5
damage = 35
penetration = ARMOR_PENETRATION_TIER_6

/datum/ammo/bullet/turret
name = "autocannon bullet"
icon_state = "redbullet" //Red bullets to indicate friendly fire restriction
Expand Down
3 changes: 3 additions & 0 deletions code/datums/ammo/rocket.dm
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,9 @@
/datum/ammo/rocket/ap/tank_towlauncher
max_range = 8

/datum/ammo/rocket/ap/tank_towlauncher/aa
max_range = 16

/datum/ammo/rocket/ltb
name = "cannon round"
icon_state = "ltb"
Expand Down
4 changes: 4 additions & 0 deletions code/datums/vehicles.dm
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@
name = "Movie APC"
interior_id = "apc_movie"

/datum/map_template/interior/apc_aa
name = "Anti-Air APC"
interior_id = "apc_aa"

/datum/map_template/interior/arc
name = "ARC"
interior_id = "arc"
Expand Down
16 changes: 16 additions & 0 deletions code/game/objects/structures/gun_rack.dm
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,22 @@
initial_stored = 0
allowed_type = /obj/item/ammo_magazine/hardpoint/boyars_dualcannon

/obj/structure/gun_rack/apc/frontal/aa
name = "vertical-launch-system ammo storage compartment"
icon_state = "boyars"
desc = "A small compartment that stores ammunition for the vehicle's VLS-array ."
BonniePandora marked this conversation as resolved.
Show resolved Hide resolved
max_stored = 2
initial_stored = 0
allowed_type = /obj/item/ammo_magazine/hardpoint/towlauncher/aa

/obj/structure/gun_rack/apc/boyars/aa
name = "anti-air cannon ammo storage compartment"
icon_state = "frontal"
desc = "A small compartment that stores ammunition for the vehicle's 'Bleihagel RE-RE965 Aerial-Defence System'."
max_stored = 2
initial_stored = 0
allowed_type = /obj/item/ammo_magazine/hardpoint/m56_cupola/quad_cannon

/obj/structure/gun_rack/m41/recon
icon_state = "m41arecon"
populate_type = /obj/item/weapon/gun/rifle/m41aMK1/forecon
Expand Down
151 changes: 151 additions & 0 deletions code/modules/vehicles/apc/apc_aa.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,151 @@
/obj/vehicle/multitile/apc/movie/aa
name = "M579 Aerial-Defence System Carrier"
desc = "A modification to the venerable M577 Armored Personnel Carrier, equipped with weapons systems tailored to target airborne threats. Comes with limited passenger capacity, entrance on the right."

interior_map = /datum/map_template/interior/apc_aa

hardpoints_allowed = list(
/obj/item/hardpoint/primary/aa_quadcannon,
/obj/item/hardpoint/secondary/towlauncher/aa,
/obj/item/hardpoint/support/flare_launcher,
/obj/item/hardpoint/locomotion/apc_wheels,
)

passengers_slots = 10


/obj/vehicle/multitile/apc/movie/aa/add_seated_verbs(mob/living/M, seat)
BonniePandora marked this conversation as resolved.
Show resolved Hide resolved
if(!M.client)
return
add_verb(M.client, list(
/obj/vehicle/multitile/proc/get_status_info,
/obj/vehicle/multitile/proc/open_controls_guide,
/obj/vehicle/multitile/proc/name_vehicle,
))
if(seat == VEHICLE_DRIVER)
add_verb(M.client, list(
/obj/vehicle/multitile/proc/toggle_door_lock,
/obj/vehicle/multitile/proc/switch_hardpoint,
/obj/vehicle/multitile/proc/cycle_hardpoint,
/obj/vehicle/multitile/proc/toggle_shift_click,
/obj/vehicle/multitile/proc/activate_horn,
))
else if(seat == VEHICLE_GUNNER)
add_verb(M.client, list(
/obj/vehicle/multitile/proc/switch_hardpoint,
/obj/vehicle/multitile/proc/cycle_hardpoint,
/obj/vehicle/multitile/proc/toggle_shift_click,
))

/obj/vehicle/multitile/apc/movie/aa/remove_seated_verbs(mob/living/M, seat)
BonniePandora marked this conversation as resolved.
Show resolved Hide resolved
if(!M.client)
return
remove_verb(M.client, list(
/obj/vehicle/multitile/proc/get_status_info,
/obj/vehicle/multitile/proc/open_controls_guide,
/obj/vehicle/multitile/proc/name_vehicle,
))
SStgui.close_user_uis(M, src)
if(seat == VEHICLE_DRIVER)
remove_verb(M.client, list(
/obj/vehicle/multitile/proc/toggle_door_lock,
/obj/vehicle/multitile/proc/switch_hardpoint,
/obj/vehicle/multitile/proc/cycle_hardpoint,
/obj/vehicle/multitile/proc/toggle_shift_click,
/obj/vehicle/multitile/proc/activate_horn,
))
else if(seat == VEHICLE_GUNNER)
remove_verb(M.client, list(
/obj/vehicle/multitile/proc/switch_hardpoint,
/obj/vehicle/multitile/proc/cycle_hardpoint,
/obj/vehicle/multitile/proc/toggle_shift_click,
))

/obj/vehicle/multitile/apc/movie/aa/initialize_cameras(change_tag = FALSE)
if(!camera)
camera = new /obj/structure/machinery/camera/vehicle(src)
if(change_tag)
camera.c_tag = "#[rand(1,100)] M579 \"[nickname]\" ADS-C"
if(camera_int)
camera_int.c_tag = camera.c_tag + " interior"
else
camera.c_tag = "#[rand(1,100)] M579 ADS-C"
if(camera_int)
camera_int.c_tag = camera.c_tag + " interior"

/obj/vehicle/multitile/apc/movie/aa/set_muzzle_offsets(obj/item/hardpoint/HP)
BonniePandora marked this conversation as resolved.
Show resolved Hide resolved
//sets muzzle flash offsets for APC weapons as appropriate for the movie APC, may need adjustment for AA weapons
switch(HP.slot)
if(HDPT_PRIMARY) //quadcannons
HP.muzzle_flash_pos = list(
"1" = list(8, -20),
"2" = list(25, 31),
"4" = list(-7, 27),
"8" = list(37, 9)
)
if(HDPT_SECONDARY) //frontmissiles
HP.muzzle_flash_pos = list(
"1" = list(34, 70),
"2" = list(-1, -70),
"4" = list(88, -7),
"8" = list(-56, 12)
)
if(HDPT_SUPPORT) //flare
HP.muzzle_flash_pos = list(
"1" = list(22, -20),
"2" = list(11, 32),
"4" = list(-5, 10),
"8" = list(37, 24)
)
return ..()
BonniePandora marked this conversation as resolved.
Show resolved Hide resolved

/*
** PRESETS SPAWNERS
*/
/obj/effect/vehicle_spawner/apc_aa
name = "Anti-Air APC Spawner"
icon = 'icons/obj/vehicles/movieapc.dmi'
icon_state = "apc_base_movie"
pixel_x = -64
pixel_y = -64

/obj/effect/vehicle_spawner/apc_aa/Initialize()
. = ..()
spawn_vehicle()
qdel(src)

//PRESET: no hardpoints
/obj/effect/vehicle_spawner/apc_aa/spawn_vehicle()
var/obj/vehicle/multitile/apc/movie/aa/APC = new (loc)

load_misc(APC)
load_hardpoints(APC)
handle_direction(APC)
APC.update_icon()

//PRESET: only wheels installed
/obj/effect/vehicle_spawner/apc_aa/plain/load_hardpoints(obj/vehicle/multitile/apc/movie/aa/V)
V.add_hardpoint(new /obj/item/hardpoint/locomotion/apc_wheels)

//PRESET: default hardpoints, destroyed
/obj/effect/vehicle_spawner/apc_aa/decrepit/spawn_vehicle()
var/obj/vehicle/multitile/apc/movie/aa/APC = new (loc)

load_misc(APC)
load_hardpoints(APC)
handle_direction(APC)
load_damage(APC)
APC.update_icon()

/obj/effect/vehicle_spawner/apc_aa/decrepit/load_hardpoints(obj/vehicle/multitile/apc/movie/aa/V)
V.add_hardpoint(new /obj/item/hardpoint/primary/aa_quadcannon)
V.add_hardpoint(new /obj/item/hardpoint/secondary/towlauncher/aa)
V.add_hardpoint(new /obj/item/hardpoint/support/flare_launcher)
V.add_hardpoint(new /obj/item/hardpoint/locomotion/apc_wheels)

//PRESET: default hardpoints
/obj/effect/vehicle_spawner/apc_aa/fixed/load_hardpoints(obj/vehicle/multitile/apc/movie/aa/V)
V.add_hardpoint(new /obj/item/hardpoint/primary/aa_quadcannon)
V.add_hardpoint(new /obj/item/hardpoint/secondary/towlauncher/aa)
V.add_hardpoint(new /obj/item/hardpoint/support/flare_launcher)
V.add_hardpoint(new /obj/item/hardpoint/locomotion/apc_wheels)
11 changes: 11 additions & 0 deletions code/modules/vehicles/hardpoints/hardpoint_ammo/cupola_ammo.dm
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,14 @@

/obj/item/ammo_magazine/hardpoint/m56_cupola/frontal_cannon/update_icon()
icon_state = "frontal_[current_rounds <= 0 ? "0" : "1"]"

/obj/item/ammo_magazine/hardpoint/m56_cupola/quad_cannon
name = "RE-RE965 Aerial-Defence System ammunition box"
desc = "A crate of belted caseless munitions for the ever-hungry RE-RE965 Aerial-Defence System. Comes loaded with a mix of HEI-T and AP rounds for combating aerial threats of all shapes and sizes. Lacks propellants, as it's to be used with the binary hypergolic principle."
default_ammo = /datum/ammo/bullet/smartgun/aa
gun_type = /obj/item/hardpoint/primary/aa_quadcannon
max_rounds = 2000
icon_state = "quad_1"

/obj/item/ammo_magazine/hardpoint/m56_cupola/quad_cannon/update_icon()
icon_state = "quad_[current_rounds <= 0 ? "0" : "1"]"
11 changes: 11 additions & 0 deletions code/modules/vehicles/hardpoints/hardpoint_ammo/tow_ammo.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,14 @@
default_ammo = /datum/ammo/rocket/ap/tank_towlauncher
max_rounds = 10
gun_type = /obj/item/hardpoint/secondary/towlauncher

/obj/item/ammo_magazine/hardpoint/towlauncher/aa
name = "M579 VLS Magazine"
icon = 'icons/obj/items/weapons/guns/ammo_by_faction/event.dmi'
desc = "A magazine of ground-to-ground missiles for the M579 ADS-C frontal launch system."
caliber = "rocket" //correlates to any rocket mags
icon_state = "quad_rocket"
w_class = SIZE_LARGE
default_ammo = /datum/ammo/rocket/ap/tank_towlauncher/aa
max_rounds = 4
gun_type = /obj/item/hardpoint/secondary/towlauncher/aa
37 changes: 37 additions & 0 deletions code/modules/vehicles/hardpoints/primary/aa_cannon.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
/obj/item/hardpoint/primary/aa_quadcannon
name = "Bleihagel RE-RE965 Aerial-Defence System"
desc = "A compact turret with four 20mm rotary cannons mounted in it. Normally slaved to the vehicles tracking systems, this one seems to be lacking the electronics required for such."
icon = 'icons/obj/vehicles/hardpoints/apc.dmi'

icon_state = "quad_cannon"
BonniePandora marked this conversation as resolved.
Show resolved Hide resolved
disp_icon = "apc"
disp_icon_state = "quadcannon"
activation_sounds = list('sound/weapons/gun_smartgun1.ogg', 'sound/weapons/gun_smartgun2.ogg', 'sound/weapons/gun_smartgun3.ogg')

damage_multiplier = 0.15

health = 2000
firing_arc = 300

allowed_seat = VEHICLE_GUNNER

ammo = new /obj/item/ammo_magazine/hardpoint/m56_cupola/quad_cannon
max_clips = 1

use_muzzle_flash = TRUE
angle_muzzleflash = FALSE
muzzleflash_icon_state = "muzzle_flash_double"

muzzle_flash_pos = list(
"1" = list(1, 5),
"2" = list(1, -30),
"4" = list(17, 3),
"8" = list(-17, 3)
)

scatter = 2
gun_firemode = GUN_FIREMODE_AUTOMATIC
gun_firemode_list = list(
GUN_FIREMODE_AUTOMATIC,
)
fire_delay = 0.02 SECONDS
39 changes: 39 additions & 0 deletions code/modules/vehicles/hardpoints/secondary/aa_launcher.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
/obj/item/hardpoint/secondary/towlauncher/aa
name = "Vertical-Launch System Array"
desc = "A hull-mounted vertical launch system for the M579 ADS-C, typically loaded with ground-to-air missiles, this one instead is capable of firing ground-to-ground missiles with devestating effect."

icon_state = "vls_launcher"
disp_icon = "apc"
disp_icon_state = "vlslauncher"

health = 2000
firing_arc = 120

allowed_seat = VEHICLE_GUNNER

ammo = new /obj/item/ammo_magazine/hardpoint/towlauncher/aa
max_clips = 1

px_offsets = list(
"1" = list(0, 0),
"2" = list(0, 0),
"4" = list(0, 0),
"8" = list(0, 0)
)

muzzle_flash_pos = list(
"1" = list(8, -1),
"2" = list(-8, -16),
"4" = list(5, -8),
"8" = list(-5, 10)
)

scatter = 1
fire_delay = 7.0 SECONDS
BonniePandora marked this conversation as resolved.
Show resolved Hide resolved

/obj/item/hardpoint/secondary/towlauncher/aa/set_bullet_traits()
..()
LAZYADD(traits_to_give, list(
BULLET_TRAIT_ENTRY(/datum/element/bullet_trait_iff)
))

6 changes: 5 additions & 1 deletion code/modules/vehicles/interior/areas.dm
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,13 @@
icon_state = "apc_cmd"

/area/interior/vehicle/apc/movie
name = "\improper M557A3 APC interior"
name = "\improper M577A3 APC interior"
icon_state = "apc_movie"

/area/vehicle/apc/movie/aa
Doubleumc marked this conversation as resolved.
Show resolved Hide resolved
name = "\improper M579 ADS-C interior"
icon_state = "apc_aa"

/area/interior/vehicle/van
name = "van interior"
icon_state = "van"
Expand Down
6 changes: 6 additions & 0 deletions code/modules/vehicles/interior/interactable/viewports.dm
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,9 @@
icon = 'icons/obj/vehicles/interiors/van.dmi'
icon_state = "windshield_viewport_top"
alpha = 80

//anti-air APC's interior console
/obj/structure/interior_viewport/terminal
BonniePandora marked this conversation as resolved.
Show resolved Hide resolved
name = "External Cameras Terminal"
desc = "A terminal hooked up to the various sensors of the M579 ADS-C, featuring plenty of flashing buttons and whooping alarms alongside a more rudimentary external-view system."
icon_state = "viewport_terminal"
3 changes: 3 additions & 0 deletions colonialmarines.dme
Original file line number Diff line number Diff line change
Expand Up @@ -2444,6 +2444,7 @@
#include "code\modules\vehicles\vehicle.dm"
#include "code\modules\vehicles\vehicle_misc_objects.dm"
#include "code\modules\vehicles\apc\apc.dm"
#include "code\modules\vehicles\apc\apc_aa.dm"
#include "code\modules\vehicles\apc\apc_command.dm"
#include "code\modules\vehicles\apc\apc_medical.dm"
#include "code\modules\vehicles\apc\apc_movie.dm"
Expand Down Expand Up @@ -2476,6 +2477,7 @@
#include "code\modules\vehicles\hardpoints\hardpoint_ammo\tow_ammo.dm"
#include "code\modules\vehicles\hardpoints\holder\holder.dm"
#include "code\modules\vehicles\hardpoints\holder\tank_turret.dm"
#include "code\modules\vehicles\hardpoints\primary\aa_cannon.dm"
#include "code\modules\vehicles\hardpoints\primary\arc_frontal.dm"
#include "code\modules\vehicles\hardpoints\primary\arc_sentry.dm"
#include "code\modules\vehicles\hardpoints\primary\autocannon.dm"
Expand All @@ -2484,6 +2486,7 @@
#include "code\modules\vehicles\hardpoints\primary\ltb.dm"
#include "code\modules\vehicles\hardpoints\primary\minigun.dm"
#include "code\modules\vehicles\hardpoints\primary\primary.dm"
#include "code\modules\vehicles\hardpoints\secondary\aa_launcher.dm"
#include "code\modules\vehicles\hardpoints\secondary\cupola.dm"
#include "code\modules\vehicles\hardpoints\secondary\flamer.dm"
#include "code\modules\vehicles\hardpoints\secondary\frontal_cannon.dm"
Expand Down
Binary file modified icons/obj/items/weapons/guns/ammo_by_faction/uscm.dmi
Binary file not shown.
Binary file modified icons/obj/vehicles/hardpoints/apc.dmi
Binary file not shown.
Binary file modified icons/obj/vehicles/hardpoints/tank.dmi
Binary file not shown.
Binary file modified icons/obj/vehicles/interiors/apc.dmi
Binary file not shown.
Binary file modified icons/obj/vehicles/interiors/general.dmi
Binary file not shown.
Binary file modified icons/obj/vehicles/movieapc.dmi
Doubleumc marked this conversation as resolved.
Show resolved Hide resolved
Binary file not shown.
Loading
Loading