Advertisement
Guest User

Untitled

a guest
Aug 30th, 2015
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.08 KB | None | 0 0
  1. function CleanserMortar ( event )
  2.     local caster = event.caster
  3.     local target = event.target
  4.     local ability = event.ability
  5.     local casterPosition = caster:GetAbsOrigin()  
  6.     local targetPosition = target:GetAbsOrigin()
  7.     local distance = casterPosition - targetPosition
  8.     local length = distance:Length()
  9.     print(length)
  10.  
  11.  
  12.     local info =
  13.     {
  14.         Ability = ability,
  15.         EffectName = "particles/skull_spear.vpcf",
  16.         vSpawnOrigin = casterPosition,
  17.         fDistance = length,
  18.         fStartRadius = 0,
  19.         fEndRadius = 0,
  20.         Source = caster,
  21.         bHasFrontalCone = false,
  22.         bReplaceExisting = false,
  23.         iUnitTargetTeam = DOTA_UNIT_TARGET_TEAM_ENEMY,
  24.         iUnitTargetFlags = DOTA_UNIT_TARGET_FLAG_NONE,
  25.         iUnitTargetType = DOTA_UNIT_TARGET_HERO + DOTA_UNIT_TARGET_BASIC,
  26.         fExpireTime = GameRules:GetGameTime() + 10.0,
  27.         bDeleteOnHit = false,
  28.         vVelocity = caster:GetForwardVector() * 900,
  29.         bProvidesVision = true,
  30.         iVisionRadius = 1000,
  31.         iVisionTeamNumber = caster:GetTeamNumber()
  32.     }
  33.  
  34.     ProjectileManager:CreateLinearProjectile(info)
  35. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement