Jump to content


Photo

Help w/ Hero's power


  • Please log in to reply
8 replies to this topic

#1 Ringwraith Captain

Ringwraith Captain
  • Members
  • 46 posts

Posted 23 November 2008 - 02:37 PM

Hi all.
I've added Gil-galad as a hero to my game, and he's working great, except for one of his powers, Vilya. It's supposed to fire a projectile at the target, similar to Saruman's fireball. I can click the button and give him a target to attack. He'll walk up and prepare to fire (I can tell by the animations), but in the middle of the animation, when the projectile is supposed to be fired, he switches back to idle without firing anything, and the power starts recharging like it was just used. I can't figure out what's wrong. I've looked at all the code I can think of, and everything looks fine to me.

Here's the relevant code from several files. If I need to post any others, let me know.
[codebox]
;******************************************************************************
;gilgalad.ini*******************************************************************
**
;******************************************************************************
;------------------------------------------------------------------------------
;
; Theoden.ini
;
;------------------------------------------------------------------------------
; Theoden
Object ElvenGilgalad
; *** ART Parameters ***

; SelectPortrait for Heros is portrait behind skill buttons. HP = HeroPortrait.
SelectPortrait = HPGilGalad

; ButtonImage for Heros is button image on Hero Select UI to select hero. HI = HeroIcon or HeroImage.
ButtonImage = HIGilGalad

Draw = W3DScriptedModelDraw ModuleTag_DRAW

WadingParticleSys = EntRipples

OkToChangeModelColor = Yes

StaticModelLODMode = no ; Will append M or L to the skin name depending on GameLOD

DefaultModelConditionState
Model = eugilgalad_skna
Skeleton = RUTheoden_SKL
End

ModelConditionState = WEAPONSET_HERO_MODE
ParticleSysBone = B_SWORDBONE Anduril FollowBone:Yes
End

AnimationState = UNPACKING SPECIAL_WEAPON_ONE ;PACKING_TYPE_1
Animation = VilyaStart
AnimationName = RUTheoden_CHRB
AnimationMode = ONCE
End
FXEvent = Frame:34 Name:FX_GilGaladVilyaStart
End

AnimationState = PREPARING SPECIAL_WEAPON_ONE ;PACKING_TYPE_1
Animation = VilyaShoot
AnimationName = RUTheoden_ATKC
AnimationMode = ONCE
;UseWeaponTiming = Yes
End
End

; --- Idle Anims
IdleAnimationState
StateName = BORED
Animation = IDLB
AnimationName = RUTheoden_IDLB
AnimationMode = ONCE
AnimationPriority = 1
End
Animation = IDLC
AnimationName = RUTheoden_IDLC
AnimationMode = ONCE
AnimationPriority = 10
End
Animation = IDLD
AnimationName = RUTheoden_IDLD
AnimationMode = ONCE
AnimationPriority = 1
End
Animation = IDLE
AnimationName = RUTheoden_IDLE
AnimationMode = ONCE
AnimationPriority = 1
End
Flags = RESTART_ANIM_WHEN_COMPLETE
BeginScript
Prev = CurDrawablePrevAnimationState()
if Prev == "SELECTED" then CurDrawableSetTransitionAnimState("Transition_SelectedToBored") end
if Prev == "READY" then CurDrawableSetTransitionAnimState("Transition_ReadyToBored") end
EndScript
End

AnimationState = FREEFALL
Animation = freefall
AnimationName = RUTheoden_FLYA
AnimationMode = LOOP
End
Flags = RANDOMSTART
End

AnimationState = STUNNED_FLAILING
Flags = RANDOMSTART
Animation = RUTheoden_FLYA
AnimationName = RUTheoden_FLYA
AnimationMode = LOOP
End
End

; --- Dying anims
AnimationState = DYING SPLATTED
Animation = RUTheoden_LNDA
AnimationName = RUTheoden_LNDA
AnimationMode = ONCE
End
End
AnimationState = DYING
Animation = RUTheoden_DIEA ; this one sucks.
AnimationName = RUTheoden_DIEA
AnimationMode = ONCE
End
Animation = RUTheoden_DIEB
AnimationName = RUTheoden_DIEB
AnimationMode = ONCE
End
End

; --- Stunned anims

AnimationState = STUNNED_STANDING_UP
Animation = RUTheoden_GTPA
AnimationName = RUTheoden_GTPA
AnimationMode = ONCE
AnimationSpeedFactorRange = 1.5 1.5
End
End
AnimationState = STUNNED
Animation = RUTheoden_LNDA
AnimationName = RUTheoden_LNDA
AnimationMode = ONCE
End
End

AnimationState = MOVING FIRING_OR_PREATTACK_A
ShareAnimation = Yes
Animation = RunAndFire
AnimationName = RUTheoden_ATRA
AnimationMode = LOOP
End
Flags = RANDOMSTART
End


; Attacking Anims
AnimationState = FIRING_OR_PREATTACK_A
Animation = ATKA
AnimationName = RUTheoden_ATKA
AnimationMode = ONCE
UseWeaponTiming = Yes
;AnimationSpeedFactorRange = .826 .826
End
Animation = ATKB
AnimationName = RUTheoden_ATKB
AnimationMode = ONCE
;AnimationSpeedFactorRange = .9066 .9066
End
Animation = ATKC
AnimationName = RUTheoden_ATKC
AnimationMode = ONCE
UseWeaponTiming = Yes
;AnimationSpeedFactorRange = 1.1466 1.1466
End
Animation = ATKD
AnimationName = RUTheoden_ATKD
AnimationMode = ONCE
UseWeaponTiming = Yes
;AnimationSpeedFactorRange = 1.0666 1.0666
End
End

AnimationState = MOVING ATTACKING
Animation = RUTheoden_RUNB
AnimationName = RUTheoden_RUNB
AnimationSpeedFactorRange = 0.4 0.4
AnimationMode = LOOP
AnimationBlendTime = 10
Distance = 24
End
End

AnimationState = MOVING
Animation = RUTheoden_RUNA
AnimationName = RUTheoden_RUNA
AnimationMode = LOOP
Distance = 24
End
End

AnimationState = PACKING_TYPE_2
StateName = SPELL
Animation = SPCC
AnimationName = RUTheoden_SPCB
AnimationSpeedFactorRange = 1.1666 1.1666
AnimationMode = ONCE
AnimationBlendTime = 20
End
Animation = SPCD
AnimationName = RUTheoden_SPCC
AnimationMode = ONCE
AnimationBlendTime = 20
End
End

; --------- Click and Hit Reactions ------------
AnimationState = HIT_REACTION HIT_LEVEL_1
Animation = Hit_Level_1_a
AnimationName = RUTheoden_HITA
AnimationMode = ONCE
End
End

;----Emotion Animations

AnimationState = LEVELED ; This state clears itself in 3 seconds
Animation = LevelUp
AnimationName = RUTheoden_CHRB
AnimationMode = ONCE
End
End

AnimationState = EMOTION_CELEBRATING
Animation = CHRA
AnimationName = RUTheoden_CHRA
AnimationMode = ONCE
End
Animation = CHRB
AnimationName = RUTheoden_CHRB
AnimationMode = ONCE
End
Flags = RESTART_ANIM_WHEN_COMPLETE
End

AnimationState = EMOTION_ALERT
StateName = READY
Animation = ready
AnimationName = RUTheoden_IDLA
AnimationMode = LOOP
AnimationBlendTime = 20
End
BeginScript
Prev = CurDrawablePrevAnimationState()
if Prev == "BORED" then CurDrawableSetTransitionAnimState("Transition_BoredToReady") end
if Prev == "SELECTED" then CurDrawableSetTransitionAnimState("Transition_SelectedToReady") end
EndScript
End

AnimationState = SELECTED
StateName = SELECTED
Animation = ATNB
AnimationName = RUTheoden_ATNB
AnimationMode = LOOP
End
BeginScript
Prev = CurDrawablePrevAnimationState()
if Prev == "BORED" then CurDrawableSetTransitionAnimState("Transition_BoredToSelected") end
if Prev == "READY" then CurDrawableSetTransitionAnimState("Transition_ReadyToSelected") end
if Prev == "SPELL" then CurDrawableSetTransitionAnimState("Transition_ReadyToSelected") end
EndScript
End

TransitionState Transition_BoredToReady
Animation = ready
AnimationName = RUTheoden_IDLA
AnimationMode = LOOP
AnimationBlendTime = 20
End
End

TransitionState Transition_ReadyToBored
Animation = IDLC
AnimationName = RUTheoden_IDLC
AnimationMode = ONCE
AnimationBlendTime = 20
End
End

TransitionState Transition_BoredToSelected
Animation = ATNA
AnimationName = RUTheoden_ATNA
AnimationMode = ONCE
End
End

TransitionState Transition_SelectedToBored
Animation = ATNE
AnimationName = RUTheoden_ATNE
AnimationMode = ONCE
End
End

TransitionState Transition_SelectedToReady
Animation = ATNC
AnimationName = RUTheoden_ATNC
AnimationMode = ONCE
End
End

TransitionState Transition_ReadyToSelected
Animation = ATNC
AnimationName = RUTheoden_ATNC
AnimationMode = ONCE_BACKWARDS
End
Flags = START_FRAME_LAST
End
End


; ***DESIGN parameters ***
Side = Elven
EditorSorting = UNIT
ThreatLevel = 4.0
ImmuneToShockwave = yes ;
ThingClass = CHARACTER_UNIT
BuildCost = 3000
BuildTime = 30

DisplayMeleeDamage = 45

TransportSlotCount = 1
WeaponSet
Conditions = NONE
Weapon = PRIMARY GilgaladSpear
AutoChooseSources = PRIMARY FROM_PLAYER FROM_SCRIPT FROM_AI
End
WeaponSet
Conditions = WEAPONSET_HERO_MODE
Weapon = PRIMARY GilgaladHeroSpear
AutoChooseSources = PRIMARY FROM_PLAYER FROM_SCRIPT FROM_AI
End

;------ Armor Sets --------
ArmorSet
Conditions = None
Armor = ToughHeroArmor
DamageFX = NormalDamageFX
End

VisionRange = VISION_STANDARD_HORSE
ShroudClearingRange = SHROUD_CLEAR_HERO

BountyValue = ROHAN_THEODEN_BOUNTY_VALUE
DisplayName = OBJECT:ElvenGilGalad
RecruitText = CONTROLBAR:ElvenGilGaladRecruit
ReviveText = CONTROLBAR:ElvenGilGaladRevive
Hotkey = CONTROLBAR:ElvenGilGaladHotkey
CrusherLevel = 0 ;Can I crush anything?
MountedCrusherLevel = 1 ;Crush level when mounted.
CrushableLevel = 2 ;What am I?: 0 = for infantry, 1 = for trees, 2 = cavalry/heroes
MountedCrushableLevel = 2 ;Crusable level when mounted.

CrushWeapon = HeroCrush

MinCrushVelocityPercent = 50 ; Has to be moving at at least 50% of full speed.
CrushDecelerationPercent = 30 ; Lose xx percent of max velocity when crushing.

CrushKnockback = 40
CrushZFactor = 1.0

CommandSet = ElvenGilgaladCommandSet
CommandPoints = 0


; *** AUDIO Parameters ***;

VoiceAttack = ElvenWarriorVoiceAttack
VoiceAttackAir = ElvenWarriorVoiceAttackBow
VoiceAttackCharge = ElvenWarriorVoiceAttackCharge
VoiceAttackStructure = ElvenWarriorVoiceAttackStructure ; ElvenWarriorVoiceAttackBuilding not recorded
VoiceAttackMachine = ElvenWarriorVoiceAttackStructure ; ElvenWarriorVoiceAttackBuilding not recorded
VoiceCreated = ElvenWarriorVoiceSalute
VoiceFullyCreated = ElvenWarriorVoiceSalute
VoiceMove = ElvenWarriorVoiceMove
VoiceMoveToCamp = ElvenWarriorVoiceMoveCamp
VoiceMoveWhileAttacking = ElvenWarriorVoiceDisengage
VoicePriority = 41
VoiceRetreatToCastle = ElvenWarriorVoiceRetreat
VoiceSelect = ElvenWarriorVoiceSelect
VoiceSelect2 = ElvenWarriorVoiceSelect2
VoiceSelectBattle = ElvenWarriorVoiceSelectBattle
VoiceGuard = ElvenWarriorVoiceMove

UnitSpecificSounds
VoiceGarrison = ElvenWarriorVoiceGarrison
VoicePrimaryWeaponMode = ElvenWarriorVoiceModeBow
VoiceSecondaryWeaponMode = ElvenWarriorVoiceModeSword
End

EvaEventDamagedOwner = UnitUnderAttack
ClientBehavior = AnimationSoundClientBehavior ModuleTag_AnimAudioBehavior
MaxUpdateRangeCap = 800
AnimationSound = Sound:FootstepDirtA Animation:RUTheoden_SKL.RUTheoden_RUNA Frames:5 16
AnimationSound = Sound:FootstepDirtA Animation:RUTheoden_SKL.RUTheoden_RUNB Frames:4 12 20 27

AnimationSound = Sound:TauntHumanHitShield Animation:RUTheoden_SKL.RUTheoden_CHRB Frames:21 31

AnimationSound = Sound:BodyFallGenericNoArmor Animation:RUTheoden_SKL.RUTheoden_DIEA Frames:47
AnimationSound = Sound:BodyFallGenericNoArmor Animation:RUTheoden_SKL.RUTheoden_DIEB Frames:19
AnimationSound = Sound:BodyFallSoldier Animation:RUTheoden_SKL.RUTheoden_LNDA Frames:1
End

Behavior = LargeGroupAudioUpdate ModuleTag_LGAU ; Tie into LargeGroupAudio system
Key = Human Unit Infantry Hero
UnitWeight = 2 ; Faramir counts as 2 infantry
End

; *** ENGINEERING Parameters ***

RadarPriority = UNIT
KindOf = HERO PRELOAD SELECTABLE CAN_CAST_REFLECTIONS INFANTRY PATH_THROUGH_EACH_OTHER SCORE ARMY_SUMMARY
PathfindDiameter = 40.0

Body = RespawnBody ModuleTag_RespawnBody
CheerRadius = EMOTION_CHEER_RADIUS
MaxHealth = 1250 ;BALANCE Theoden Health
PermanentlyKilledByFilter = NONE ;Who kills me permanently?
DodgePercent = HERO_DODGE_PERCENT
End

Behavior = RespawnUpdate ModuleTag_RespawnUpdate
DeathAnim = DYING ;Model condition to play when killed-to-respawn
DeathFX = FX_GenericDieToRespawn ;FXList to play when killed-to-respawn
DeathAnimationTime = 4000 ;How long DeathAnim will take.
InitialSpawnFX = FX_Resurrection
RespawnAnim = LEVELED ;Animation to play when respawning.
RespawnFX = FX_Resurrection ;FXList to play when respawning.
RespawnAnimationTime = 4000 ;Time it takes for respawn to play.
AutoRespawnAtObjectFilter = NONE +CASTLE_KEEP ;Respawn at this location -- and at it's exit production point if possible.
ButtonImage = HIGilGalad

;RespawnEntries determine the ruleset for how a character can be revived. Some units may automatically respawn, others
;may require a specific revive action performed on him. You can specify different values for each level... or use Level:Any
RespawnRules = AutoSpawn:No Cost:600 Time:90000 Health:100% ;DEFAULT VALUES
RespawnEntry = Level:2 Cost:700 Time:90000 ;For other levels, only override what is different.
RespawnEntry = Level:3 Cost:800 Time:90000
RespawnEntry = Level:4 Cost:900 Time:90000
RespawnEntry = Level:5 Cost:1000 Time:120000
RespawnEntry = Level:6 Cost:1100 Time:120000
RespawnEntry = Level:7 Cost:1200 Time:120000
RespawnEntry = Level:8 Cost:1300 Time:120000
RespawnEntry = Level:9 Cost:1400 Time:120000
RespawnEntry = Level:10 Cost:1500 Time:120000
End

Behavior = AutoAbilityBehavior ModuleTag_AutoAbilityBehavior
End

Behavior = AutoHealBehavior ModuleTag_TheodenHealing
StartsActive = Yes
HealingAmount = HERO_HEAL_AMOUNT
HealingDelay = 1000
StartHealingDelay = HERO_HEAL_DELAY
HealOnlyIfNotInCombat = Yes
End

Behavior = EmotionTrackerUpdate Module_EmotionTracker
TauntAndPointDistance = 300 ; max distance to taunted/pointed objet
TauntAndPointUpdateDelay = 1000 ; how often scan (milliseconds)

AddEmotion = Alert_Base
End

Behavior = AIUpdateInterface ModuleTag_03
AutoAcquireEnemiesWhenIdle = Yes ATTACK_BUILDINGS
MoodAttackCheckRate = 500
HoldGroundCloseRangeDistance = 40
AILuaEventsList = TheodenFunctions
End

LocomotorSet
Locomotor = TheodenHumanLocomotor
Condition = SET_NORMAL
Speed = NORMAL_GOOD_HERO_SPEED
End

;-------------------------------------------

;;;; Elven Gift bonus

Behavior = AutoHealBehavior ModuleTag_ElvenGiftHealing
StartsActive = No
TriggeredBy = Upgrade_ElvenGift
HealingAmount = ELVEN_GIFT_REGEN_AMOUNT
HealingDelay = ELVEN_GIFT_REGEN_DELAY
StartHealingDelay = HERO_HEAL_DELAY
HealOnlyIfNotInCombat = Yes
End

Behavior = AttributeModifierUpgrade ModuleTag_ElvenGiftBonus
TriggeredBy = Upgrade_ElvenGift
AttributeModifier = SpellBookElvenGifts
End

Behavior = PhysicsBehavior ModuleTag_04
GravityMult = 1.0
End

Behavior = HeroDie ModuleTag_HeroDeath
SpecialPowerTemplate = SpecialAbilitySmite ;the special power that I recharge by dying
End

Behavior = SlowDeathBehavior ModuleTag_05
DeathTypes = ALL
SinkDelay = 3000
SinkRate = 0.40 ; in Dist/Sec
DestructionDelay = 8000
Sound = INITIAL TheodenVoiceDie
End

Behavior = SquishCollide ModuleTag_06
;nothing
End

Behavior = HitReactionBehavior HitReactionBehaviorModuleTag
HitReactionLifeTimer1 = 7 ; level 1 (light damage) hit reaction animations in frames (5 per sec)
HitReactionLifeTimer2 = 15 ; level 2 (medium damage) hit reaction animations in frames (5 per sec)
HitReactionLifeTimer3 = 10 ; level 3 (heavy damage) hit reaction animations in frames (5 per sec)

HitReactionThreshold1 = 0.0 ; level 1 (light damage) threshold trigger
HitReactionThreshold2 = 25.0 ; level 2 (medium damage) threshold trigger
HitReactionThreshold3 = 50.0 ; level 3 (heavy damage) threshold trigger
End

;;; VILYA (Rank 4) ;;;
Behavior = UnpauseSpecialPowerUpgrade ModuleTag_FireballEnabler
SpecialPowerTemplate = SpecialAbilitySarumanFireball
TriggeredBy = Upgrade_Level1 ;Upgrade_Level4
End

Behavior = SpecialPowerModule ModuleTag_FireballStarter
SpecialPowerTemplate = SpecialAbilitySarumanFireball
UpdateModuleStartsAttack = Yes
StartsPaused = Yes
InitiateSound = ElvenWarriorVoiceAttackCharge
End

Behavior = WeaponFireSpecialAbilityUpdate ModuleTag_FireballUpdate
SpecialPowerTemplate = SpecialAbilitySarumanFireball
WhichSpecialWeapon = 1
SkipContinue = Yes

UnpackTime = 3466.67
PreparationTime = 800
PersistentPrepTime = 600
PackTime = 1800 ;1533.33

AwardXPForTriggering = 0

StartAbilityRange = SARUMAN_FIREBALL_RANGE
MustFinishAbility = Yes
SpecialWeapon = GilgaladVilya
End

;;; AIGLOS (Rank 6) ;;;
Behavior = UnpauseSpecialPowerUpgrade ModuleTag_AragornBladeMasterEnabler
SpecialPowerTemplate = SpecialAbilityAragornBladeMaster
TriggeredBy = Upgrade_Level1 ;Upgrade_Level6
End

Behavior = SpecialPowerModule ModuleTag_AragornBladeMasterStarter ; SpecialAbility is a SpecialPower, SpecialPower is anyting special
SpecialPowerTemplate = SpecialAbilityAragornBladeMaster
StartsPaused = Yes
End

Behavior = HeroModeSpecialAbilityUpdate ModuleTag_AragornBladeMasterUpdate ; So the difference in SpecialAbility is that it takes timing from this Update, instead of simply firing.
SpecialPowerTemplate = SpecialAbilityAragornBladeMaster
HeroAttributeModifier = GilgaladAiglos
HeroEffectDuration = 25000 ; 30000 ; this should sync with the auto ability delay re-fire time in commandButtons.ini
UnpackTime = 1 ; insant unpack
TriggerSound = AragornBladeMaster
End

;;; LEADERSHIP (Rank 3) ;;;
Behavior = AttributeModifierAuraUpdate ModuleTag_FaramirLeadership
StartsActive = No ;If no, requires upgrade to turn on.
BonusName = GilgaladPassiveLeadership
TriggeredBy = Upgrade_Level1 ;Upgrade_Level3
RefreshDelay = 2500
Range = 150 ; 200
ObjectFilter = ANY +INFANTRY +CAVALRY -STRUCTURE -BASE_FOUNDATION -HERO
End
Behavior = UnpauseSpecialPowerUpgrade ModuleTag_TheodenLeadership
SpecialPowerTemplate = SpecialAbilityFakeLeadership
TriggeredBy = Upgrade_Level1 ;Upgrade_Level3
End
Behavior = SpecialPowerModule ModuleTag_TheodenLeadershipUpdate
SpecialPowerTemplate = SpecialAbilityFakeLeadership
UpdateModuleStartsAttack = No
StartsPaused = Yes
End

Geometry = CYLINDER
GeometryMajorRadius = 8.0
GeometryMinorRadius = 8.0
GeometryHeight = 19.2
GeometryIsSmall = Yes
Shadow = SHADOW_DECAL
ShadowSizeX = 19;
ShadowSizeY = 19;
ShadowTexture = ShadowI;
End
;------------------------------------------------------------------------------
Object GilGaladVilyaProjectile

; *** ART Parameters ***
Draw = W3DScriptedModelDraw ModuleTag_Draw
DefaultModelConditionState
Model = FIRELOCATOR
ParticleSysBone ROOTTRANSFORM GilGaladVilyaWind FollowBone:yes
ParticleSysBone ROOTTRANSFORM GilGaladVilyaTrail FollowBone:yes
End
End

; *** AUDIO Parameters ***

; ***DESIGN parameters ***
EditorSorting = SYSTEM
ArmorSet
Armor = NoArmor
End
VisionRange = 0.0

; *** ENGINEERING Parameters ***
KindOf = PROJECTILE
Body = ActiveBody ModuleTag_02
MaxHealth = 10.0
End

Behavior = DestroyDie ModuleTag_03
;nothing
End

Behavior = BezierProjectileBehavior ModuleTag_04

FirstHeight = 9 ; Height of Bezier control points above highest intervening terrain
SecondHeight = 9
FirstPercentIndent = 20% ; Percentage of shot distance control points are placed
SecondPercentIndent = 100%
FlightPathAdjustDistPerSecond = 50 ; Can allow a max speed this can attempt to follow a target. Units are their velocity we can tag. (45 is default human speed)
DetonateCallsKill = Yes
CurveFlattenMinDist = 50.0
End

Behavior = PhysicsBehavior ModuleTag_05
KillWhenRestingOnGround = Yes
GravityMult = 0.0
End

Behavior = FXListDie ModuleTag_07
DeathTypes = ALL
DeathFX = FX_GilGaladVilyaExplode
End

Geometry = Sphere
GeometryIsSmall = Yes
GeometryMajorRadius = 0.8
End[/codebox]

[codebox]
;******************************************************************************
;weapon.ini*********************************************************************
;******************************************************************************
;------------------------------------------------------------------------------
Weapon GilgaladVilya ;BALANCE Saruman
LeechRangeWeapon = Yes
AttackRange = 280 ; SARUMAN_FIREBALL_RANGE ; set this in his special power
WeaponSpeed = 220 ; 150 ; dist/sec
MinWeaponSpeed = 150 ; 100
MaxWeaponSpeed = 250 ; 200 ; dist/sec Upper limit on scaling, when attacking past nominal "max" range
ScaleWeaponSpeed = Yes ; Used for lob weapons, scales speed proportional to range
HitPercentage = 100 ;When this weapon is used it will hit exactly 100% of the time.
ScatterRadius = 0.0 ;When this weapon misses it can randomly miss by as much as this distance.
DelayBetweenShots = 5000 ; time between shots, msec
PreAttackDelay = 1 ; 1467 is the prep time for archer.
PreAttackRandomAmount = 0 ; amount of additional preattack variance for archer type attacks only
PreAttackType = PER_SHOT ; Do the delay each time we attack a new target
FiringDuration = 1 ; Duration of the archer firing shot is 500ms.
IsAimingWeapon = Yes
AcceptableAimDelta = 15
AntiAirborneVehicle = Yes
AntiAirborneMonster = Yes
FireFX = FX_SarumanFireball
DamageType = FLAME

ProjectileNugget ; Default arrow
ProjectileTemplateName = GilGaladVilyaProjectile
WarheadTemplateName = GilgaladVilyaWarhead
End
End

;----------------------------
Weapon GilgaladVilyaWarhead
ProjectileCollidesWith = ENEMIES NEUTRAL STRUCTURES WALLS
RadiusDamageAffects = ENEMIES NEUTRALS NOT_SIMILAR MINES ; ALLIES

DamageNugget ; A basic Nugget that just does damage
Damage = SARUMAN_FIREBALL_DAMAGE
Radius = SARUMAN_FIREBALL_RADIUS
DelayTime = 0
DamageType = MAGIC
DamageFXType = BIG_ROCK
DeathType = CRUSHED
DamageScalar = 150% NONE +MordorFellBeast +MordorWitchKingOnFellBeast +GondorGwaihir
End

DamageNugget ; to make the fireball more mighty against enemy heroes
Damage = 50
Radius = SARUMAN_FIREBALL_RADIUS
DelayTime = 0
DamageType = MAGIC
DamageFXType = BIG_ROCK
DeathType = CRUSHED
DamageScalar = 500% NONE +HERO -MordorFellBeast -MordorWitchKingOnFellBeast -GondorGwaihir
End

DamageNugget ; A basic Nugget that just does damage
Damage = SARUMAN_FIREBALL_DAMAGE_SIEGE
Radius = SARUMAN_FIREBALL_RADIUS
DelayTime = 0
DamageType = MAGIC
DamageFXType = BIG_ROCK
DeathType = CRUSHED
DamageScalar = 300% NONE +MordorFellBeast +MordorWitchKingOnFellBeast +GondorGwaihir
End

MetaImpactNugget ; A Nugget that throws things back with force
HeroResist = 0.75
ShockWaveAmount = 80.00
ShockWaveRadius = SARUMAN_FIREBALL_RADIUS
ShockWaveTaperOff = 0.75
ShockWaveZMult = 1.20
End
End[/codebox]

[codebox]
;******************************************************************************
;commandbutton.ini**************************************************************
;******************************************************************************
CommandButton Command_GilgaladVilya
Command = SPECIAL_POWER
SpecialPower = SpecialAbilitySarumanFireball
Options = NEED_TARGET_ENEMY_OBJECT NEED_TARGET_NEUTRAL_OBJECT
TextLabel = CONTROLBAR:GilgaladVilya
ButtonImage = SIGilGaladVilya
CursorName = Bombard
InvalidCursorName = GenericInvalid
ButtonBorderType = ACTION
DescriptLabel = CONTROLBAR:ToolTipGilgaladVilya
InPalantir = Yes
AutoAbility = Yes
PresetRange = 200.0
End[/codebox]

Edited by Ringwraith Captain, 23 November 2008 - 08:13 PM.


#2 dethwaker3

dethwaker3

    Not Smart

  • Members
  • 559 posts
  • Location:At Home :D
  • Projects:New Heros and Units Mod
  •  Unwanted

Posted 23 November 2008 - 06:52 PM

Can u post it sepearate?
Done with my mod: Go here to download: http://bfme2.heaveng....php?fileid=667
or go here http://forums.revora...showtopic=67026 for some screenshot


Posted Image<---- Click here for download!


Posted Image
Click here to level up my card!

#3 Ringwraith Captain

Ringwraith Captain
  • Members
  • 46 posts

Posted 23 November 2008 - 08:14 PM

Sure. Edited first post.

#4 Radspakr Wolfbane

Radspakr Wolfbane

    The John Farnham of modding

  • Members
  • 7,722 posts
  • Location:less than 5 meters from my bed
  • Projects:Comeback tour
  •  The Retired Beard

Posted 24 November 2008 - 01:29 AM

Have you made the projectile?

Break dancing into the hearts of millions


#5 Ringwraith Captain

Ringwraith Captain
  • Members
  • 46 posts

Posted 24 November 2008 - 03:04 PM

Yeah, the projectile is at the bottom of gilgalad.ini (Object GilGaladVilyaProjectile)

#6 Radspakr Wolfbane

Radspakr Wolfbane

    The John Farnham of modding

  • Members
  • 7,722 posts
  • Location:less than 5 meters from my bed
  • Projects:Comeback tour
  •  The Retired Beard

Posted 25 November 2008 - 02:37 AM

I suggest you simpilfy the weapon remove the second and third damage nugget.
If you want different damages against Heroes or something use damagescalar.

Break dancing into the hearts of millions


#7 Ringwraith Captain

Ringwraith Captain
  • Members
  • 46 posts

Posted 25 November 2008 - 01:24 PM

I'll try that next time I have a chance (College is calling right now).
By the way, I copied that directly from Saruman's fireball, so that shouldn't be a problem, should it?

#8 Radspakr Wolfbane

Radspakr Wolfbane

    The John Farnham of modding

  • Members
  • 7,722 posts
  • Location:less than 5 meters from my bed
  • Projects:Comeback tour
  •  The Retired Beard

Posted 26 November 2008 - 01:21 AM

don't think so.
But did Sarumans Fireball have all the different nuggets?

Break dancing into the hearts of millions


#9 Ringwraith Captain

Ringwraith Captain
  • Members
  • 46 posts

Posted 26 November 2008 - 07:31 PM

Yep, it's got all the nuggets. Like you said, it could all be done with damage scalars in one nugget. But, that's EA for ya.




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users