Ok,as you some of you know I am still new to Jass and stuff so I'm trying to make a spell that if you are attacked theres a chance that the enemy who is attacking you will be stunned,almost like Tiny's passive.
So far I've got this.
I already have filters and that stuff all I need is the action and how to preload the ability.Also I'm not sure if this is totally correct.
Just want to be sure.
Ok so I have the group sort of if it was an active spell so I also need help there and then I have this.
Ok so this damages the unit as you've realized,but I only want it to be stunned for like 0.5 or 1 second.
Please don't rate my skill in vJass I know I still suck:/
Was I supposed to post this in the World Editor Help Zone?
Credits---
The Hiveworkshop for all their helpful tutorials on vJass and Jass.
So far I've got this.
JASS:
private function Actions takes nothing returns nothing
local location SpellLoc = GetSpellTargetLoc()
local real spellX = GetLocationX(SpellLoc)
local real spellY = GetLocationY(SpellLoc)
local unit caster = GetTriggerUnit()
local integer level = GetUnitAbilityLevel(caster, SPELL_ID)
local unit f
local integer creeps = 0
call GroupEnumUnitsInRange(all,spellX,spellY,Range(level),b)
set SPassive = StunPassive(all)
loop
set f = FirstOfGroup(copy)
exitwhen(f == null)
call GroupRemoveUnit(copy,f)
if IsUnitAlly(f,GetOwningPlayer(caster)) then
set creeps = creeps+1
else
call DoNothing
endif
endloop
JASS:
call DoNothing
Ok so I have the group sort of if it was an active spell so I also need help there and then I have this.
JASS:
loop
set f = FirstOfGroup(all)
exitwhen (f == null)
call GroupRemoveUnit(all, f)
if IsUnitEnemy(f, GetOwningPlayer(caster)) then
call UnitDamageTarget(caster, f, Damage(level), true, false, A_TYPE, D_TYPE, null)
endif
endloop
Please don't rate my skill in vJass I know I still suck:/
Was I supposed to post this in the World Editor Help Zone?
Credits---
The Hiveworkshop for all their helpful tutorials on vJass and Jass.
Last edited: