DavisProg
  • DavisProg
  • 62% (Friendly)
  • Private Topic Starter
14 years ago
Hello,

I am using General's World Builder.
I have a question of, how to increase the attack range and attack power of a unit?
Is it able to work with map.ini?
Please help with some ini code. Thanks A Lot!
Sponsor
glumurr
14 years ago
hmm..

are you saying that you wan't to increase the attack range for..
the battlemaster for example?

if so then

if I remember it correctly.
you will have to create a new weapon for the battlemaster in map.ini

the new weapon would have a longer attack range and do more damage than the normal battlemastertank weapon.

Weapon BattleMasterTankGun_NEW
  PrimaryDamage           = 100  ;60.0 - 60 was the original damage
  PrimaryDamageRadius     = 5.0
  ScatterRadiusVsInfantry = 10.0
  AttackRange             = 200  ;150.0 - 150 was the original attack range
  MinTargetPitch          = -15
  MaxTargetPitch          = 15                       
  DamageType              = ARMOR_PIERCING
  DeathType               = NORMAL
  WeaponSpeed             = 400                      
  WeaponRecoil            = 5                         
  ProjectileObject        = BattleMasterTankShell
  FireFX                  = WeaponFX_GenericTankGunNoTracerSmall
  VeterancyFireFX         = HEROIC WeaponFX_HeroicGenericTankGunNoTracerSmall
  ProjectileDetonationFX  = WeaponFX_GenericTankShellDetonation
  FireSound               = BattlemasterTankWeapon
  RadiusDamageAffects     = ALLIES ENEMIES NEUTRALS
  DelayBetweenShots       = 2000               ; time between shots, msec
  ClipSize                = 0                    ; how many shots in a Clip (0 == infinite)
  ClipReloadTime          = 0              ; how long to reload a Clip, msec
  WeaponBonus             = PLAYER_UPGRADE DAMAGE 125% ; UraniumShells

  ; 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 WALLS 
End

then you will have to give the new weapon to the battlemaster object and just replace the old one in map.ini

Object ChinaTankBattleMaster
  WeaponSet
    Conditions = None 
    Weapon = PRIMARY BattleMasterTankGun_NEW  ;was BattleMasterTankGun
  End
End

you can do this to any unit..
I know this isn't the best explination out there but I tried.. and I hope I explained it correclty how to do it..
and if this isn't what you were looking for then I don't know what you were looking for hehe..
hmm...
if I don't reply to a topic I don't know the answer - sorry
DavisProg
  • DavisProg
  • 62% (Friendly)
  • Private Topic Starter
14 years ago

hmm..

are you saying that you wan't to increase the attack range for..
the battlemaster for example?

you can do this to any unit..
I know this isn't the best explination out there but I tried.. and I hope I explained it correclty how to do it..

glumurr wrote:



Well, thanks. It works great.
And here is my code:
Weapon AmericaInfantryMissileDefender_NEW
  PrimaryDamage               = 500.0            
  PrimaryDamageRadius         = 10.0     
  ScatterRadiusVsInfantry     = 10.0
  AttackRange                 = 300.0
  DamageType                  = Explosion
  DeathType                   = Exploded
  WeaponSpeed                 = 600               
  ProjectileObject            = MissileDefenderMissile
  ProjectileExhaust           = MissileDefenderMissileExhaust
  VeterancyProjectileExhaust  = HEROIC HeroicMissileDefenderMissileExhaust
  ProjectileDetonationFX      = WeaponFX_NukeCannon
  FireFX                      = FX_BuggyMissileIgnition
  RadiusDamageAffects         = ALLIES ENEMIES NEUTRALS
  ScatterRadius               = 0 
  DelayBetweenShots           = 5000 
  ClipSize                    = 4        
  ClipReloadTime              = 10000    
  AutoReloadsClip             = Yes 
  ShowsAmmoPips               = Yes
  FireSound                   = MissileDefenderWeapon
  WeaponBonus                 = PLAYER_UPGRADE DAMAGE 125%
  AntiAirborneVehicle         = Yes
  AntiAirborneInfantry        = Yes
  ProjectileCollidesWith      = STRUCTURES
End

And The Object:
Object AmericaInfantryMissileDefender
  WeaponSet
    Conditions = None
    Weapon = PRIMARY AmericaInfantryMissileDefender_NEW
  End
End

I would like the "missle" to explode like the "nuke cannon" because of its HIGH damage.
If there is any error in my script. Help me fix please.
Please Help With The "Projcetile" Area. Thanks a lot.
glumurr
14 years ago
well to be honest.. I don't see anything worng here.
I placed the nuke cannon fx at my missile defender and it worked fine.
but I placed it at the game, not at map.ini

so it must be a bug in map.ini or something.
I have no idea what is wrong hehe..
hmm...
if I don't reply to a topic I don't know the answer - sorry