Skip to content

Commit

Permalink
Merge pull request Civ13#2833 from KanohaShinobi/master
Browse files Browse the repository at this point in the history
japanese tanks and MGs
  • Loading branch information
KanohaShinobi authored May 14, 2024
2 parents 803b3e1 + 869a7b2 commit a5cbd69
Show file tree
Hide file tree
Showing 19 changed files with 202 additions and 7 deletions.
3 changes: 3 additions & 0 deletions code/modules/1713/machinery/modular_vehicles/carparts/cars.dm
Original file line number Diff line number Diff line change
Expand Up @@ -778,6 +778,9 @@
/obj/structure/engine/internal/diesel/premade/chiha
enginesize = 25000

/obj/structure/engine/internal/diesel/premade/hago
enginesize = 10000

/obj/structure/engine/internal/gasoline/premade/falcon
enginesize = 6500

Expand Down
15 changes: 15 additions & 0 deletions code/modules/1713/machinery/modular_vehicles/carparts/premade.dm
Original file line number Diff line number Diff line change
Expand Up @@ -640,6 +640,21 @@
"3,4" = list(/obj/structure/vehicleparts/movement/tracks/reversed,/obj/structure/vehicleparts/frame/chi_ha/lb,/obj/item/weapon/reagent_containers/glass/barrel/fueltank/tank/fueleddiesel)
)

/obj/effects/premadevehicles/tank/hago
name = "Type 95 Ha-Go"
icon_state = "3x3"
custom_color = "#6a5a3d"
axis = /obj/structure/vehicleparts/axis/heavy/hago
tocreate = list(
"1,1" = list(/obj/structure/vehicleparts/movement/tracks/hago/right,/obj/structure/vehicleparts/frame/hago/rf,/obj/structure/bed/chair/drivers/tank),
"2,1" = list(/obj/structure/vehicleparts/movement/tracks/hago/left,/obj/structure/vehicleparts/frame/hago/lf,/obj/structure/bed/chair/mgunner/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97),

"1,2" = list(/obj/structure/vehicleparts/frame/hago/rc,),
"2,2" = list(/obj/structure/vehicleparts/frame/hago/lc, /obj/structure/turret/hago),

"1,3" = list(/obj/structure/vehicleparts/frame/hago/rb,/obj/structure/vehicleparts/movement/tracks/hago/left/reversed,/obj/structure/engine/internal/diesel/premade/hago,/obj/item/weapon/reagent_containers/glass/barrel/fueltank/tank/fueleddiesel),
"2,3" = list(/obj/structure/vehicleparts/frame/hago/lb,/obj/structure/vehicleparts/movement/tracks/hago/right/reversed,/obj/structure/shellrack/full37,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97,/obj/item/ammo_magazine/type99/type97),
)
/obj/effects/premadevehicles/tank/l3
name = "L3/33"
icon_state = "3x3"
Expand Down
56 changes: 54 additions & 2 deletions code/modules/1713/machinery/modular_vehicles/carparts/tanks.dm
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@
w_left = list("c_wall",TRUE,TRUE,25,25,FALSE,FALSE)
/obj/structure/vehicleparts/frame/m13/right
w_right = list("c_wall",TRUE,TRUE,25,25,FALSE,FALSE)

/obj/structure/vehicleparts/frame/m13/left/door
w_left = list("c_door",TRUE,TRUE,25,25,TRUE,TRUE)
/obj/structure/vehicleparts/frame/m13/right/door
Expand Down Expand Up @@ -370,6 +370,9 @@
w_left = list("c_wall",TRUE,TRUE,70,70,FALSE,FALSE)
w_front = list("c_armoredfront",TRUE,TRUE,75,75,FALSE,FALSE)

/////////////////////////////////////////////////////////////////////////////////////
/////////////////JAPAN///////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////

/obj/structure/vehicleparts/frame/i_go

Expand Down Expand Up @@ -429,6 +432,55 @@
w_left = list("c_wall",TRUE,TRUE,25,50,FALSE,FALSE)
w_front = list("c_armoredfront",TRUE,TRUE,25,50,FALSE,FALSE)

/obj/structure/vehicleparts/frame/hago
icon = 'icons/obj/vehicles/tankparts.dmi'
normal_icon = 'icons/obj/vehicles/tankparts.dmi'
broken_icon = 'icons/obj/vehicles/vehicleparts_damaged.dmi'

/// front
/obj/structure/vehicleparts/frame/hago/lf
icon_state = "hago_frame_lf"
w_front = list("hago_fl_frame",FALSE,FALSE,12,50,FALSE,FALSE,TRUE)
w_left = list("none",TRUE,TRUE,12,50,FALSE,FALSE)
override_roof_icon = "hago_fl_roof"
override_frame_icon = "hago_fl_frame"
/obj/structure/vehicleparts/frame/hago/rf
icon_state = "hago_frame_rf"
w_front = list("hago_fr_frame",TRUE,TRUE,12,50,FALSE,FALSE)
w_right = list("none",TRUE,TRUE,12,50,FALSE,FALSE)
override_roof_icon = "hago_fr_roof"
override_frame_icon = "hago_fr_frame"
/// middle
/obj/structure/vehicleparts/frame/hago/lc
icon_state = "hago_frame_cl"
w_left = list("hago_cl_frame",TRUE,TRUE,10,50,TRUE,TRUE)
override_roof_icon = "hago_cl_roof"
override_frame_icon = "hago_cl_frame"

/obj/structure/vehicleparts/frame/hago/rc
icon_state = "hago_frame_cr"
w_right = list("hago_cr_frame",TRUE,TRUE,10,50,FALSE,FALSE)
override_roof_icon = "hago_cr_roof"
override_frame_icon = "hago_cr_frame"

/// back
/obj/structure/vehicleparts/frame/hago/lb
icon_state = "hago_frame_bl"
w_back = list("hago_bl_frame",TRUE,TRUE,6,50,FALSE,FALSE)
w_left = list("none",TRUE,TRUE,10,50,FALSE,FALSE)
override_roof_icon = "hago_bl_roof"
override_frame_icon = "hago_bl_frame"

/obj/structure/vehicleparts/frame/hago/rb
icon_state = "hago_frame_br"
w_back = list("hago_br_frame",TRUE,TRUE,6,50,FALSE,FALSE)
w_right = list("none",TRUE,TRUE,10,50,FALSE,FALSE)
override_roof_icon = "hago_br_roof"
override_frame_icon = "hago_br_frame"

//////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////////////

/obj/structure/vehicleparts/frame/m4
/obj/structure/vehicleparts/frame/m4/front
w_front = list("c_wall",TRUE,TRUE,30,50,FALSE,FALSE)
Expand Down Expand Up @@ -906,7 +958,7 @@
/obj/structure/vehicleparts/frame/is2/rbc
icon_state = "is2_frame_steel_middle_back_right"
w_right = list("is2_middle_back_right_frame",TRUE,TRUE,90,90,TRUE,TRUE)

/// back
/obj/structure/vehicleparts/frame/is2/lb
icon_state = "is2_frame_steel_back_left"
Expand Down
16 changes: 16 additions & 0 deletions code/modules/1713/machinery/modular_vehicles/movement.dm
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,22 @@
base_icon = "m41_tracks_right_back"
movement_icon = "m41_tracks_right_back_m"

/obj/structure/vehicleparts/movement/tracks/hago/left
icon = 'icons/obj/vehicles/tankparts.dmi'
icon_state = "hago_tracks_l"
base_icon = "hago_tracks_l"
movement_icon = "hago_tracks_l_m"

/obj/structure/vehicleparts/movement/tracks/hago/right
icon = 'icons/obj/vehicles/tankparts.dmi'
icon_state = "hago_tracks_r"
base_icon = "hago_tracks_r"
movement_icon = "hago_tracks_r_m"
/obj/structure/vehicleparts/movement/tracks/hago/left/reversed
reversed = TRUE
/obj/structure/vehicleparts/movement/tracks/hago/right/reversed
reversed = TRUE

/obj/structure/vehicleparts/movement/tracks/apc/left
icon = 'icons/obj/vehicles/apcparts96x96.dmi'
icon_state = "tracks_end_left"
Expand Down
4 changes: 4 additions & 0 deletions code/modules/1713/machinery/modular_vehicles/wheels.dm
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,10 @@
mg = new/obj/item/weapon/gun/projectile/automatic/type99(src)
..()

/obj/structure/bed/chair/mgunner/type97/New()
mg = new/obj/item/weapon/gun/projectile/automatic/type99/type97tank(src)
..()

/obj/structure/bed/chair/mgunner/user_unbuckle_mob(mob/user)
var/mob/living/M = unbuckle_mob()
if (M)
Expand Down
12 changes: 12 additions & 0 deletions code/modules/1713/machinery/vehicles.dm
Original file line number Diff line number Diff line change
Expand Up @@ -561,6 +561,18 @@
tank_names_japanese -= pickedname
name = "[name] \'[pickedname]\'"

/obj/structure/vehicleparts/axis/heavy/hago
name = "Type 95 Ha-Go"
speeds = 4
speedlist = list(1=8,2=5,3=3,4=2)
color = "#6a5a3d"
reg_number = ""
New()
..()
var/pickedname = pick(tank_names_japanese)
tank_names_japanese -= pickedname
name = "[name] \'[pickedname]\'"

/obj/structure/vehicleparts/axis/heavy/m4
name = "M-4 Sherman"
speeds = 4
Expand Down
7 changes: 7 additions & 0 deletions code/modules/1713/siege/cannon_types.dm
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,13 @@
maxrange = 25
caliber = 57

/obj/structure/cannon/modern/tank/japanese37
name = "Type 94 Cannon"
desc = "A 37mm Japanese tank-based cannon."
icon_state = "tank_cannon"
maxrange = 25
caliber = 37

/obj/structure/cannon/modern/tank/german88
name = "8.8 cm KwK 36"
desc = "A 88mm German tank-based cannon."
Expand Down
26 changes: 26 additions & 0 deletions code/modules/1713/siege/shell.dm
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,22 @@
name = "[caliber]mm [atype] shell"
icon_state = "shell[atype]"

/obj/item/cannon_ball/shell/tank/HE37
atype = "HE"
caliber = 37
heavy_armor_penetration = 5
damage = 225
/obj/item/cannon_ball/shell/tank/AP37
atype = "AP"
caliber = 37
heavy_armor_penetration = 65
damage = 95
/obj/item/cannon_ball/shell/tank/APCR37
atype = "APCR"
caliber = 37
heavy_armor_penetration = 85
damage = 115

/obj/item/cannon_ball/shell/tank/HE45
atype = "HE"
caliber = 45
Expand Down Expand Up @@ -604,6 +620,16 @@
new /obj/item/cannon_ball/shell/tank/APCR57(storage)
update_icon()

/obj/structure/shellrack/full37/New()
..()
for (var/i=1, i<=4, i++)
new /obj/item/cannon_ball/shell/tank/HE37(storage)
for (var/i=1, i<=8, i++)
new /obj/item/cannon_ball/shell/tank/AP37(storage)
for (var/i=1, i<=4, i++)
new /obj/item/cannon_ball/shell/tank/APCR37(storage)
update_icon()

/obj/structure/shellrack/full45/New()
..()
for (var/i=1, i<=6, i++)
Expand Down
26 changes: 26 additions & 0 deletions code/modules/1713/siege/turret.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1261,4 +1261,30 @@
commander_seat.setup(src)
weapons.Add(new/obj/structure/cannon/modern/tank/japanese57(src))
weapons.Add(new/obj/item/weapon/gun/projectile/automatic/type99/type97tank(src))
..()

/obj/structure/turret/hago
turret_color = "#6a5a3d"
turret_icon = "type95_turret"
name = "Type 95 Ha-Go"
density = 0

turret_x = 0
turret_y = 0

gunner_x = 0
gunner_y = 0

commander_x = 0
commander_y = 0

rotation_speed = 2

New()
gunner_seat = new /obj/structure/bed/chair/gunner(src.loc)
gunner_seat.setup(src)
commander_seat = new /obj/structure/bed/chair/commander(src.loc)
commander_seat.setup(src)
weapons.Add(new/obj/structure/cannon/modern/tank/japanese37(src))
weapons.Add(new/obj/item/weapon/gun/projectile/automatic/type99/type97tank(src))
..()
18 changes: 16 additions & 2 deletions code/modules/1713/weapons/attachment.dm
Original file line number Diff line number Diff line change
Expand Up @@ -285,11 +285,25 @@ Current Defines (_defines/attachment.dm)
/// JAPANESE ///

/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type97
name = "Type 97"
desc = "You can attach this to japanese ww2 sniper rifles and machineguns"
name = "Type 97 Optic"
desc = "You can attach this to japanese arisaka rifles."
icon_state = "type97"
mount = "type97_cronstein"

/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type99
name = "Type 99 Optic"
desc = "You can attach this to japanese mgs."
icon_state = "type99"
mount = "type99_cronstein"
/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type99/type96
name = "Type 96 Optic"

/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type97tank
name = "Type 97 Scope"
desc = "You can attach this to the type 97 heavy tank rifle."
icon_state = "type97_tank"
mount = "type97_tank"

/// FRENCH ///

/obj/item/weapon/attachment/scope/adjustable/sniper_scope/apx
Expand Down
24 changes: 22 additions & 2 deletions code/modules/1713/weapons/guns/mg/lmg.dm
Original file line number Diff line number Diff line change
Expand Up @@ -111,14 +111,28 @@
throwforce = 30
attachment_slots = ATTACH_IRONSIGHTS|ATTACH_SCOPE|ATTACH_BARREL
slowdown = 0.2
has_telescopic = TRUE
scope_mounts = list("type99_cronstein")
// has_telescopic = TRUE
slot_flags = SLOT_SHOULDER
/obj/item/weapon/gun/projectile/automatic/type99/New()
..()
var/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type99/SP = new/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type99(src)
SP.attached(null,src,TRUE)

/obj/item/weapon/gun/projectile/automatic/type99/type97tank
name = "Type 97 tank machinegun"
desc = "The Type 97 tank machine Gun, is a Japanese machine gun based on the ZB26 designed specifically for tank use."
scope_mounts = list("type97_tank")
magazine_type = /obj/item/ammo_magazine/type99/type97
good_mags = list(/obj/item/ammo_magazine/type99/type97)
icon_state = "type97lmg"
item_state = "type99lmg"
base_icon = "type97lmg"

/obj/item/weapon/gun/projectile/automatic/type99/type97tank/New()
..()
var/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type97tank/SP = new/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type97tank(src)
SP.attached(null,src,TRUE)

/obj/item/weapon/gun/projectile/automatic/type96
name = "Type 96 light machinegun"
Expand All @@ -133,11 +147,17 @@
weight = 9.0
attachment_slots = ATTACH_IRONSIGHTS|ATTACH_SCOPE|ATTACH_BARREL
slowdown = 0.2
has_telescopic = TRUE
// has_telescopic = TRUE
scope_mounts = list("type99_cronstein")
slot_flags = SLOT_SHOULDER
firemodes = list(
list(name = "automatic", burst=1, burst_delay=0.4, move_delay=4, dispersion = list(0.2, 0.1, 0.4, 0.6, 0.2), recoil = 0))

/obj/item/weapon/gun/projectile/automatic/type96/New()
..()
var/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type99/type96/SP = new/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type99/type96(src)
SP.attached(null,src,TRUE)

/obj/item/weapon/gun/projectile/automatic/dp28
name = "DP-28"
desc = "The DP-28 light machinegun. This one is in 7.62x54mmR."
Expand Down
2 changes: 1 addition & 1 deletion code/modules/projectiles/guns/projectile.dm
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@

update_icon()
if (has_telescopic)
var/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type97/A = new /obj/item/weapon/attachment/scope/adjustable/sniper_scope/type97(src)
var/obj/item/weapon/attachment/scope/adjustable/sniper_scope/type99/A = new /obj/item/weapon/attachment/scope/adjustable/sniper_scope/type99(src)
spawn_add_attachment(A, src)
else
var/obj/item/weapon/attachment/A = new /obj/item/weapon/attachment/scope/iron_sights(src)
Expand Down
Binary file modified icons/obj/gun_att.dmi
Binary file not shown.
Binary file modified icons/obj/guns/mgs.dmi
Binary file not shown.
Binary file modified icons/obj/guns/parts.dmi
Binary file not shown.
Binary file added icons/obj/vehicles/hago.dmi
Binary file not shown.
Binary file modified icons/obj/vehicles/tankparts.dmi
Binary file not shown.
Binary file modified icons/obj/vehicles/vehicleparts_damaged.dmi
Binary file not shown.
Binary file modified icons/obj/vehicles/vehicles256x256.dmi
Binary file not shown.

0 comments on commit a5cbd69

Please sign in to comment.