Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

[JASS] Is there a Problem here?

Discussion in 'Triggers & Scripts' started by naitsirk, Feb 12, 2010.

  1. naitsirk

    naitsirk

    Joined:
    Jan 24, 2009
    Messages:
    570
    Resources:
    0
    Resources:
    0
    Here is the Code, I tried to make my vJASS Spell to use Timers, so I made a Loop_Action trigger.
    here's the Code:
    Code
    Code (vJASS):
    private function Loop_Action takes group whatGroup, unit caster, unit target, string Effect1, string Effect2, real x, real y, returns nothing
        call GroupEnumUnitsInRange( whatGroup, x, y, 125., null)
        call DestroyEffect(AddSpecialEffect( Effect1, x, y)
        call DestroyEffect(AddSpecialEffect(Effect2, x, y)
        set target = FirstOfGroup(whatGroup)
        if IsUnitAlly(target, GetOwningPlayer(caster)) then
            call SetWidgetLife(target, GetWidgetLife(target) + Heal(level))
        else
            call UnitDamageTarget(caster, target, Loopdam(level), true, false, ATTACK_TYPE_MAGIC, DAMAGE_TYPE_NORMAL, null)
        endif
    endfunction
     
  2. Maximilianx

    Maximilianx

    Joined:
    Oct 14, 2008
    Messages:
    334
    Resources:
    0
    Resources:
    0
    And what exactly is going wrong?
     
  3. Deaod

    Deaod

    Joined:
    Nov 18, 2007
    Messages:
    805
    Resources:
    12
    Maps:
    1
    Spells:
    11
    Resources:
    12
    missing closing parentheses.
     
  4. naitsirk

    naitsirk

    Joined:
    Jan 24, 2009
    Messages:
    570
    Resources:
    0
    Resources:
    0
    thanks.