hey all. i have a artillery unit, the M110, in my mod. i dont want the turret to go up and down depeding on where the target is...i just want the turret to fire at a certain angle. 45degrees is fine i think...anyways, when i had it in-game, it couldnt target structures for some reason. so i completely re-did the weapon, now when it fires, the shell would just blow up right in front of the unit! it would fire, then blow up right when it was fired...plz help...i even commented out the FirePitch and all things related to it to see if that was the problem....didnt work still. thx in advance
Code:
WEAPON.INI
---------------------
;------------------------------------------------------------------------------
Weapon M110GunWeapon
PrimaryDamage = 110.0
PrimaryDamageRadius = 15.0
ScatterRadiusVsInfantry = 15.0 ;When this weapon is used against infantry, it can randomly miss by as much as this distance.
AttackRange = 320
MinimumAttackRange = 110.0
;MinTargetPitch = 45
;MaxTargetPitch = 45
DamageType = ARMOR_PIERCING
DeathType = EXPLODED
FireFX = WeaponFX_GenericTankGunNoTracer
VeterancyFireFX = HEROIC WeaponFX_HeroicGenericTankGunNoTracer
ProjectileObject = OverlordTankShell
ProjectileDetonationFX = WeaponFX_BombTruckDefaultBombDetonation
RadiusDamageAffects = ALLIES ENEMIES NEUTRALS NOT_SIMILAR
FireSound = OverlordTankWeapon
DelayBetweenShots = 0
ClipSize = 1 ; how many shots in a Clip (0 == infinite)
ClipReloadTime = 4500 ; how long to reload a Clip, msec
; note, these only apply to units that aren't the explicit target
; (ie, units that just happen to "get in the way"... projectiles
; always collide with the Designated Target, regardless of these flags
ProjectileCollidesWith = STRUCTURES
End
AmericaVehicle.ini
------------------------
;----------------------------------------------------------
Object AmericaVehicleM110
; *** ART Parameters ***
SelectPortrait = M110_L
ButtonImage = M110
;UpgradeCameo1 = Upgrade_AmericaScoutDrone
;UpgradeCameo2 = Upgrade_AmericaBattleDrone
;UpgradeCameo3 = Upgrade_AmericaAdvancedTraining
;UpgradeCameo4 = Upgrade_AmericaHellfireDrone
;UpgradeCameo5 = XXX
Draw = W3DTankDraw ModuleTag_01
OkToChangeModelColor = Yes
;ProjectileBoneFeedbackEnabledSlots = PRIMARY ; WeaponLaunchBone will be shown/hidden, not just used for firing offset
DefaultConditionState
Model = m110
Turret = TURRET
; TurretPitch = TURRETEL
WeaponFireFXBone = PRIMARY TurretMS01
WeaponRecoilBone = PRIMARY BARREL
WeaponMuzzleFlash = PRIMARY TurretFX01
WeaponLaunchBone = PRIMARY TurretMS01
End
ConditionState = REALLYDAMAGED
Model = m110
End
AliasConditionState = RUBBLE
TrackMarks = EXTnkTrack.tga
End
; ***DESIGN parameters ***
DisplayName = OBJECT:M110
Side = America
EditorSorting = VEHICLE
TransportSlotCount = 3 ;how many "slots" we take in a transport (0 == not transportable)
BuildCost = 1350
BuildTime = 21.0 ;in seconds
VisionRange = 210
ShroudClearingRange = 230
Prerequisites
Object = AmericaWarFactory
Object = AmericaStrategyCenter
End
ExperienceValue = 50 50 100 150 ;Experience point value at each level
ExperienceRequired = 0 200 400 800 ;Experience points needed to gain each level
IsTrainable = Yes ;Can gain experience
WeaponSet
Conditions = None
Weapon = PRIMARY M110GunWeapon
End
ArmorSet
Conditions = None
Armor = TruckArmor
DamageFX = TankDamageFX
End
CrusherLevel = 2 ;What can I crush?: 1 = infantry, 2 = trees, 3 = vehicles
CrushableLevel = 2 ;What am I?: 0 = for infantry, 1 = for trees, 2 = general vehicles
CommandSet = AmericaVehicleM110CommandSet
; *** AUDIO Parameters ***
VoiceSelect = TomahawkVoiceSelect
VoiceMove = TomahawkVoiceMove
VoiceGuard = TomahawkVoiceMove
VoiceAttack = TomahawkVoiceAttack
SoundMoveStart = TomahawkMoveStart
SoundMoveStartDamaged = TomahawkMoveStart
UnitSpecificSounds
; These have the syntax of SomeNameSomewhereInCode = SomeNameSomewhereInLookupINIs
VoiceCreate = TomahawkVoiceCreate
TurretMoveStart = NoSound
TurretMoveLoop = TurretMoveLoopLoud
SoundEject = PilotSoundEject
VoiceEject = PilotVoiceEject
VoiceCrush = TomahawkVoiceCrush
VoiceEnter = TomahawkVoiceMove
VoiceBombard = TomahawkVoiceAttack
End
; *** ENGINEERING Parameters ***
RadarPriority = UNIT
KindOf = PRELOAD SELECTABLE DONT_AUTO_CRUSH_INFANTRY CAN_ATTACK CAN_CAST_REFLECTIONS VEHICLE SCORE
Body = ActiveBody ModuleTag_02
MaxHealth = 210.0
InitialHealth = 210.0
; Subdual damage "Subdues" you (reaction defined by BodyModule) when it passes your max health.
; The cap limits how extra-subdued you can be, and the other numbers detemine how fast it drains away on its own.
SubdualDamageCap = 360
SubdualDamageHealRate = 500
SubdualDamageHealAmount = 50
End
Behavior = AIUpdateInterface ModuleTag_03
Turret
TurretTurnRate = 0 ; turn rate, in degrees per sec
TurretPitchRate = 0
;FirePitch = 45 ; Instead of aiming pitchwise at the target, it will aim here
AllowsPitch = No
ControlledWeaponSlots = PRIMARY
End
AutoAcquireEnemiesWhenIdle = No NotWhileAttacking
End
Locomotor = SET_NORMAL M110Locomotor
Behavior = PhysicsBehavior ModuleTag_04
Mass = 50.0
End
Behavior = SlowDeathBehavior ModuleTag_05
DeathTypes = ALL -CRUSHED -SPLATTED
DestructionDelay = 500
DestructionDelayVariance = 100
FX = INITIAL FX_GenericTankDeathEffect
OCL = MIDPOINT OCL_AmericaVehicleTomahawkDie
FX = FINAL FX_AmericaVehicleTomahawkDeathExplosion
End
Behavior = DestroyDie ModuleTag_10
DeathTypes = NONE +CRUSHED +SPLATTED
End
Behavior = FXListDie ModuleTag_11
DeathTypes = NONE +CRUSHED +SPLATTED
DeathFX = FX_CarCrush
End
Behavior = CreateObjectDie ModuleTag_12
DeathTypes = NONE +CRUSHED +SPLATTED
CreationList = OCL_CrusaderTank_CrushEffect
End
; Behavior = FXListDie
; DeathTypes = ALL -CRUSHED -SPLATTED
; DeathFX = FX_GenericTankDeathEffect
; End
; Behavior = CreateObjectDie
; DeathTypes = ALL -CRUSHED -SPLATTED
; CreationList = OCL_GenericTankDeathEffect
; End
Behavior = EjectPilotDie ModuleTag_13
DeathTypes = ALL -CRUSHED -SPLATTED
ExemptStatus = HIJACKED
VeterancyLevels = ALL -REGULAR ;only vet+ gives pilot
GroundCreationList = OCL_EjectPilotOnGround
AirCreationList = OCL_EjectPilotViaParachute
End
Behavior = TransitionDamageFX ModuleTag_14
ReallyDamagedParticleSystem1 = Bone:Smoke RandomBone:Yes PSys:SmokeSmallContinuous01
ReallyDamagedFXList1 = Loc: X:0 Y:0 Z:0 FXList:FX_BattleMasterDamageTransition
End
Behavior = FlammableUpdate ModuleTag_21
AflameDuration = 5000 ; If I catch fire, I'll burn for this long...
AflameDamageAmount = 3 ; taking this much damage...
AflameDamageDelay = 500 ; this often.
End
Geometry = BOX
GeometryMajorRadius = 15.0
GeometryMinorRadius = 10.0
GeometryHeight = 10.0
GeometryIsSmall = Yes
Shadow = SHADOW_VOLUME
ShadowSizeX = 45 ; minimum elevation angle above horizon. Used to limit shadow length
End