Jump to content


thermobaric multiple warhead tomahawk


  • Please log in to reply
1 reply to this topic

#1 Guest_Guest_phoenix_*_*

Guest_Guest_phoenix_*_*
  • Guests

Posted 02 September 2004 - 03:25 AM

ok, i know that sounds like a mouthful, but what i'm trying to do is launch a tomahawk missile that explodes into 4 separate aurora bombs that will each then seek its own target and explode a fuel air gas explosion.

my idea is to use the carpetbomb model that launches some bombs that then explode into smaller clusters causing damage on a large area

can somebody help me out and i realize when you look at this code that it's an unbalanced weapon cuz it's too powerful but i'd appreciate it if someone could help to see if it would work. so far it errored out saying: Release Crash at Wed Sep 01 23:08:03 2004
; Reason Uncaught Exception during initialization.

Last error:


Current stack:

anyway so here's what i did
in weapon.ini


;------------------------------------------------------------------------------
Weapon CIC_ATACMSWeapon
PrimaryDamage = 380.0 ;150.0
PrimaryDamageRadius = 30.0
SecondaryDamage = 75.0
SecondaryDamageRadius = 60.0
ScatterRadiusVsInfantry = 20.0 ;When this weapon is used against infantry, it can randomly miss by as much as this distance.
AttackRange = 550.0 ;350.0
PreAttackDelay = 250
PreAttackType = PER_SHOT ; Do the delay every single shot
MinimumAttackRange = 300.0
LeechRangeWeapon = Yes
DamageType = EXPLOSION
DeathType = EXPLODED
FireFX = FX_TomahawkIgnition
ProjectileObject = ThermobaricMissile
ProjectileExhaust = TomahawkMissileExhaust
VeterancyProjectileExhaust = HEROIC HeroicTomahawkMissileExhaust ProjectileDetonationFX=CIC_FX_ATACMSExplode ;WeaponFX_SCUDMissileDetonationExplosive
DamageDealtAtSelfPosition = Yes
ProjectileDetonationOCL = OCL_ThermobaricBombObject;SupW_OCL_FuelAirBomb
RadiusDamageAffects = SELF ALLIES ENEMIES NEUTRALS NOT_SIMILAR
FireSound = TomahawkWeapon
DelayBetweenShots = 1000
ClipSize = 1 ; how many shots in a Clip (0 == infinite)
ClipReloadTime = 8000 ; how long to reload a Clip, msec
; Uses a clip of one to get the Reloading modelcondition
CapableOfFollowingWaypoints = Yes

; 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

in weaponobjects.ini

;------------------------------------------------------------------------------
Object ThermobaricMissile

; *** ART Parameters ***
Draw = W3DModelDraw ModuleTag_01
OkToChangeModelColor = Yes
DefaultConditionState
Model = AVTomahawk_M
End
ConditionState = JAMMED
ParticleSysBone = None SparksMedium
End
End

; ***DESIGN parameters ***
DisplayName = OBJECT:TomahawkMissile
EditorSorting = SYSTEM
VisionRange = 0.0
TransportSlotCount = 1
ArmorSet
Conditions = None
Armor = ProjectileArmor
DamageFX = None
End

; *** ENGINEERING Parameters ***
KindOf = PRELOAD CAN_CAST_REFLECTIONS PROJECTILE SMALL_MISSILE
Body = ActiveBody ModuleTag_02
MaxHealth = 100.0
InitialHealth = 100.0
SubdualDamageCap = 200
SubdualDamageHealRate = 100000
SubdualDamageHealAmount = 50
End

Behavior = DestroyDie ModuleTag_03
;nothing
End

End
Behavior = InstantDeathBehavior DeathModuleTag_02
DeathTypes = NONE +LASERED
; shot down by laser.
FX = FX_GenericMissileDisintegrate
OCL = OCL_GenericMissileDisintegrate
End
Behavior = InstantDeathBehavior DeathModuleTag_03
DeathTypes = ALL -LASERED -DETONATED
; shot down by nonlaser.
FX = FX_GenericMissileDeath
End
Behavior = FireWeaponWhenDeadBehavior ModuleTag_04
DeathWeapon = ThermobaricMissile
StartsActive = Yes
End

Behavior = HeightDieUpdate ModuleTag_05
TargetHeight = 1.0
TargetHeightIncludesStructures = No
End
Behavior = PhysicsBehavior ModuleTag_06
Mass = 1
End
Behavior = MissileAIUpdate ModuleTag_07
TryToFollowTarget = Yes
FuelLifetime = 8000
InitialVelocity = 75 ; in dist/sec
IgnitionDelay = 30
IgnitionFX = FX_NapalmMissileIgnition
DistanceToTravelBeforeTurning = 60
DistanceToTargetBeforeDiving = 100
End
Locomotor = SET_NORMAL ThermobaricMissileLocomotor
Behavior = FXListDie ModuleTag_08
DeathFX = FX_BuggyNewDeathExplosion
OrientToObject = No
End
Geometry = Sphere
GeometryIsSmall = Yes
GeometryMajorRadius = 1.0

End

;------------------------------------------------------------------------------
Object ThermobaricBombObject

; *** ART Parameters ***
Draw = W3DModelDraw ModuleTag_01
DefaultConditionState
Model = EXCarptBmb
End
End

; ***DESIGN parameters ***
DisplayName = OBJECT:FuelAirBomb
EditorSorting = SYSTEM
TransportSlotCount = 10 ;how many "slots" we take in a transport (0 == not transportable)
VisionRange = 300.0
ShroudClearingRange = 0
ArmorSet
Conditions = None
Armor = ProjectileArmor
DamageFX = None
End

; *** AUDIO Parameters ***
SoundFallingFromPlane = DaisyCutterWeapon
; *** ENGINEERING Parameters ***
KindOf = PROJECTILE
Body = ActiveBody ModuleTag_02
MaxHealth = 100.0
InitialHealth = 100.0
End

Behavior = CreateObjectDie ModuleTag_03
CreationList = OCL_ThermobaricBombObject
End
Behavior = FXListDie ModuleTag_04
;DeathFX = FX_DaisyCutterExplode
DeathFX = AirF_FX_AuroraBombExplode
End
Behavior = DestroyDie ModuleTag_05
;nothing
End

Behavior = PhysicsBehavior ModuleTag_06
Mass = 75.0
AerodynamicFriction = 1 ; this is now friction-per-sec
ForwardFriction = 33 ; this is now friction-per-sec
CenterOfMassOffset = 2 ; Default of 0 means nothing tips as it falls. Positive tips forward, negative tips back
End
Behavior = MissileAIUpdate ModuleTag_07
TryToFollowTarget = Yes
FuelLifetime = 0
IgnitionDelay = 0
InitialVelocity = 0 ; in dist/sec
DistanceToTravelBeforeTurning = 0
DistanceToTargetBeforeDiving = 0
End
Behavior = HeightDieUpdate ModuleTag_07
TargetHeight = 30.0
TargetHeightIncludesStructures = Yes
End
Locomotor = SET_NORMAL AuroraBombLocomotor ; yes, that's right.
Geometry = Sphere
GeometryIsSmall = Yes
GeometryMajorRadius = 12.0

End

finally in objectcreationlist.ini

; -----------------------------------------------------------------------------
; The daisy cutter bomb blows up and releases these objects to continue
; the "weapon bomb" process
; -----------------------------------------------------------------------------
ObjectCreationList OCL_ThermobaricBombObject ;SupW_OCL_FuelAirBomb

; This daisy cutter gas is the actual object that does the damage
CreateObject
ObjectNames = SupW_AuroraFuelAirGas
Disposition = LIKE_EXISTING
End

; Random debris for the bomb shell breaking up
CreateDebris
ModelNames = GXMammoth_D01 GXMammoth_D02 GXMammoth_D03 GXMammoth_D04
Count = 4
Mass = 5.0
Disposition = SEND_IT_FLYING
DispositionIntensity = 1.5
End
End

PLEASE HELP GUYS :) :grin:

#2 beng

beng
  • Members
  • 93 posts

Posted 25 June 2008 - 04:35 AM

Please put your code in CODE tags as it is hard to read it when it is not indented.

If you have ZH, what does world builder say when you run it with the mod installed?

You can also try debugging by deleting parts of the code and seeing if the game will work, then you can narrow it down to the section of code that is causing the crash.

As for the concept, it is similar to something i did in a zero hour map.ini where a ballistic missile submarine launches a SLBM that flies over the target area and releases a number of MIRVs, each of which will search for a target and attack it. Hoever my MIRVs were nukes, not thermobaric warheads.

In your case what you need is to make the tomahawk missile fly quite high, say height 120, then when it dives over the target area, have a height die kill it at say height 100, but put in "only when moving down" so that it does not die when it flies over hills and the height goes below the height die height.

You may want to make it so that it does not release the multiple warheads when shot down, so put the OCL that creates the warheads inside a death behavior that works for DeathTypes = NONE +NORMAL , then only gattling canons will make it release warheads when killed as stinger site missiles and patriots and lasers cause different death types.

For the warheads, make them to use the aurora jet ai instead of missileAI. Make their attack locomotor a thrust one, say the scorpion missile locomotor, and their other locomotor a wings one, like mig jet locomotor.

Give the warheads also a weaponset with a dummy weapon like the tunnel network dummy gun as secondary weapon, and suicide weapon as primary weapon.

In the jet ai module, put in a turret spec like the one from the comanche, with turn and pitch rates set to 0. Make the turret control both weapon slots. Also set the auto acquire enemies to yes and mood attack check to 100

Then what will happen is:

tomahawk missile flies to target

if shot down by other than gattling, just dies without releasing warheads

else, when reaches distance to target before diving, it starts to dive

when it reaches height die height, it dies, triggering a slow or instant death behavior that calls an OCL

the OCL creates the warhead objects, throwing them out

the warhead objects auto acuire targets, searching within the range of their dummy weapon

since their turrents can't turn, the warheads turn towards the target

since the aurora jet style Jet AI changes their locomotor to a thust one when attacking, they invariably move towards the target,

a height die module in the warhead kills it at a height above 40 (40 is the height die height for thermobaric bomb gasses)

an instantdeathbehavior module in the warhead object then calls an OCL which creates the supw general or air force general's aurora fuel bomb gas (air force one does more damage).

The gas object explodes and does the damage when it falls to height 40.

You may also be interested in my tomahawk storm map.ini, this fires missiles which dispense combined effects submunitions over the target. They are unguided cluster bombs though.

Edited by beng, 25 June 2008 - 11:55 AM.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users