Thread: Bugs Thread
View Single Post
  #872  
Old 12-06-2012, 09:17 PM
Fatt_Shade Fatt_Shade is offline
Approved Member
 
Join Date: Nov 2010
Location: Serbia
Posts: 837
Default

@camelotcrusade
Distance penalty for range attack units is in unit.atom file. Expl : archmage in game folder/sessions/addon/data.kfs archmage.atom look for his lightning attack
Code:
  lightning {
    group=1,2
    class=scripted
    ad_factor=1
    showdmg=1
    penalty=1
    distance=60
    base_attack=1
    script_attack=special_archmage_lightning_attack
    script_calccells=calccells_all_enemy_actors_takes_damage
    attack_cursor=archer_arrow
    damage {
      magic=5,8
    }
    custom_params {
      shock=25
    }
See that distance have value 60, so he have penalty on 60 hex, and longest arena is around 9 hex. Meaning archmage have no penalty for basic attack. On other hand runemage.atom you asked about in same data.kfs have this value
Code:
  throw1 {
    group=1,2
    class=throw
    base_attack=1
    ad_factor=1
    distance=7
    mindist=2
    showdmg=1
    penalty=0.5
    animation=attack/throw/thtarget
    throw=priest3_ball
    framekey=x
    damage {
      magic=10,12
    }
    custom_params {
      rune_num=0
    }
Meaning he have penalty 50% on distance 7 hex.
To change this just change value on distance=... to what you want, and in penalty from 0.01 to 0.99 (go nuts).

You can also check druid.atom in same .kfs archive or necromant.atom , if you want to give some aoe bonus to attack, and aoe penalty. Druid.atom :
Code:
  throw1 {
    group=1,2
    showdmg=1
    device=natureforce
    class=throw
    distance=6
    mindist=1
    base_attack=1
    penalty=0.5
    animation=attack/throw/thtarget
    throw=druid_bullet
    framekey=x
    7in1=0.5
    hint_gen_script=hint_mass_attack_throw_7in1
    damage {
      magic=4,8
    }
Here you see that druid have 50% penalty on 6 hex distance, and his attack hit 7 hex radius (7in1=) with 50% dmg on surrounding hex.
Play with it (i added aoe dmg to cannoner unit special salve attack, and it works great), and have fun.
Reply With Quote