1. Are you planning to upload your awesome spell or system to Hive? Please review the rules here.
    Dismiss Notice
  2. Seek unity between the elements in the 22nd Terraining Contest Poll.
    Dismiss Notice
  3. Seize the moment! The 18th Mini Mapping Contest has commenced.
    Dismiss Notice
  4. The heavens smile on the old faithful. The 16th Techtree Contest has begun.
    Dismiss Notice
  5. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

Winterstar v1.3

Submitted by X-OMG-X
This bundle is marked as approved. It works and satisfies the submission rules.
Hi everybody on the hive!
This is my first spell i upload here on the hive, but not the last.
I hope you like it, because it did my best to bring you a spell.
The spell is created for- and used in my map, Dalanar RPG.

Winterstar
Hurls cold stars of ice in all directions around the Hydromancer, dealing 70/140/210 damage and freezing enemy units hit by the icecold winter stars.


The spell should be MUI and leakless, but if you find any bugs please say me.

Credits:
Demongrip - Help with triggering
Naitsirk - Help with making spell MUI
XombeR - Found leak in Map triggers
Roflcopter - Found position leak

Please give credits if used in your map!

Keywords:
Winter, star, Winterstar, x-omg-x, ice, cold, freeze, snow, water, elemental, element, mui, leakless, v1.3
Contents

Winterstar (Map)

Reviews
Moderator
11:30, 7th Oct 2009 TriggerHappy187: I really like this spell visually, good job. It seems you have fixed all of the leaks (as well as the unneeded unit group), so I can approve this.
  1. 11:30, 7th Oct 2009
    TriggerHappy187:

    I really like this spell visually, good job.

    It seems you have fixed all of the leaks (as well as the unneeded unit group), so I can approve this.
     
  2. XombeR

    XombeR

    Joined:
    Oct 4, 2009
    Messages:
    41
    Resources:
    0
    Resources:
    0
    (17:15 GMT+1) downloading...
    (17:19 GMT+1) EDIT

    *** EDIT ***
    Ok, the spell it self has no leaks and works fine!
    I would give the spell a 3.7/5

    --- REASON ---
    1: The FX works fine, so it's a [10/10 (1/5)]
    2: There are no leaks and it's MUI since it's instant [10/10 (1/5)]
    3: The spell is not that original and there are kinda lots of different versions of it, so its a [5/10 (0.5/5)]
    4: You could add some more description to the spell and add a cooldown triggered by the ESC button instead of it being "no cooldowned" as spell... [2/10 (0.2/5)]
    5: Overall: The spell works and is leakfree and MUI [1/10 (1/5)]

    --- ERRORS ---
    I found some leaks in the "map" triggers, I know it's not really a part of the spell that's why it did not come with in the review.
    Here are the solutions:
    • Map1
      • Events
        • Unit - A unit Dies
      • Conditions
        • ((Dying unit) is A Hero) Equal to True
      • Actions
        • Set Temp_Point = (Position of (Dying unit))
        • Hero - Instantly revive (Dying unit) at Temp_Point, Show revival graphics
        • Custom script: call RemoveLocation(udg_Temp_Point)

    Add variables to set the point and then remove it using Custom Scripts.

    • Map2
      • Events
        • Unit - A unit Dies
      • Conditions
        • ((Dying unit) is A Hero) Equal to False
        • (Unit-type of (Dying unit)) Not equal to Dummy
      • Actions
        • Wait 10.00 seconds
        • Set Temp_Point = (Position of (Dying unit))
        • Special Effect - Create a special effect at Temp_Point using Abilities\Spells\Undead\AnimateDead\AnimateDeadTarget.mdl
        • Unit - Create 1 (Unit-type of (Dying unit)) for (Owner of (Dying unit)) at Temp_Point facing Default building facing degrees
        • Custom script: call RemoveLocation(udg_Temp_Point)

    Same here...

    --- OTHER ---
    It's good for being a first spell on the hive from you!
    Keep it up dude!
    +rep for a working first spell!
     
  3. Roflcoptor

    Roflcoptor

    Joined:
    Nov 25, 2008
    Messages:
    188
    Resources:
    4
    Icons:
    1
    Spells:
    3
    Resources:
    4
    I don't have to get this, do I?

    Anyway wth is up with:
    • Custom Script : local unit udg_SD_Caster


    and those 30 dummys, are they really neccesary? T_T

    then random point is kinda ugly, use some math to make a nice circle.

    And besides it does leak.

    31 points per cast.

    However, a very creative use of SFX.

    And as far as i know, regions (areas) happen to leak too.
    I'd generally prefer a point with random angle.
     
  4. Demongrip

    Demongrip

    Joined:
    Sep 8, 2009
    Messages:
    80
    Resources:
    6
    Spells:
    6
    Resources:
    6
    The spell is good visually.Now on to the triggering:
    Well roflcoptor says it all.Instead of making those 30 dummys and the unit group u can simply just make an integer variable and make For each integer(variable) from 1 to 30 do actions.Also the region variable can be replaced with a point with polar offser variable for the for each integer action
    Example:
    Set Point=WS_Point(or whatever variable is your caster point) offset by 300 towards ?? degrees.This can be the point of the dummy cast since it is 300 range further from the caster.You can just experiment with it.
    With the degrees well it`s simple too just make a real variable and set it to 0.Then in the for each integer loop set the real like that:
    Set Real=Real +360/30
    Here you are done and can make it easier and more understanding to the users.Also I suggest you to add some documentation.
    If you don`t understand how to make that just pm me I`ll explain you further.
     
  5. X-OMG-X

    X-OMG-X

    Joined:
    Nov 10, 2008
    Messages:
    1,940
    Resources:
    16
    Icons:
    1
    Skins:
    3
    Maps:
    2
    Spells:
    8
    Template:
    1
    Tutorials:
    1
    Resources:
    16
    Wow thanks for the good comments.

    @XombeR: Okay will fix the leaks in map triggers

    @Rolfcopter: Yes, the 30 dummies is neccesary. About the region leak, i will try to make some research and if it leaks i will fix it.

    @Demongrip: As i said before the dummies gives it a better effect. Whatever, maybe i will change it to FEO. Try to cast the spell some times without any enemies around you and you will see the lines of stars are random. Thats why i did do the dummies.

    Anyways, thanks for the good comments and your reviews. I will try to improve myself and my spells and come up with some more soon.
     
  6. MortAr

    MortAr

    Joined:
    Feb 25, 2009
    Messages:
    1,765
    Resources:
    7
    Icons:
    6
    Packs:
    1
    Resources:
    7
    Look the attachment, same effect, less triggering.

    edit: I don't think the spell-section is the place where you have to advertise your other maps.
     

    Attached Files:

  7. Roflcoptor

    Roflcoptor

    Joined:
    Nov 25, 2008
    Messages:
    188
    Resources:
    4
    Icons:
    1
    Spells:
    3
    Resources:
    4
    So they ARE supposed to shoot in random directions? WTF?
     
  8. X-OMG-X

    X-OMG-X

    Joined:
    Nov 10, 2008
    Messages:
    1,940
    Resources:
    16
    Icons:
    1
    Skins:
    3
    Maps:
    2
    Spells:
    8
    Template:
    1
    Tutorials:
    1
    Resources:
    16
    @Roflcoptor: Yea thats right. But ofc i can change it if you guys like it better without randoms.
    @Mortar-: Will take a look at it. Thanks. And sorry for the link, will remove it.
     
  9. YourNameHere

    YourNameHere

    Joined:
    Apr 29, 2007
    Messages:
    745
    Resources:
    4
    Maps:
    1
    Spells:
    2
    JASS:
    1
    Resources:
    4
    Srsly guys, stop complaining about stuff that really can be fixed within seconds by yourself. I could just come and say OMG LOOK THIS IS BETTER WTF DID THIS GUY DO I MADE IT MORE EFFICIENTLY
    He did his best, so appreciate it. (No, this doesn't include telling him that stuff leaks, because that is actually important)

    lolwut?
    Code (vJASS):
        #include "YourName.j"

    scope Winterstar initializer init
    {

        #define
        {
            ABILITY         = 'A001'
            INTERVAL        = 0.02
            RADIUS          = 50
            MAX_DISTANCE    = 500
            EFFECT_COUNT    = 18
            DAMAGE          = GetUnitAbilityLevel(.caster, ABILITY)*300*INTERVAL
            MAX_EXECUTIONS  = 20
            EFFECT          = "Abilities\\Spells\\Undead\\FrostNova\\FrostNovaTarget.mdl"
        }
       
        private keyword Frozen
       
        private struct Winterstar
        {
            unit caster
            float cur
            float dist
           
            static timer t = new timer
            static int total = 0
            static new data
            static group enum = new group
            static boolexpr bool = null
            static thistype create(unit caster)
            {
                thistype this = new thistype
                .caster = caster
                .dist = MAX_DISTANCE/MAX_EXECUTIONS
                .cur = .dist
               
                if .total == 0
                {
                    TimerStart(.t, INTERVAL, true, function thistype.work)
                }
               
                .data[.total++] = this
               
                return this
            }
           
            private static void work()
            {
                int i = -1
                do
                {
                    break (++i >= .total)
                    thistype this; this = .data[i]
                    float x
                    float y
                    float a = 0
                    int q = -1
                    do
                    {
                        break (++q >= EFFECT_COUNT-1)
                        x = GetUnitX(.caster)+(.cur+GetRandomReal(0,50))*Cos(a)
                        y = GetUnitY(.caster)+(.cur+GetRandomReal(0,50))*Sin(a)
                        DestroyEffect(AddSpecialEffect("Abilities\\Spells\\Human\\ManaFlare\\ManaFlareMissile.mdl", x, y))
                        GroupEnumUnitsInRange(.enum, x, y, RADIUS, .bool)
                        unit u
                        do
                        {
                            u = FirstOfGroup(.enum)
                            break (u == null)
                            if IsUnitEnemy(u, GetOwningPlayer(.caster)) && !IsUnitType(u, UNIT_TYPE_DEAD)
                            {
                                UnitDamageTarget(.caster, u, DAMAGE, true, false, ATTACK_TYPE_MAGIC, DAMAGE_TYPE_NORMAL, null)
                                Frozen.create(u, FROZEN_TIME)
                                DestroyEffect(AddSpecialEffect(EFFECT, GetUnitX(u), GetUnitY(u)))
                            }
                            GroupRemoveUnit(.enum, u)
                        }
                        a += 2*bj_PI/(EFFECT_COUNT-1)
                    }
                    .cur += .dist
                    if .cur >= MAX_DISTANCE
                    {
                        .total--
                        .data[i] = .data[.total]
                        .destroy()
                    }
                }
               
                if .total == 0 {PauseTimer(.t)}
            }
        }
       
        #define
        {
            FROZEN_INTERVAL     = 0.01
            FROZEN_TIME         = GetUnitAbilityLevel(.caster, ABILITY)
            FROZEN_ANIM_SPEED   = 0
            FROZEN_RED          = 255
            FROZEN_GREEN        = 255
            FROZEN_BLUE         = 255
            FROZEN_EFFECT       = "Abilities\\Spells\\Undead\\FreezingBreath\\FreezingBreathTargetArt.mdl"
            FROZEN_ATTACHMENT   = "origin"
        }
       
        private struct Frozen
        {
            unit target
            float time
            float max
            effect fx
           
            timer t = new timer
           
            static hashtable hash
            static group frozen = new group
           
            private static void onInit()
            {
                .hash = InitHashtable()
            }
           
            static thistype create(unit target, float time)
            {
                thistype this
                if HaveSavedInteger(.hash, GetHandleId(target), 0)
                {
                    this = LoadInteger(.hash, GetHandleId(target), 0)
                }
                else
                {
                    this = new thistype
                    .target = target
                    .fx = AddSpecialEffectTarget(FROZEN_EFFECT, target, FROZEN_ATTACHMENT)
                    SetUnitTimeScale(target, FROZEN_ANIM_SPEED)
                    SetUnitVertexColor(target, FROZEN_RED, FROZEN_GREEN, FROZEN_BLUE, 255)
                    GroupAddUnit(.frozen, target)
                    SaveInteger(.hash, GetHandleId(target), 0, this)
                    SaveInteger(.hash, GetHandleId(.t), 0, this)
                    TimerStart(.t, FROZEN_INTERVAL, true, function thistype.work)
                }
               
                .time = 0
                .max = time
               
                return this
            }
           
            private static void work()
            {
                thistype this = LoadInteger(.hash, GetHandleId(GetExpiredTimer()), 0)
                SetUnitPosition(.target, GetUnitX(.target), GetUnitY(.target))
                .time = .time+FROZEN_INTERVAL
                if .time >= .max || IsUnitType(.target, UNIT_TYPE_DEAD)
                {
                    .destroy()
                }
            }
           
            private void onDestroy()
            {
                PauseTimer(.t)
                DestroyTimer(.t)
                FlushChildHashtable(.hash, GetHandleId(.target))
                FlushChildHashtable(.hash, GetHandleId(.t))
                SetUnitTimeScale(.target, 1)
                SetUnitVertexColor(.target, 255, 255, 255, 255)
                DestroyEffect(.fx)
                GroupRemoveUnit(.frozen, .target)
            }
        }
       
        private void work()
        {
            if GetSpellAbilityId() == ABILITY
            {
                Winterstar.create(GetTriggerUnit())
            }
        }
       
        private void init()
        {
            trigger trg = new trigger
            TriggerRegisterAnyUnitEventBJ(trg, EVENT_PLAYER_UNIT_SPELL_EFFECT)
            TriggerAddAction(trg, function work)
        }
    }

    NO YOU CANT COMPILE THIS BECAUSE ITS CJASS AND YOU DONT HAVE YOURNAME.J
     
  10. X-OMG-X

    X-OMG-X

    Joined:
    Nov 10, 2008
    Messages:
    1,940
    Resources:
    16
    Icons:
    1
    Skins:
    3
    Maps:
    2
    Spells:
    8
    Template:
    1
    Tutorials:
    1
    Resources:
    16
    @YourNameHere: Thanks.
    @All: Will update tomorrow, cuz i will go to bed now :p
     
  11. Demongrip

    Demongrip

    Joined:
    Sep 8, 2009
    Messages:
    80
    Resources:
    6
    Spells:
    6
    Resources:
    6
    Here I made it just as you wanted-not like a circle but like a star.If you have any questions about the triggering pm me
     

    Attached Files:

  12. X-OMG-X

    X-OMG-X

    Joined:
    Nov 10, 2008
    Messages:
    1,940
    Resources:
    16
    Icons:
    1
    Skins:
    3
    Maps:
    2
    Spells:
    8
    Template:
    1
    Tutorials:
    1
    Resources:
    16
    Thanks alot, demongrip. Your name is added to credits and +rep is given.
     
  13. Demongrip

    Demongrip

    Joined:
    Sep 8, 2009
    Messages:
    80
    Resources:
    6
    Spells:
    6
    Resources:
    6
    You are welcome.If you have any problems with triggering just pm me and I`ll look if I can help.
     
  14. Roflcoptor

    Roflcoptor

    Joined:
    Nov 25, 2008
    Messages:
    188
    Resources:
    4
    Icons:
    1
    Spells:
    3
    Resources:
    4
    well nice improvements, but you still leak a point :(

    • Special Effect - Create a special effect at >>>(Position of SD_Caster)<<< using SD_Effect
     
  15. mjllonir

    mjllonir

    Joined:
    May 31, 2009
    Messages:
    432
    Resources:
    3
    Spells:
    3
    Resources:
    3
    Could you explain to me why your attack goes up as well as your attributes? I think it's just a spell, not a buffer that gives you a permanent boost each time you use it.
     
  16. X-OMG-X

    X-OMG-X

    Joined:
    Nov 10, 2008
    Messages:
    1,940
    Resources:
    16
    Icons:
    1
    Skins:
    3
    Maps:
    2
    Spells:
    8
    Template:
    1
    Tutorials:
    1
    Resources:
    16
    Take a look at map stuff. Its just to make the caster survive better. Its not a part of the spell.

    Offtopic: Yay, approved.
     
  17. icepig01

    icepig01

    Joined:
    Oct 30, 2009
    Messages:
    2
    Resources:
    0
    Resources:
    0
    Dude, whr to change this skill AOE and the damage?
     
  18. X-OMG-X

    X-OMG-X

    Joined:
    Nov 10, 2008
    Messages:
    1,940
    Resources:
    16
    Icons:
    1
    Skins:
    3
    Maps:
    2
    Spells:
    8
    Template:
    1
    Tutorials:
    1
    Resources:
    16
    The AoE is be changeable in the triggers i think. Made the spell for months ago.
    As i can remember, the damage is changeable in the object editor (dummy spell).