Jump to content

An interesting effect/Spell probably wont need any help


Sirxon

Recommended Posts

Well i played Dota 2 for some time and i noticed a cool spell which bloodseeker uses called Rupture, basically the spell deals around 250 or something initial damage, and also damages the enemy the way he traveled (by certain amount of HP), anyway is this can be done here? Also ive noticed the Condition in the perk/spell system "IsFleeing" would that help also?

Link to comment
Share on other sites

Float Property UpdateRate Auto
Float Property DamagePerDistanceFraction Auto
Activator Property FXEmptyActivator Auto
Message Property TotalDamageMessage Auto
String Property SchoolPotencyActorValue Auto
String Property ResistanceActorValue Auto
 
ObjectReference TehBox
Float TotalDamage
 
Event OnEffectStart(Actor akTarget, Actor akCaster)
  TehBox = akTarget.PlaceAtMe(FXEmptyActivator)
  TotalDamage = 0
  RegisterForSingleUpdate(UpdateRate)
EndEvent
 
Event OnUpdate()
  Float DamageValue = GetTargetActor().GetDistance(TehBox)*DamagePerDistanceFraction
  DamageValue *= ((100+GetCasterActor().GetActorValue(SchoolPotencyActorValue))/100)
  DamageValue *= ((100-GetTargetActor().GetActorValue(ResistanceActorValue))/100)
  If DamageValue > 0
    TotalDamage += DamageValue
    GetTargetActor().DamageActorValue("Health",DamageValue)
  EndIf
  TehBox.MoveTo(GetTargetActor())
  RegisterForSingleUpdate(UpdateRate)
EndEvent
 
Event OnEffectFinish(Actor akTarget, Actor akCaster)
  TehBox.Delete()
  TotalDamageMessage.Show(TotalDamage)
EndEvent

 

FXEmptyActivator = let it auto fill

SchoolPotencyActorValue = DestructionPowerMod

ResistanceActorValue = DamageResist for physical damage, MagicResist for magic, etc.

UpdateRate = 0.1

DamagePerDistanceFraction = try 0.1 and modify up or down as needed

TotalDamageMessage = a message that says Total damage dealt: %.0

Edited by EnaiSiaion
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...