Spellpack Undying

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
DotA Spell Pack

- Jass Coded
- MUI
- Leakless
- Lagless
- Requires NewGen WorldEditor

Raise Dead
**Note**
Only this spell is MPI and not MUI. Since IceFrog made it MPI too.
Code:
Calls the Undying's fellow zombies out of the earth to fight. Once a zombie attacks six times, another one will rise alongside it. When a zombie dies, its reanimating life force returns to Dirge, healing him by 50 hp. Lasts 30 seconds.

Level 1 - 1 Zombie
Level 2 - 2 Zombies
Level 3 - 3 Zombies
Level 4 - 4 Zombies

Cooldown: 30
Manacost: 100/120/140/160

Level 1: 100 mana, 30 sec cooldown.
Level 2: 120 mana, 30 sec cooldown.
Level 3: 140 mana, 30 sec cooldown.
Level 4: 160 mana, 30 sec cooldown.

JASS:
scope RaiseDead

//===================================================================================
//                                    Raise Dead                                 
//                                by kentchow75/~GaLs
//===================================================================================
//
// Implemention Instruction
// 
//--------------------------------------------------------------------------------
// -Object Needed to be copied from Object Editor to your map.
//  [ Ability ]
//  1. Raise Dead [D]
//
//  [ Buff ]
//  1. Zombie
//
//  [ Unit ]
//  1. Dummy Healer [Raise Dead]
//--------------------------------------------------------------------------------
// -Trigger  
//  1. Copy this whole trigger to your map.
//  2. Copy the ABC trigger to your map if you don't have 1 in your map. (ABC v5.1 or above required)
//  3. CSSafety
//--------------------------------------------------------------------------------
// -Requirements
//  1. Jass NewGen WorldEditor from <a href="http://www.wc3campaigns.net" target="_blank" class="link link--external" rel="nofollow ugc noopener">www.wc3campaigns.net</a>. ( v4b and above )
//--------------------------------------------------------------------------------
// -Credits
//  1. Thanks to Cohadar for his brilliant ABC system.
//--------------------------------------------------------------------------------
//===================================================================================
//  Implementation End                                 
//===================================================================================

globals

//*******************************************************************************************
//  Configuration  (This is where you need to edit to make the spell works in your map)
//*******************************************************************************************
//
//=================================================================
//  &lt;- RawCode -&gt;
// Change the rawcode. (Press CTRL+D to view the rawcode in object editor)
    private constant integer RD_RAW = &#039;Test&#039;
//  The rawcode of the ability.    

    private constant integer RD_ZOM = &#039;h001&#039;
//  The rawcode of the zombie unit.

    private constant integer RD_HEALER = &#039;h003&#039;
//  The rawcode of the healer unit.

//  &lt;- Speed -&gt;
    private constant real RD_SPEED = .05
//  How fast will the skull moves.

//=================================================================

//*******************************************************************************************
//  Configuration End
//*******************************************************************************************

// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
    
endglobals

globals
    private unit array Dirge
    private trigger Zdie = CreateTrigger()
    private trigger move = CreateTrigger()
    private trigger Dese = CreateTrigger()
endglobals

private struct RaiseDead
unit healer
timer t
unit Hero

    static method create takes unit u returns RaiseDead
    local RaiseDead heal= RaiseDead.allocate()
        set heal.healer = u
        set heal.Hero = Dirge[GetPlayerId(GetOwningPlayer(heal.healer))]
        set heal.t = NewTimer()
    return heal
    endmethod
    
    method offsetX takes real source, real dist, real angle returns real
        return source + dist * Cos(angle * bj_DEGTORAD)
    endmethod
    
    method offsetY takes real source, real dist, real angle returns real
        return source + dist * Sin(angle * bj_DEGTORAD)
    endmethod
    
    method AngBtwPoi takes real x1, real y1, real x2, real y2 returns real
        return bj_RADTODEG * Atan2(y2 - y1, x2 - x1)
    endmethod
    
    static method timerEnd takes nothing returns nothing
    local timer t = GetExpiredTimer()
    local RaiseDead H = GetTimerStructA(t)
    local real x1 = GetUnitX(H.healer)
    local real y1 = GetUnitY(H.healer)
    local real x2 = GetUnitX(H.Hero)
    local real y2 = GetUnitY(H.Hero)
    local real ang = H.AngBtwPoi(x1,y1,x2,y2)
    local real newx = H.offsetX(x1,15,ang)
    local real newy = H.offsetY(y1,15,ang)
    
    call SetUnitX(H.healer, newx)
    call SetUnitY(H.healer, newy)
    call SetUnitFacing(H.healer,ang)
    
    set t = null
    endmethod
    
    method onDestroy takes nothing returns nothing
        call ReleaseTimer(.t)
    endmethod
endstruct

private function RDCond takes nothing returns boolean
    return GetSpellAbilityId() == RD_RAW
endfunction

function Trig_Raise_Dead_Actions takes nothing returns nothing
    set Dirge[GetPlayerId(GetOwningPlayer(GetTriggerUnit()))] = GetTriggerUnit()
endfunction


private function EndMoveCond takes nothing returns boolean
    return GetTriggerUnit() == Dirge[GetPlayerId(GetOwningPlayer(GetTriggerUnit()))]
endfunction

private function EndMoveAct takes nothing returns nothing
local RaiseDead heal = GetTriggerStructA(GetTriggeringTrigger())

    call UnitApplyTimedLife(heal.healer,&#039;BTLF&#039;,.1)
    call SetUnitState(heal.Hero,UNIT_STATE_LIFE,GetUnitState(heal.Hero,UNIT_STATE_LIFE)+50)
    call ClearTriggerStructA(GetTriggeringTrigger())
    call ClearTimerStructA(heal.t)
    call heal.destroy()
    
call DestroyTrigger(GetTriggeringTrigger())
endfunction

private function ZdieCond takes nothing returns boolean
    return GetUnitTypeId(GetTriggerUnit()) == RD_ZOM
endfunction

private function ZdieAct takes nothing returns nothing
local unit zom = GetTriggerUnit()
local unit hero = Dirge[GetPlayerId(GetOwningPlayer(zom))]
local unit healer = CreateUnit(GetOwningPlayer(zom),RD_HEALER,GetUnitX(zom),GetUnitY(zom),270)
local trigger EndMove = CreateTrigger()
local RaiseDead heal = RaiseDead.create(healer)
    
    call SetTriggerStructA(EndMove,heal)
    call TriggerRegisterUnitInRange(EndMove, healer, 80, null)
    call TriggerAddCondition(EndMove, Condition(function EndMoveCond))
    call TriggerAddAction(EndMove, function EndMoveAct)
    
    call SetTimerStructA(heal.t,heal)
    call TimerStart(heal.t,RD_SPEED,true,function RaiseDead.timerEnd)
    
set zom = null
set hero = null
set healer = null
set EndMove = null
endfunction


//===========================================================================
function InitTrig_Raise_Dead takes nothing returns nothing
local trigger t = CreateTrigger(  )
    call TriggerAddAction( t, function Trig_Raise_Dead_Actions )
    call TriggerAddCondition(t,Condition(function RDCond ))
    call TriggerRegisterAnyUnitEventBJ(t,EVENT_PLAYER_UNIT_SPELL_EFFECT)
set t = null
    
    call TriggerAddAction(Zdie, function ZdieAct)
    call TriggerAddCondition(Zdie,Condition(function ZdieCond))
    call TriggerRegisterAnyUnitEventBJ(Zdie,EVENT_PLAYER_UNIT_DEATH)
endfunction

endscope


rdzb7.jpg


Soul Rip
Code:
Redirects the flow of living energy through a target friend or foe, damaging them or healing them depending on how many units are near it. 25 for each unit.

Level 1 - 5 max
Level 2 - 10 max
Level 3 - 15 max
Level 4 - 20 max

JASS:

scope SoulRip

//===================================================================================
//                                      Soul Rip                                 
//                                by kentchow75/~GaLs
//===================================================================================
//
// Implemention Instruction
// 
//--------------------------------------------------------------------------------
// -Object Needed to be copied from Object Editor to your map.
//  [ Ability ]
//  1. Soul Rip [R]
//  
//--------------------------------------------------------------------------------
// -Trigger  
//  1. Copy this whole trigger to your map.
//  2. Copy the ABC trigger to your map if you don&#039;t have 1 in your map. (ABC v5.1 or above required)
//  3. CSSafety
//--------------------------------------------------------------------------------
// -Requirements
//  1. Jass NewGen WorldEditor from <a href="http://www.wc3campaigns.net" target="_blank" class="link link--external" rel="nofollow ugc noopener">www.wc3campaigns.net</a>. ( v4b and above )
//--------------------------------------------------------------------------------
// -Credits
//  1. Thanks to Cohadar for his brilliant ABC system.
//--------------------------------------------------------------------------------
//===================================================================================
//  Implementation End                                 
//===================================================================================

globals

//*******************************************************************************************
//  Configuration  (This is where you need to edit to make the spell works in your map)
//*******************************************************************************************
//
//  &lt;-------------------- Rawcode --------------------&gt;
//
    private constant integer    SR_Id                       = &#039;A003&#039; 
//  The raw of the ability, Soul Rip
//
//  &lt;------------------ Rawcode End ------------------&gt;
//
//  &lt;-------------------- Config ---------------------&gt;
//
    private constant real       SR_Rad                      = 1000.
//  The radius of the spell effect.
//
    private constant string     SR_LightningName            = &quot;MFPB&quot;
//  The name of the lightning will be created when casting.
//
    private constant real       SR_LightningRemovalDelay    = .75
//  Delay before the lightning get removed.
//
endglobals

private constant function SR_DamagePerUnit takes integer level returns integer
    return level * 5 //Damage Per Unit. (level x 5)
endfunction
//  &lt;------------------ Config End -------------------&gt;

//*******************************************************************************************
//  Configuration End
//*******************************************************************************************

// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//

globals
    private unit target
    private unit caster
endglobals


private constant function SR_Max takes integer Level returns integer
    return Level * 5
endfunction

struct Soul_Rip

lightning li

    static method create takes lightning light returns Soul_Rip
    local Soul_Rip SR = Soul_Rip.allocate()
        set SR.li = light
    return SR
    endmethod

    method onDestroy takes nothing returns nothing
        call DestroyLightning(.li)
    endmethod
endstruct

private function tAct takes nothing returns nothing
local timer t = GetExpiredTimer()
local Soul_Rip SR = ClearTimerStructA(t)

    call SR.destroy()
    
call ReleaseTimer(t)
set t = null
endfunction

private function GAct takes nothing returns nothing
local unit enum = GetEnumUnit()
local timer t = NewTimer()
local lightning l = AddLightning(SR_LightningName,true,GetUnitX(enum),GetUnitY(enum),GetUnitX(target),GetUnitY(target))
local Soul_Rip SR = Soul_Rip.create(l)
local integer Lvl = GetUnitAbilityLevel(caster,SR_Id)

    call SetTimerStructA(t,SR)

    if not IsUnitAlly(target, GetOwningPlayer(caster))then
        call UnitDamageTarget(caster , target, SR_DamagePerUnit(Lvl),true,false,ATTACK_TYPE_MAGIC,DAMAGE_TYPE_NORMAL,null)
    elseif IsUnitAlly(target,GetOwningPlayer(caster)) then
        call SetUnitState(target,UNIT_STATE_LIFE,GetUnitState(target,UNIT_STATE_LIFE)+SR_DamagePerUnit(Lvl))
    endif
    
    call TimerStart(t,SR_LightningRemovalDelay,false,function tAct)
    
set enum = null
set l = null
set t = null
endfunction

private function GCond takes nothing returns boolean
    return not IsUnitType(GetFilterUnit(),UNIT_TYPE_STRUCTURE) and GetUnitState(GetFilterUnit(),UNIT_STATE_LIFE)&gt;0
endfunction

private function SoulRipCond takes nothing returns boolean
    return GetSpellAbilityId() == SR_Id
endfunction

globals
    private group G = CreateGroup()
    private group GTwo
endglobals

private function SoulRipAct takes nothing returns nothing
local real tx = GetUnitX(GetSpellTargetUnit())
local real ty = GetUnitY(GetSpellTargetUnit())
local integer level = GetUnitAbilityLevel(GetSpellAbilityUnit(),SR_Id)

set target = GetSpellTargetUnit()
set caster = GetSpellAbilityUnit()

    call GroupEnumUnitsInRange(G,tx,ty,SR_Rad,Condition(function GCond))
    call GroupRemoveUnit(G,GetSpellAbilityUnit())
    
    if CountUnitsInGroup(G) &gt; SR_Max(level) then        // If the units in the group is larger than the number of pickable unit.
        set GTwo = GetRandomSubGroup(SR_Max(level),G)   // We form another group that is equal to the number of piackable unit.
        call ForGroup(GTwo,function GAct)
        call DestroyGroup(GTwo)
    else
        call ForGroup(G,function GAct)
    endif
    
endfunction

//===========================================================================
function InitTrig_Soul_Rip takes nothing returns nothing
local trigger t = CreateTrigger(  )
    call TriggerRegisterAnyUnitEventBJ(t,EVENT_PLAYER_UNIT_SPELL_EFFECT)
    call TriggerAddCondition(t,Condition(function SoulRipCond))
    call TriggerAddAction( t, function SoulRipAct )
set t = null
endfunction

endscope

kiaejsjkid.jpg


Heartstopper Aura
Code:
The Dirge's deathly air stills the hearts of his opponents, causing them to lose 1% of their max health over time.

Level 1 - 250 AoE
Level 2 - 500 AoE
Level 3 - 750 AoE
Level 4 - 1000 AoE
JASS:
scope HeartstopperAura

//===================================================================================
//                                 Heaststopper Aura                                 
//                                by kentchow75/~GaLs
//===================================================================================
//
// Implemention Instruction
// 
//--------------------------------------------------------------------------------
// -Object Needed to be copied from Object Editor to your map.
//  [ Ability ]
//  1. HeartStopper Aura [H]
//  
//  [ Buff ]
//  1. Heartstopper Aura
//--------------------------------------------------------------------------------
// -Trigger  
//  Copy this whole trigger to your map.
//--------------------------------------------------------------------------------
// -Requirements
//  1. Jass NewGen WorldEditor from <a href="http://www.wc3campaigns.net" target="_blank" class="link link--external" rel="nofollow ugc noopener">www.wc3campaigns.net</a>. ( v4b and above )
//--------------------------------------------------------------------------------
//===================================================================================
//  Implementation End                                 
//===================================================================================

globals

//*******************************************************************************************
//  Configuration  (This is where you need to edit to make the spell works in your map)
//*******************************************************************************************
//
//=================================================================
// &lt;- RawCode -&gt;
// Change the rawcode. (Press CTRL+D to view the rawcode in object editor)

    private constant integer HA_ID = &#039;A000&#039; 
    //This the rawcode of the main spell. (HeartStopper Aura [H])

    private constant integer HA_BuffID = &#039;B002&#039; 
    //The rawcode of the buff.

//=================================================================
endglobals
//=================================================================
// &lt;- Distance -&gt;
private constant function HA_Radius takes integer level returns integer
    return level*250 //This is how far will the buff reach. 
endfunction
//=================================================================
//*******************************************************************************************
//  Configuration End
//*******************************************************************************************


// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
globals
    unit caster
endglobals

private function EneAct takes nothing returns nothing
local real amou = GetUnitState(GetEnumUnit(),UNIT_STATE_MAX_LIFE)/100 // 1% of the unit&#039;s maximun life.
    call UnitDamageTarget(caster,GetEnumUnit(),amou,true,false,ATTACK_TYPE_CHAOS,DAMAGE_TYPE_NORMAL,null)
endfunction

private function EneCond takes nothing returns boolean
    return GetUnitAbilityLevel(GetFilterUnit(),HA_BuffID)&gt;0 and GetFilterUnit()!=caster and GetUnitState(GetFilterUnit(),UNIT_STATE_LIFE) &gt;0
endfunction

globals
    private group G = CreateGroup()
    private group Ene = CreateGroup()
endglobals

private function GAct takes nothing returns nothing
local real x = GetUnitX(GetEnumUnit())
local real y = GetUnitY(GetEnumUnit())
local real rad = I2R(HA_Radius(GetUnitAbilityLevel(GetEnumUnit(),HA_ID)))
    set caster = GetEnumUnit()
    call GroupEnumUnitsInRange(Ene,x,y,rad,Condition(function EneCond))
    call ForGroup(Ene,function EneAct)
endfunction

private function GCond takes nothing returns boolean
    return GetUnitAbilityLevel(GetFilterUnit(),HA_ID)&gt;0
endfunction


private function Trig_Heartstopper_Aura_Actions takes nothing returns nothing
    call GroupEnumUnitsInRect(G,bj_mapInitialPlayableArea,Condition(function GCond))
    call ForGroup(G,function GAct)
endfunction

//===========================================================================
function InitTrig_Heartstopper_Aura takes nothing returns nothing
    local trigger t = CreateTrigger(  )
    call TriggerAddAction( t, function Trig_Heartstopper_Aura_Actions )
    call TriggerRegisterTimerEvent(t,1,true)
set t = null
endfunction

endscope

wlycbszyqy.thumb500.jpg


Plague
Code:
Infects the target with a plague. Reduces movement speed by 25% and amplifies incoming damage. Infects other units that come within range of a plagued unit.

Level 1 - 20% Extra Damage
Level 2 - 25% Extra Damage
Level 3 - 30% Extra Damage.
JASS:
scope Plague

//===================================================================================
//                                      Plague                                 
//                                by kentchow75/~GaLs
//===================================================================================
//
// Implemention Instruction
// 
//--------------------------------------------------------------------------------
// -Object Needed to be copied from Object Editor to your map.
//  [ Ability ]
//  1. Plague [E]
//  2. Plague [E] Dummy
//
//  [ Buff ]
//  1. Plague
//
//  [ Unit ]
//  1. Dummy Plaguer
//--------------------------------------------------------------------------------
// -Trigger  
//  1. Copy this whole trigger to your map.
//  2. Copy the ABC trigger to your map if you don&#039;t have 1 in your map. (ABC v5.1 or above required)
//  3. CSSafety
//--------------------------------------------------------------------------------
// -Requirements
//  1. Jass NewGen WorldEditor from <a href="http://www.wc3campaigns.net" target="_blank" class="link link--external" rel="nofollow ugc noopener">www.wc3campaigns.net</a>. ( v4b and above )
//--------------------------------------------------------------------------------
// -Credits
//  1. Thanks to Cohadar for his brilliant ABC system.
//--------------------------------------------------------------------------------
//===================================================================================
//  Implementation End                                 
//===================================================================================

globals

//*******************************************************************************************
//  Configuration  (This is where you need to edit to make the spell works in your map)
//*******************************************************************************************
//
//=================================================================
//  &lt;- RawCode -&gt;
// Change the rawcode. (Press CTRL+D to view the rawcode in object editor)
//
    private constant integer P_Id = &#039;A004&#039;   
    //Rawcode of the main ability.

    private constant integer P_DummyId = &#039;A001&#039;   
    //Rawcode of the dummy ability.

    private constant integer P_DummyPlaguer = &#039;h005&#039;   
    //Rawcode of the dummy plaguer.

    private constant integer PBuff_Id = &#039;B001&#039;   
    //Rawcode of the buff.
//=================================================================

//=================================================================
//  &lt;- Order String -&gt;
    private constant string P_DummyOrderString = &quot;cripple&quot; 
    //Order string of the dummy ability

//=================================================================
endglobals

//=================================================================
//  &lt;- Duration -&gt;
private constant function Duration takes integer level returns integer
    return level * 5
    //How long does the effect last. (level * 5)
endfunction

//=================================================================

//=================================================================
//  &lt;- Infect Range -&gt;
private constant function P_InfectRange takes integer level returns integer
    return level * 50
    //Infect other unit in range of. (level * 50)
endfunction
    
//=================================================================

//=================================================================
//  &lt;- Amplify Formula -&gt;
private constant function Amplified takes integer Level returns integer
    return (Level *5)+15    
    //The formula to calculate how much damage to amplify.
    // lvl 1 for 20% / lvl 2 for 25% / lvl 3 for 30%
endfunction
//=================================================================

//*******************************************************************************************
//  Configuration End
//*******************************************************************************************

// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//
// -----------------------&gt; Do not edit anything below this line. &lt;-----------------------//


globals
    private unit Target
    private group Registered = CreateGroup()
endglobals

//============================= 
//==     Amplify Trigger     ==
//============================= 
private function AmpCond takes nothing returns boolean
    return GetUnitAbilityLevel(GetTriggerUnit(),PBuff_Id) &gt; 0 and GetUnitState(GetTriggerUnit(),UNIT_STATE_LIFE)&gt;0
endfunction

private function AmpAct takes nothing returns nothing
local unit dmger = GetEventDamageSource()
local integer buffLvl = GetUnitAbilityLevel(GetTriggerUnit(),PBuff_Id)
local real dmgInc = (GetEventDamage()/100.)*(100+Amplified(buffLvl)) // 1% x Multiplied

    call DisableTrigger(GetTriggeringTrigger())
    call UnitDamageTarget(dmger,GetTriggerUnit(),dmgInc,true,false,ATTACK_TYPE_MAGIC,DAMAGE_TYPE_NORMAL,WEAPON_TYPE_WHOKNOWS)
    call EnableTrigger(GetTriggeringTrigger())
    
set dmger = null
endfunction
//============================= 
//==           End           ==
//=============================

struct plague
unit caster
unit target
trigger Infect
trigger Amplify
group reg

    static method create takes unit cas, unit tar returns plague
    local plague pl = plague.allocate()
    set pl.caster = cas
    set pl.target = tar
    set pl.Infect = CreateTrigger()
    set pl.Amplify = CreateTrigger()
    set pl.reg = CreateGroup()
    call TriggerAddCondition(pl.Amplify,Condition(function AmpCond))
    call TriggerAddAction(pl.Amplify,function AmpAct)
    return pl
    endmethod
    
    method onDestroy takes nothing returns nothing
    call DestroyTrigger(.Infect)
    call DestroyTrigger(.Amplify)
    call DestroyGroup(.reg)
    endmethod
    
endstruct


private function tAct takes nothing returns nothing
local timer t = GetExpiredTimer()
local plague pl = GetTimerStructA(t)
    call ClearTriggerStructA(pl.Infect)
    call GroupRemoveGroup(Registered, pl.reg)
    call pl.destroy()
    call PauseTimer(t)
    call ClearTimerStructA(t)
    call ReleaseTimer(t)
set t = null
endfunction

//============================== 
//==      Infect Trigger      ==
//============================== 

//Surround
private function SurCond takes nothing returns boolean
    return IsUnitAlly(GetFilterUnit(),GetOwningPlayer(Target))==true and IsUnitType(GetFilterUnit(),UNIT_TYPE_STRUCTURE)==false and GetUnitState(GetFilterUnit(),UNIT_STATE_LIFE)&gt;0 and GetFilterUnit()!= Target
endfunction

private function SurAct takes nothing returns nothing
local plague pl = GetTriggerStructA(GetTriggeringTrigger())
local unit enu = GetEnumUnit()
local location tarloc = GetUnitLoc(pl.target)
local unit u = CreateUnit(GetOwningPlayer(pl.target),P_DummyPlaguer,GetUnitX(enu),GetUnitY(enu),270)

    call UnitAddAbility(u,P_DummyId)
    call UnitApplyTimedLife(u,&#039;BTLF&#039;,1)
    call SetUnitAbilityLevel(u,P_DummyId,GetUnitAbilityLevel(pl.caster,P_Id))
    call IssueTargetOrder(u,P_DummyOrderString,enu)
    
    if  IsUnitInGroup(enu,Registered) == false then
        call TriggerRegisterUnitEvent(pl.Amplify,enu,EVENT_UNIT_DAMAGED)
        call GroupAddUnit(Registered,enu)
        call GroupAddUnit(pl.reg,pl.target)
    endif

set enu = null
call RemoveLocation(tarloc)
set tarloc = null
set u = null
endfunction
//Endz

globals
    private group Surround = CreateGroup()
endglobals

//InfAct
private function InfAct takes nothing returns nothing
local plague pl = GetTriggerStructA(GetTriggeringTrigger())
local location tloc = GetUnitLoc(pl.target)
local integer Lvl = GetUnitAbilityLevel(pl.caster,P_Id)
    set Target = pl.target
    call GroupEnumUnitsInRangeOfLoc(Surround,tloc,P_InfectRange(Lvl),Condition(function SurCond))
    call ForGroup(Surround,function SurAct)
call RemoveLocation(tloc)
set tloc = null
endfunction
//Endz

//=============================
//==           End           ==
//=============================
    

private function PlagueCond takes nothing returns boolean
    return GetSpellAbilityId() == P_Id
endfunction

function PlagueAct takes nothing returns nothing
local timer t = NewTimer()
local plague pl = plague.create(GetSpellAbilityUnit(),GetSpellTargetUnit())
local integer Lvl = GetUnitAbilityLevel(pl.caster,P_Id)

    if IsUnitInGroup(pl.target,Registered)==false then
        call TriggerRegisterUnitEvent(pl.Amplify,pl.target,EVENT_UNIT_DAMAGED)
        call GroupAddUnit(Registered,pl.target)
        call GroupAddUnit(pl.reg,pl.target)
    endif
    
    call SetTriggerStructA(pl.Infect, pl)
    call TriggerRegisterTimerEvent(pl.Infect,.5,true)
    call TriggerAddAction(pl.Infect,function InfAct)
    
    call SetTimerStructA(t,pl)
    call TimerStart(t,Duration(Lvl),false,function tAct)
set t = null
endfunction

//===========================================================================
function InitTrig_Plague takes nothing returns nothing
local trigger t = CreateTrigger(  )
    call TriggerRegisterAnyUnitEventBJ(t,EVENT_PLAYER_UNIT_SPELL_EFFECT)
    call TriggerAddCondition(t,Condition(function PlagueCond))
    call TriggerAddAction( t, function PlagueAct )
set t = null
endfunction

endscope

acxebvzrmt.jpg


Download Here
View attachment Spell Pack [DotA].w3x

//==============================================================================
Off-topic
If you are intended to asking why making dota spell, please read this. I just feel like making it, no other purpose.

Edit1 - I am resizing the image now, dont worry.
Edit2 - Resized the image and replace the old image.
Edit3 - Added Raise Dead, Fixed issues on the previous spell.
Edit4 - Fixed a typo in the implementation instruction of Raise Dead
 

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
>>doesnt this leak?
Hmm, I was wondering about this too. Well, handle leak, but unit do?

>>Also couldnt Heartstopper Aura just be the healing wards aura with a negative value?
Hmm, well. Even if it is, you still need to trigger it right? In order to keep the ward at the same place as the hero. I just made some other version of it.. :p
 

cr4xzZz

Also known as azwraith_ftL.
Reaction score
51
> local real tx = GetUnitX(GetSpellTargetUnit())
local real ty = GetUnitY(GetSpellTargetUnit())

I think reals don't leak... Only locations, unit groups, etc. Nice spells +rep if I can :p
 
S

sinners_la_b

Guest
>>Also couldnt Heartstopper Aura just be the healing wards aura with a negative value?
Hmm, well. Even if it is, you still need to trigger it right? In order to keep the ward at the same place as the hero. I just made some other version of it.. :p

Well not to not pick because you and cool spells but if you search for Healing Ward in the abilites menu it will find both the ward and the aura. You just then modify the aura then give it to the hero.

sinners

EDIT

> local real tx = GetUnitX(GetSpellTargetUnit())
local real ty = GetUnitY(GetSpellTargetUnit())

I think reals don't leak... Only locations, unit groups, etc. Nice spells +rep if I can

Yes they dont lol i looked at it wrong. I am tired :(
 

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
>>Well not to not pick because you and cool spells but if you search for Healing Ward in the abilites menu it will find both the ward and the aura. You just then modify the aura then give it to the hero.
What you want me to do?
 

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
>>woah gals~ you learnt structs already>.< so fast
Nah, structs are easy to learn.
Just a piece of cake once you get work into vJass.
 

NetherHawk

New Member
Reaction score
26
=[ can i remain at handle vars..?. it isnt that bad right... i mean dota uses it huh... thats gd enuff for me =D

cant rep you for this, apparently need rep others first =[
 

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
>>=[ can i remain at handle vars..?. it isnt that bad right... i mean dota uses it huh... thats gd enuff for me =D

cant rep you for this, apparently need rep others first =[

No, handle vars aren't that good. It may causes fatal error due to the handle stacking bug.
And, Handle Vars uses gamecache. Gamecache slow.
 

cr4xzZz

Also known as azwraith_ftL.
Reaction score
51
What's the difference between constant function and private constant function? Sorry if this is considered as spam :/
 

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
>>What's the difference between constant function and private constant function? Sorry if this is considered as spam :/
Actually, there is no different.
"private" is a vJass syntax, which makes the function won't conflict with other function with the same name. Private need to be used in certain condition, such as inside library block or global block.
JASS:
scope Test
private function ABC takes nothing returns nothing
    call BJDebugMsg(&quot;ABC&quot;)
endfunction
endscope

function ABC takes nothing returns nothing
    call BJDebugMsg(&quot;ABC&quot;)
endfunction
//* This won&#039;t syntex the worldeditor.
 

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
In scope or in library block.
Read the vJass manual which is included when you download NewGen WE for more details.
 

Somatic

You can change this now in User CP.
Reaction score
84
Nice Spells! Arent rise Dead just normal Lava Spawns? Then detect when they die they cast a fan of knive targeting player hero? thats what i felt

@Sinners la b - That does not claim the hero the kill. As they die due to their own "degeneration" while ~gals~ method claim the kill for the hero.

~Off topic~
Ill need more pratice for Vjass... I cant even cope with understanding much of the Handlers Vars! Pathetic me for not able to pick up even with basic understanding of C++.

Question : Is Vjass easier than Handlers Vars?
 

The_Kingpin

Member (Who are you and why should I care?)
Reaction score
41
Lol, Plague is kinda the same thing as the Contagious Disease I just made... <_<
 

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
>>That does not claim the hero the kill. As they die due to their own "degeneration" while ~gals~ method claim the kill for the hero.
Well, yes. Enemy can die from Heartstopper Aura. If you are lucky enough to get the last hit by the spell.

>>Ill need more pratice for Vjass... I cant even cope with understanding much of the Handlers Vars! Pathetic me for not able to pick up even with basic understanding of C++
I don't know C++ or even HTML either. I just know vJass, only.

>>Is Vjass easier than Handlers Vars?
You can't compare these 2 things. Due to my oppinion, Handle Vars are easier to learn, but it is slow.

Edit - LoL i forgoten to reply someone.

>>Lol, Plague is kinda the same thing as the Contagious Disease I just made... <_<
I don't know.

>>i think someone mentioned this at the dota forums too. hahaha
What are you refering 'this' to ?
 
L

LeDah

Guest
Very nice spells gals as always

P.S nether and you are saying???? that gals copied or smth your idea.explain better plx :)
 

~GaLs~

† Ғσſ ŧħə ѕαĸε Φƒ ~Ğ䣚~ †
Reaction score
180
>>Very nice spells gals as always
Thanks, as always.

>>P.S nether and you are saying???? that gals copied or smth your idea.explain better plx
I think so? No idea.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top