implemented shells

This commit is contained in:
devZoGok
2025-05-14 19:34:01 +03:00
parent 6ea9baaed4
commit 94ee446741
13 changed files with 116 additions and 39 deletions
@@ -1,7 +1,21 @@
ProjectileId = {CRUISE_MISSILE = 0, TORPEDO = 1}
ProjectileClass = {CRUISE_MISSILE = 0, TORPEDO = 1}
ProjectileId = {SHELL = 0, CRUISE_MISSILE = 1, TORPEDO = 2}
ProjectileClass = {SHELL = 0, CRUISE_MISSILE = 1, TORPEDO = 2}
G = 9.8
projectiles = {
{
projectileClass = ProjectileClass.SHELL,
size = {x = 1, y = 1, z = 1},
speed = 5,
rotAngle = .1,
explosion = {damage = 100, radius = 20, sfx = PATH .. 'Sounds/SFX/Explosions/explosion02.ogg'},
directHitDamage = 200,
rayLength = 1,
name = "Shell",
basePath = PATH .. "Models/GameObjects/Projectiles/Shells/",
meshPath = "shell.xml",
albedoPath = 'shell.jpg'
},
{
projectileClass = ProjectileClass.CRUISE_MISSILE,
size = {x = 6, y = 13.5, z = 2.54},
+10 -9
View File
@@ -160,11 +160,17 @@ units = {
{
weapons = {
{
type = WeaponClass.HITSCAN,
type = WeaponClass.SHELL,
projectile = {id = ProjectileId.SHELL, pos = {x = 0.06, y = 5.82, z = 11.4}, rot = {w = 1, x = 0, y = 0, z = 0}},
rateOfFire = 1000,
damage = 200,
maxRange = 25,
fireFx = {
{
vfx = false,
duration = 300,
path = PATH .. 'Sounds/Units/Tanks/attack.ogg',
},
{
vfx = true,
duration = 50,
@@ -172,19 +178,14 @@ units = {
path = PATH .. vfxPrefix .. 'muzzleFlash.xml',
color = {x = 1, y = 1, z = 0, a = 1},
},
parent = 'Turret',
parent = 'CannonBarrel',
pos = {x = 0.06, y = 5.82, z = 11.4},
rot = {w = 1, x = 0, y = 0, z = 0},
--scale = .5
},
{
vfx = false,
duration = 300,
path = PATH .. 'Sounds/Units/Tanks/attack.ogg',
}
},
landHitFx = {explosionVfx, explosionSfx},
unitHitFx = {explosionVfx, explosionSfx}
--landHitFx = {explosionVfx, explosionSfx},
--unitHitFx = {explosionVfx, explosionSfx}
}
},
unitClass = UnitClass.TANK,