logo   login
right
Home Forums Downloads Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Forum Info
Forum Members: 18,537
Total Threads: 8,627
Posts: 94,210

Administrators:
DeeZire, Redemption

There are currently 107 users online.
Partner Links

Free Credit Repair

Learn the Ticket Broker Secrets
Advertisements


Generals & Zero Hour Editing Discuss any modding related issues to do with Generals and Zero Hour here.

Reply
 
LinkBack Thread Tools
Old 10-12-2005, 07:01 PM   #1 (permalink)
Senior Member
 
Join Date: May 2004
Posts: 144
Default Questions, help, and puzzlers

I got mostly some questions regarding making certain weapons.

They should be possible, but I need some ideas on how to go about it.

Here's what I'm interested in implementing:

Multi/Burst missles: Basically what the name says. You fire a projectile at a target, then it splits into multiple projectiles that go for the originally selected target. Now the tricky one I wan't to try is having one where the missles blows up and all the new missles pick their own targets based either on randomness or proximity.

Ground units moving while attacking: I figure I might have to mimic planes with their flight locomoters, but I'd like to know if having a ground unit move around while attacking an object is possible, like moving side to side or back and forth. Also, (this might be impossible or extremely difficult), having a unit with no turret appear to be moving in any direction while facing the target.
Thinimus is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 10-13-2005, 12:24 AM   #2 (permalink)
Senior Member
 
CommieDog's Avatar
 
Join Date: Oct 2004
Location: Alaska (Hell Frozen Over)
Posts: 368
Default

I created something similar to the Burst Missile you describe, but mine uses bomblets instead of smaller missiles that attempt to track a target. I could post the code if you wanted it.
CommieDog is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 10-13-2005, 12:19 PM   #3 (permalink)
Senior Member
 
Join Date: Oct 2003
Location: In front of my computer...
Posts: 215
Default

Quote:
having a unit with no turret appear to be moving in any direction while facing the target.
This is really easy, just make your body as the turret in the ini file, and link the body to a dummy for the chassis, i can post screenshots later if you need them. (I assume you mean a hovercraft.)
NukeWinter is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 10-13-2005, 05:27 PM   #4 (permalink)
Senior Member
 
Join Date: Apr 2005
Location: Gamers Heaven
Posts: 781
Send a message via AIM to SmokeyDaBear Send a message via MSN to SmokeyDaBear Send a message via Yahoo to SmokeyDaBear
Default

CommieDog please post code, i might use that logic for something else i was thinking of...
SmokeyDaBear is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 10-13-2005, 08:40 PM   #5 (permalink)
Senior Member
 
CommieDog's Avatar
 
Join Date: Oct 2004
Location: Alaska (Hell Frozen Over)
Posts: 368
Default

Here you go:

WeaponObject.ini
Code:
;------------------------------------------------------------------------------
Object MultiMissile1

  ; *** ART Parameters ***
  Draw = W3DModelDraw ModuleTag_01
    OkToChangeModelColor = Yes
    ConditionState = NONE
      Model = UBScudStrm_M
    End
  End

  ; ***DESIGN parameters ***
  DisplayName      = OBJECT:MultiMissile
  Side = Tibs
  EditorSorting   = SYSTEM
  TransportSlotCount = 1                 ;how many "slots" we take in a transport (0 == not transportable)
  VisionRange = 0.0  
  ArmorSet
    Conditions      = None
    Armor           = ProjectileArmor
    DamageFX        = None
  End

  ; *** ENGINEERING Parameters ***
  KindOf            = PRELOAD CAN_CAST_REFLECTIONS PROJECTILE
  Body = ActiveBody ModuleTag_02
    MaxHealth       = 100000.0
    InitialHealth   = 100000.0
  End

; ---- begin Projectile death behaviors
  Behavior = InstantDeathBehavior DeathModuleTag_01
    DeathTypes = ALL
    ; we detonated normally.  No effect, since it is in weapon.  Don't want to double.
    ; FX        = FX_ArtilleryBarrage
    OCL         = OCL_MultiMissileWarhead1
  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
; ---- end Projectile death behaviors

  Behavior = FireWeaponWhenDeadBehavior ModuleTag_07
    DeathWeapon   = MinigunnerCreationWeapon;MultiMissileWarheadWeapon1
    StartsActive  = Yes
  End

  Behavior = PhysicsBehavior ModuleTag_08
    Mass = 1
  End
  Behavior = MissileAIUpdate ModuleTag_09
    TryToFollowTarget = Yes 
    FuelLifetime = 10000
    InitialVelocity = 30                ; in dist/sec
    IgnitionDelay = 0
  End
  Locomotor = SET_NORMAL A10ThunderboltMissileLocomotor

  Behavior = HeightDieUpdate ModuleTag_10
    TargetHeight        = 75.0
    TargetHeightIncludesStructures = No
    OnlyWhenMovingDown  = Yes
  End

  Behavior = SpecialPowerCompletionDie ModuleTag_11
    SpecialPowerTemplate = SuperweaponMultiMissile
  End

  Geometry = Sphere
  GeometryIsSmall = Yes
  GeometryMajorRadius = 2.0

End

;------------------------------------------------------------------------------
Object MultiMissileBomblet

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

  ; ***DESIGN parameters ***
  EditorSorting     = SYSTEM
  VisionRange       = 0.0
  ArmorSet
    Conditions      = None
    Armor           = ProjectileArmor
    DamageFX        = None
  End

  ; *** ENGINEERING Parameters ***
  KindOf = PROJECTILE
  Body = ActiveBody ModuleTag_02
    MaxHealth       = 100.0
    InitialHealth   = 100.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.
    ; A projectile is not disabled, but instead loses target and scatters
    SubdualDamageCap = 200
    SubdualDamageHealRate = 100000
    SubdualDamageHealAmount = 50
  End

; ---- begin Projectile death behaviors

  Behavior = InstantDeathBehavior DeathModuleTag_01
    DeathTypes = NONE +DETONATED
    ; we detonated normally.
    ; no FX, just quiet destroy ourselves
  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

; ---- end Projectile death behaviors

  Behavior = FireWeaponWhenDeadBehavior ModuleTag_05
    DeathWeapon   = MultiMissileBombletWeapon
    StartsActive  = Yes
  End

  Behavior = PhysicsBehavior ModuleTag_06
    Mass = 1
  End
  Behavior = MissileAIUpdate ModuleTag_07
    TryToFollowTarget               = Yes
    FuelLifetime                    = 1800
    InitialVelocity                 = 150                ; in dist/sec
    IgnitionDelay                   = 0
    DistanceToTravelBeforeTurning   = 3
    IgnitionFX                      = FX_BuggyMissileIgnition
  End
  Locomotor = SET_NORMAL GenericTDMissileLocomotor

  Behavior = HeightDieUpdate ModuleTag_08
    TargetHeight        = 1.0
    TargetHeightIncludesStructures = Yes
    OnlyWhenMovingDown  = Yes
  End

  Geometry = Sphere
  GeometryIsSmall = Yes
  GeometryMajorRadius = 2.0

End
Weapon.ini:
Code:
;------------------------------------------------------------------------------
Weapon MultiMissileWarheadWeapon1
  DamageType = FLAME
  DeathType = BURNED
  ProjectileDetonationOCL = OCL_MultiMissileWarhead1
  MissileCallsOnDie = Yes
End

;------------------------------------------------------------------------------
Weapon MultiMissileBombletWeapon
  PrimaryDamage         = 150.0
  PrimaryDamageRadius   = 40.0
  AttackRange           = 125.0
  DamageType            = EXPLOSION
  DeathType             = EXPLODED
  WeaponSpeed           = 99999.0
  ProjectileDetonationFX = FX_ArtilleryBarrage
  RadiusDamageAffects   = ENEMIES NEUTRALS ALLIES
  DelayBetweenShots     = 0    ; time between shots, msec
  ClipSize              = 1    ; how many shots in a Clip (0 == infinite)
  ClipReloadTime        = 0    ; how long to reload a Clip, msec
  AutoReloadsClip       = No
End
ObjectCreationList.ini:
Code:
; -----------------------------------------------------------------------------
ObjectCreationList SUPERWEAPON_MultiMissile1
  DeliverPayload
    Transport                       = BigMissile ;Can substitute with another transport vehicle, look at the Artillery Barrage OCL code
    FormationSize                   = 1
    StartAtPreferredHeight          = Yes
    StartAtMaxSpeed                 = Yes
    MaxAttempts                     = 1                   ;max attempts
    DeliveryDistance                = 50                  ;distance from target allowed to start/stop dropping.
    VisibleItemsDroppedPerInterval  = 1                   ;Drops two bombs at a time
    VisibleDropBoneBaseName         = RootTransform       ;The bombs are created and dropped at this bone base
    VisibleSubObjectBaseName        = Bomb                ;The bombs are visible until dropped.
    VisibleNumBones                 = 1                   ;Number of bones.
    VisiblePayloadTemplateName      = MultiMissile1       ;Created when payload is dropped.
    VisiblePayloadWeaponTemplate    = MinigunnerCreationWeapon ;Doesn't really matter
    InheritTransportVelocity        = Yes                 ;The bombs will start at transport velocity.
    SelfDestructObject              = Yes                 ; so the delivery vehicle goes away 'POP!'
    DeliveryDecalRadius = 150
    DeliveryDecal
      Texture           = SCCNuclearMissile_China
      Style             = SHADOW_ALPHA_DECAL
      OpacityMin        = 25%
      OpacityMax        = 50%
      OpacityThrobTime  = 500
      Color             = R:255 G:0 B:0 A:255 
      OnlyVisibleToOwningPlayer = Yes
    End
  End
End

; -----------------------------------------------------------------------------
ObjectCreationList OCL_MultiMissileWarhead1
  CreateObject
    ObjectNames = MultiMissileBomblet
    Disposition = SEND_IT_FLYING RANDOM_FORCE
    DispositionIntensity = 0.4
    Count = 5
  End
End
CommieDog is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 10-15-2005, 02:42 PM   #6 (permalink)
Senior Member
 
Join Date: May 2004
Posts: 144
Default

Thanks for the examples, they're a big help.

For the moving autmoatically while attacking, I'm thinking I'll have to do something along the lines of the US sentry/scout/hellfire drones.

I'm working on a hovering type vehicle that always faces what it is attacking, but appears to be strafing sideways and moving back and forth during attacks.
Thinimus is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 10-15-2005, 02:55 PM   #7 (permalink)
Senior Member
 
Join Date: Apr 2005
Location: Gamers Heaven
Posts: 781
Send a message via AIM to SmokeyDaBear Send a message via MSN to SmokeyDaBear Send a message via Yahoo to SmokeyDaBear
Default

thanx commie
SmokeyDaBear is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 04:32 PM.


Design By: Miner Skinz.com
Powered by vBulletin® Version 3.7.0 Release Candidate 2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.