Starcraft II Beta Key Spell Contest

TriggerHappy

Spell Moderator
Level 37
Joined
Jun 23, 2007
Messages
4,027
Spell Contest
Win a Sc2 Beta key

The objective of this spell contest is to create a futuristic type spell which would fit into Starcraft II concept-wise. Once again, the spell needs to be futuristic or tech-like and must be a spell which would fit into Starcraft II. All the placers will receive a beta key for Starcraft II (1st, 2nd, 3rd place) along with some rep.

There will only be one judge which is me.

Rules

  • No submission may violate any Hive Workshop site rules.
  • Your submitted spell must follow the theme description. If the judging moderator feels that your spell does not follow the selected theme, then it is his decision to disqualify you.
  • You may use any amount of imported resources in your spell as long as you give proper credit to the creator of the resource.
  • Either GUI or Jass may be used to create your spell; you will not be penalized if you use GUI over Jass.
  • Spells must be at least MPI. You will be marked down for not having a MUI spell. If it's not at least MPI your submission will not be counted.
  • Third party editors may be used in the creation of your spell, but you must clearly state which editor you used to create the map. If a third party editor is necessary to use your spell, add a link, along with your spell submission, to download the editor.

    Examples of third party editors are:
    • World Editor Unlimited
    • JassNewGenPack (or Grimoire)
    • UMSWE
  • Each spell submission must be created during the contest and must be submitted before the contest deadline (noted at the end of this post).
  • You may use utilities that do small jobs for you, but you may not use large systems that do everything.

    Example of utilities
    • CSCache
    • Armor Detection System
    • Local Handle Vars
    • Vector System
    Example of large systems
    • Caster System
    • Particle/Object Engine
    • Knockback Functions
    • Jump System
  • An infraction of any of the rules stated above may result in a disqualification.
  • Judges may not participate in the contest as contestants.
  • Your submission must be created only by you : No team submissions.
  • Completed submissions must be physically attached to this thread in a post.
  • Your last submission will be the considered the final submission, unless if you are previously disqualified from this contest.

Grading


Eyecandy 20 pts
Does the spell look good visually?​
Coding 20 pts
Is the spell efficient, leakless and MUI?​
Rules 10 pts
Did your spell follow the rules?​
Concept 20 pts
Is the spells idea unique and original?​

Rewards


First Place: 10 rep, a beta key and an award icon.
Second Place: 8 rep and a beta key.
Third Place: 5 rep and a beta key.

The contest concludes on April 30th.
 
Last edited:
Level 19
Joined
Apr 22, 2007
Messages
1,960
I'd really like to do this one, but I'm hella busy and otherwise probably wouldn't end up finishing anything anyway. lol

I might, by some crazy chance, actually manage to participate, even though I haven't Jassed in something like a year or more.
 

TriggerHappy

Spell Moderator
Level 37
Joined
Jun 23, 2007
Messages
4,027
Anachron said:
I'd be able to judge.

The main post said:
There will only be one judge which is me.

Anachron said:
Or on the other site, if I participate as contestant, am I able to use my Missile Engine?

No.

Pharoh_ said:
Is a WIP required?

I could honestly care less. I've always disliked that rule.

HINDYhay said:
I'd really like to do this one, but I'm hella busy and otherwise probably wouldn't end up finishing anything anyway. lol

I might, by some crazy chance, actually manage to participate, even though I haven't Jassed in something like a year or more.

DOO ITTT!
 
Level 22
Joined
Dec 31, 2006
Messages
2,216
Could be funny to join, but I already have a key. Maybe I can join just for the lulz, i.e, you don't have to review my submission. If you do then remember to not count me as a real participant.
 
Level 18
Joined
Feb 28, 2009
Messages
1,971
Could be funny to join, but I already have a key. Maybe I can join just for the lulz, i.e, you don't have to review my submission. If you do then remember to not count me as a real participant.
Umm, well. SC2 won`t run on my PC but anyway I take a part here for fun :p I`ll probably give the key to someone.
 
Level 3
Joined
Apr 20, 2010
Messages
46
I already have a beta-key on the way but I'd like to make something anyway. Haven't participated in anything like this before.
 
Level 17
Joined
Aug 16, 2007
Messages
860
Starcraft II Beta Key Spell Contest submission

Hello! I thought I could join this contest and so I did. I've been working at this spell a few hours now, and I think this is the final! It went out kinda good :)

I also made the spell very user friendly, in the fact someone else wanted to use it.


Shoot a missile at a target point. When the missile finds an enemie within a specific range it will seek to the enemie and if the missile hits the enemie it will be stuck into the enemies body. While it's stuck, the missile will order beam turrets to shoot beams at the hitted unit.

Lasts 5 seconds.

Level 1 - 200 total damage.

Level 2 - 400 total damage.

Level 3 - 600 total damage.




  • Energy Missile Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Energy Missile
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • EM_Index[2] Equal to 0
        • Then - Actions
          • Trigger - Turn on Energy Missile Loop <gen>
        • Else - Actions
      • Set EM_Index[1] = (EM_Index[1] + 1)
      • Set EM_Index[2] = (EM_Index[2] + 1)
      • Set EM_MissileOff[EM_Index[1]] = False
      • Set EM_Caster[EM_Index[1]] = (Triggering unit)
      • Set EM_Point[0] = (Position of (Triggering unit))
      • Set EM_Point[1] = (Target point of ability being cast)
      • Set EM_MissileAngle[EM_Index[1]] = (Angle from EM_Point[0] to EM_Point[1])
      • -------- -------------------- --------
      • Set EM_MissileHomingTarget[EM_Index[1]] = No unit
      • -------- -------------------- --------
      • Set EM_MissileArt[EM_Index[1]] = Abilities\Weapons\SpiritOfVengeanceMissile\SpiritOfVengeanceMissile.mdl
      • Set EM_DamageEffect[EM_Index[1]] = war3mapImported\IonCannonBeam.mdl
      • Set EM_DamageEffect2[EM_Index[1]] = Abilities\Spells\Human\Thunderclap\ThunderClapCaster.mdl
      • Set EM_MissileSize = 140.00
      • Set EM_MissileStartHeight = 90.00
      • -------- -------------------- --------
      • Set EM_MissileDamage[EM_Index[1]] = (200.00 x (Real((Level of (Ability being cast) for (Triggering unit)))))
      • Set EM_SpellDuration[EM_Index[1]] = 5.00
      • Set EM_MissileLifeTime[EM_Index[1]] = 3.75
      • Set EM_MissileSpeed[EM_Index[1]] = 17.50
      • Set EM_MissileHomingDetectionAoE[EM_Index[1]] = 400.00
      • Set EM_MissileHitAoE[EM_Index[1]] = 125.00
      • -------- -------------------- --------
      • Set EM_Counter[EM_Index[1]] = 0.00
      • Set EM_CounterMax[EM_Index[1]] = 0.50
      • Set EM_TimeUntilDamage[EM_Index[1]] = 0.50
      • -------- -------------------- --------
      • Set EM_Point[2] = (EM_Point[0] offset by 100.00 towards EM_MissileAngle[EM_Index[1]] degrees)
      • Unit - Create 1 Dummy_Unit for (Owner of (Triggering unit)) at EM_Point[2] facing EM_MissileAngle[EM_Index[1]] degrees
      • Set EM_MissileUnit[EM_Index[1]] = (Last created unit)
      • Special Effect - Create a special effect attached to the origin of EM_MissileUnit[EM_Index[1]] using EM_MissileArt[EM_Index[1]]
      • Set EM_MissileSpecialEffect[EM_Index[1]] = (Last created special effect)
      • -------- -------------------- --------
      • Animation - Change EM_MissileUnit[EM_Index[1]]'s size to (EM_MissileSize%, EM_MissileSize%, EM_MissileSize%) of its original size
      • Animation - Change EM_MissileUnit[EM_Index[1]] flying height to EM_MissileStartHeight at 0.00
      • -------- -------------------- --------
      • Custom script: call RemoveLocation(udg_EM_Point[0])
      • Custom script: call RemoveLocation(udg_EM_Point[1])
      • Custom script: call RemoveLocation(udg_EM_Point[2])


  • Energy Missile Loop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • For each (Integer EM_Index[3]) from 1 to EM_Index[1], do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • EM_MissileOff[EM_Index[3]] Equal to False
            • Then - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • EM_MissileLifeTime[EM_Index[3]] Less than or equal to 0.00
                • Then - Actions
                  • Set EM_MissileOff[EM_Index[3]] = True
                  • -------- -------------------- --------
                  • Unit - Kill EM_MissileUnit[EM_Index[3]]
                  • Special Effect - Destroy EM_MissileSpecialEffect[EM_Index[3]]
                  • -------- -------------------- --------
                  • Set EM_Index[2] = (EM_Index[2] - 1)
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • EM_Index[2] Less than or equal to 0
                    • Then - Actions
                      • Set EM_Index[1] = 0
                      • Set EM_Index[2] = 0
                      • Trigger - Turn off Energy Missile Loop <gen>
                    • Else - Actions
                • Else - Actions
                  • Custom script: set udg_EM_MissileLifeTime[udg_EM_Index[3]] = (udg_EM_MissileLifeTime[udg_EM_Index[3]] - 0.03)
                  • -------- -------------------- --------
                  • Set EM_Point[0] = (Position of EM_MissileUnit[EM_Index[3]])
                  • Set EM_Point[1] = (EM_Point[0] offset by EM_MissileSpeed[EM_Index[3]] towards EM_MissileAngle[EM_Index[3]] degrees)
                  • Unit - Move EM_MissileUnit[EM_Index[3]] instantly to EM_Point[1]
                  • -------- -------------------- --------
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • EM_MissileHomingTarget[EM_Index[3]] Equal to No unit
                    • Then - Actions
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • EM_Counter[EM_Index[3]] Greater than or equal to EM_CounterMax[EM_Index[3]]
                        • Then - Actions
                          • Set EM_Counter[EM_Index[3]] = 0.00
                          • Set EM_UnitGroup = (Units within EM_MissileHomingDetectionAoE[EM_Index[3]] of EM_Point[1] matching (((((Matching unit) is A structure) Equal to False) and (((Matching unit) is alive) Equal to True)) and ((((Matching unit) is A ground unit) Equal to True) and (((Matching unit) b
                          • Unit Group - Pick every unit in EM_UnitGroup and do (Actions)
                            • Loop - Actions
                              • Set EM_Point[2] = (Position of (Picked unit))
                              • Set EM_MissileAngle[EM_Index[3]] = (Angle from EM_Point[0] to EM_Point[2])
                              • Custom script: call RemoveLocation(udg_EM_Point[2])
                          • Custom script: call DestroyGroup(udg_EM_UnitGroup)
                        • Else - Actions
                          • Set EM_Counter[EM_Index[3]] = (EM_Counter[EM_Index[3]] + 0.03)
                      • -------- -------------------- --------
                      • Set EM_UnitGroup = (Units within EM_MissileHitAoE[EM_Index[3]] of EM_Point[1] matching (((((Matching unit) is A structure) Equal to False) and (((Matching unit) is alive) Equal to True)) and ((((Matching unit) is A ground unit) Equal to True) and (((Matching unit) belongs to an
                      • Unit Group - Pick every unit in EM_UnitGroup and do (Actions)
                        • Loop - Actions
                          • Set EM_MissileHomingTarget[EM_Index[3]] = (Picked unit)
                      • Custom script: call DestroyGroup(udg_EM_UnitGroup)
                    • Else - Actions
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • EMC_Index[2] Equal to 0
                        • Then - Actions
                          • Trigger - Turn on Energy Missile Charge Loop <gen>
                        • Else - Actions
                      • -------- -------------------- --------
                      • Set EMC_Index[1] = (EMC_Index[1] + 1)
                      • Set EMC_Index[2] = (EMC_Index[2] + 1)
                      • Set EMC_Off[EMC_Index[1]] = False
                      • -------- -------------------- --------
                      • Set EMC_Unit[EMC_Index[1]] = EM_MissileHomingTarget[EM_Index[3]]
                      • Set EMC_Damage[EMC_Index[1]] = EM_MissileDamage[EM_Index[3]]
                      • Set EMC_Duration[EMC_Index[1]] = EM_MissileEnergyChargeDuration[EM_Index[3]]
                      • Set EMC_DurationMax[EMC_Index[1]] = EM_MissileEnergyChargeDuration[EM_Index[3]]
                      • Set EMC_DamageEffect[EMC_Index[1]] = EM_DamageEffect[EM_Index[3]]
                      • Set EMC_DamageEffect2[EMC_Index[1]] = EM_DamageEffect2[EM_Index[3]]
                      • Set EMC_SpellEnd[EMC_Index[1]] = False
                      • Set EMC_Caster[EMC_Index[1]] = EM_Caster[EM_Index[3]]
                      • Set EMC_SpellEffectCounterMax[EMC_Index[1]] = EM_TimeUntilDamage[EM_Index[3]]
                      • -------- -------------------- --------
                      • Special Effect - Create a special effect attached to the head of EM_MissileHomingTarget[EM_Index[3]] using EM_MissileArt[EM_Index[3]]
                      • Set EMC_UnitEffect[EMC_Index[1]] = (Last created special effect)
                      • -------- -------------------- --------
                      • Set EM_MissileLifeTime[EM_Index[3]] = 0.00
                  • -------- -------------------- --------
                  • Custom script: call RemoveLocation(udg_EM_Point[0])
                  • Custom script: call RemoveLocation(udg_EM_Point[1])
            • Else - Actions


  • Energy Missile Charge Loop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • For each (Integer EMC_Index[3]) from 1 to EMC_Index[1], do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • EMC_Off[EMC_Index[3]] Equal to False
            • Then - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • EMC_SpellEnd[EMC_Index[3]] Equal to True
                • Then - Actions
                  • Set EMC_Off[EMC_Index[3]] = True
                  • -------- -------------------- --------
                  • Special Effect - Destroy EMC_UnitEffect[EMC_Index[3]]
                  • -------- -------------------- --------
                  • Set EMC_Index[2] = (EMC_Index[2] - 1)
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • EMC_Index[2] Less than or equal to 0
                    • Then - Actions
                      • Set EMC_Index[1] = 0
                      • Set EMC_Index[2] = 0
                      • Trigger - Turn off Energy Missile Charge Loop <gen>
                    • Else - Actions
                • Else - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • EMC_Duration[EMC_Index[3]] Less than or equal to 0.00
                    • Then - Actions
                      • Set EMC_SpellEnd[EMC_Index[3]] = True
                    • Else - Actions
                      • Set EMC_Duration[EMC_Index[3]] = (EMC_Duration[EMC_Index[3]] - 0.03)
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • EMC_SpellEffectCounter[EMC_Index[3]] Greater than or equal to EMC_SpellEffectCounterMax[EMC_Index[3]]
                        • Then - Actions
                          • Set EMC_SpellEffectCounter[EMC_Index[3]] = 0.00
                          • -------- -------------------- --------
                          • Special Effect - Create a special effect attached to the origin of EMC_Unit[EMC_Index[3]] using EMC_DamageEffect[EMC_Index[3]]
                          • Special Effect - Destroy (Last created special effect)
                          • Special Effect - Create a special effect attached to the origin of EMC_Unit[EMC_Index[3]] using EMC_DamageEffect2[EMC_Index[3]]
                          • Special Effect - Destroy (Last created special effect)
                          • -------- -------------------- --------
                          • Set EMC_Real = (EMC_Damage[EMC_Index[3]] / (EMC_DurationMax[EMC_Index[3]] / EMC_SpellEffectCounterMax[EMC_Index[3]]))
                          • Unit - Cause EMC_Caster[EMC_Index[3]] to damage EMC_Unit[EMC_Index[3]], dealing EMC_Real damage of attack type Chaos and damage type Normal
                          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                            • If - Conditions
                              • (EMC_Unit[EMC_Index[3]] is alive) Equal to False
                            • Then - Actions
                              • Set EMC_Duration[EMC_Index[3]] = 0.00
                            • Else - Actions
                        • Else - Actions
                          • Set EMC_SpellEffectCounter[EMC_Index[3]] = (EMC_SpellEffectCounter[EMC_Index[3]] + 0.03)
            • Else - Actions






Well, goodluck to everyone ^^

Download: View attachment Energy Missile - The_Flood.w3x
 
Last edited:
Level 3
Joined
Apr 20, 2010
Messages
46
That will mean you cant win or take any of the 1/2/3 places though.

Yeah, perhaps it is more accurate to say that I am inspired to make something because of the contest, opposed to For the contest. So I can challenge myself creatively and technically and get critique from people.
 

Cokemonkey11

Code Moderator
Level 26
Joined
May 9, 2006
Messages
3,369
Spell: High Oribital Drop Pod

"Radios in co-ordinates for a High Oribital Drop Pod to be sent. Stuns nearby enemy units upon landing. The HODP heals nearby friendly units and repels enemy units. Lasts 30 seconds.

Level upgrades reduce cooldown and mana cost."

Triggers:

libIsTerrainWalkable (thanks to anitarf and vexorian)
JASS:
//Thanks to anitarf and Vexorian @ wc3c.net for this library, it makes things easier.

library IsTerrainWalkable initializer Init
    globals
        // this value is how far from a point the item may end up for the point to be considered pathable
        private constant real MAX_RANGE=10.
        // the following two variables are set to the position of the item after each pathing check
        // that way, if a point isn't pathable, these will be the coordinates of the nearest point that is
        public real X=0.
        public real Y=0.
        
        private rect r
        private item check
        private item array hidden
        private integer hiddenMax = 0
    endglobals

    private function Init takes nothing returns nothing
        set check=CreateItem('ciri',0,0)
        call SetItemVisible(check,false)
        set r=Rect(0.0,0.0,128.0,128.0)
    endfunction

    private function HideBothersomeItem takes nothing returns nothing
        if IsItemVisible(GetEnumItem()) then
            set hidden[hiddenMax]=GetEnumItem()
            call SetItemVisible(hidden[hiddenMax],false)
            set hiddenMax=hiddenMax+1
        endif
    endfunction

    function IsTerrainWalkable takes real x, real y returns boolean
        // first, hide any items in the area so they don't get in the way of our item
        call MoveRectTo(r,x,y)
        call EnumItemsInRect(r,null,function HideBothersomeItem)
        // try to move the check item and get it's coordinates
        call SetItemPosition(check,x,y)//this unhides the item...
        set X=GetItemX(check)
        set Y=GetItemY(check)
        call SetItemVisible(check,false)//...so we must hide it again
        // before returning, unhide any items that got hidden at the start
        loop
            exitwhen hiddenMax<=0
            set hiddenMax=hiddenMax-1
            call SetItemVisible(hidden[hiddenMax],true)
            set hidden[hiddenMax]=null
        endloop
        // return pathability status
        return (x-X)*(x-X)+(y-Y)*(y-Y)<MAX_RANGE*MAX_RANGE
    endfunction
endlibrary

hodp:
JASS:
//Notes: Using z=.005x^2+150?

scope HODP initializer i
    private struct cruiserDat
        unit cruiser
        unit box
        integer offset
    endstruct
    
    globals
        private constant integer HODPCODE='A000'
        private constant integer CRUISERCODE='h001'
        private constant integer BUFFID='BHav' //Avatar
        private constant integer BOMBCODE='A001'
        private constant integer BOXID='h002'
        private constant integer DUMMYID='h003'
        private constant integer STUNID='A002'
        private constant integer SENTRYID='h004'
        private timer time=CreateTimer()
        private integer dbIndex=-1
        private player tempPlayer
        private group grp=CreateGroup()
        private cruiserDat array cruiserDB
    endglobals
    
    private function f takes nothing returns boolean
        local unit u
        local unit filter=GetFilterUnit()
        if IsUnitEnemy(filter,tempPlayer) then
            set u=CreateUnit(tempPlayer,DUMMYID,GetUnitX(filter),GetUnitY(filter),270)
            call UnitAddAbility(u,STUNID)
            call IssueTargetOrder(u,"thunderbolt",filter)
            call UnitApplyTimedLife(u,BUFFID,5)
        endif
        set filter=null
        return false
    endfunction
    
    private function p takes nothing returns nothing
        local cruiserDat tempDat
        local integer index=0
        local effect fx
        local unit sentry
        local player tempPlayer
        loop
            exitwhen index>dbIndex
            set tempDat=cruiserDB[index]
            set tempDat.offset=tempDat.offset-10
            call SetUnitFlyHeight(tempDat.cruiser,(.005)*(tempDat.offset*tempDat.offset)+150,0)
            call SetUnitX(tempDat.cruiser,GetUnitX(tempDat.cruiser)-10)
            call SetUnitVertexColor(tempDat.cruiser,255,255,255,255-R2I(.2*(GetUnitFlyHeight(tempDat.cruiser))))
            if tempDat.offset<150 then
                if tempDat.box==null then
                    set tempPlayer=GetOwningPlayer(tempDat.cruiser)
                    set tempDat.box=CreateUnit(tempPlayer,BOXID,GetUnitX(tempDat.cruiser),GetUnitY(tempDat.cruiser),270)
                    call SetUnitFlyHeight(tempDat.box,GetUnitFlyHeight(tempDat.cruiser)-100,0)
                endif
                if GetUnitFlyHeight(tempDat.box)>10 then
                    call SetUnitX(tempDat.box,GetUnitX(tempDat.box)-5)
                    call SetUnitFlyHeight(tempDat.box,GetUnitFlyHeight(tempDat.box)-20,0)
                elseif GetWidgetLife(tempDat.box)>1 then
                    set fx=AddSpecialEffect("Objects\\Spawnmodels\\Undead\\ImpaleTargetDust\\ImpaleTargetDust.mdl",GetUnitX(tempDat.box),GetUnitY(tempDat.box))
                    call DestroyEffect(fx)
                    set tempPlayer=GetOwningPlayer(tempDat.box)
                    call GroupEnumUnitsInRange(grp,GetUnitX(tempDat.box),GetUnitY(tempDat.box),150,Filter(function f))
                    call KillUnit(tempDat.box)
                    set sentry=CreateUnit(GetOwningPlayer(tempDat.box),SENTRYID,GetUnitX(tempDat.box),GetUnitY(tempDat.box),270)
                    call UnitApplyTimedLife(sentry,BUFFID,30)
                endif
            endif
            if GetUnitFlyHeight(tempDat.cruiser)<350 then
                call UnitAddAbility(tempDat.cruiser,BOMBCODE)
            else
                call UnitRemoveAbility(tempDat.cruiser,BOMBCODE)
            endif
            if tempDat.offset<-500 then
                call RemoveUnit(tempDat.cruiser)
                call tempDat.destroy()
                set cruiserDB[index]=cruiserDB[dbIndex]
                set dbIndex=dbIndex-1
                if dbIndex==-1 then
                    call PauseTimer(time)
                endif
            endif
            set index=index+1
        endloop
        set tempPlayer=null
    endfunction
    
    private function c takes nothing returns boolean
        local real x
        local real y
        local location where
        local unit u
        local cruiserDat tempDat
        if GetSpellAbilityId()==HODPCODE then
            set where=GetSpellTargetLoc()
            set u=CreateUnit(GetOwningPlayer(GetSpellAbilityUnit()),CRUISERCODE,GetLocationX(where)+500,GetLocationY(where),180)
            call UnitApplyTimedLife(u,BUFFID,8)
            call SetUnitAnimation(u,"Walk")
            set tempDat=cruiserDat.create()
            set tempDat.cruiser=u
            set tempDat.offset=500
            set tempDat.box=null
            set dbIndex=dbIndex+1
            set cruiserDB[dbIndex]=tempDat
            if dbIndex==0 then
                call TimerStart(time,.03,true,function p)
            endif
            call RemoveLocation(where)
        endif
        return false
    endfunction
    
    private function i takes nothing returns nothing
        local trigger t=CreateTrigger()
        call TriggerRegisterAnyUnitEventBJ(t,EVENT_PLAYER_UNIT_SPELL_EFFECT)
        call TriggerAddCondition(t,Condition(function c))
    endfunction
endscope

blast:
JASS:
scope blast initializer i
    private struct kbDat
        unit pushee
        real degDirection
        integer power
    endstruct
    
    globals
        private constant integer BLASTID='A004'
        private unit tempCaster
        private timer time=CreateTimer()
        private integer dbIndex=-1
        private group grp=CreateGroup()
        private kbDat array kbDB
    endglobals
    
    private function p takes nothing returns nothing
        local integer index=0
        local kbDat tempDat
        local real x
        local real y
        loop
            exitwhen index>dbIndex
            set tempDat=kbDB[index]
            set x=GetUnitX(tempDat.pushee)+tempDat.power*Cos(tempDat.degDirection*bj_DEGTORAD)
            set y=GetUnitY(tempDat.pushee)+tempDat.power*Sin(tempDat.degDirection*bj_DEGTORAD)
            if IsTerrainWalkable(x,y) then
                call SetUnitX(tempDat.pushee,x)
                call SetUnitY(tempDat.pushee,y)
            else
                set tempDat.power=1
            endif
            set tempDat.power=tempDat.power-1
            if tempDat.power<1 then
                call tempDat.destroy()
                set kbDB[index]=kbDB[dbIndex]
                set dbIndex=dbIndex-1
                if dbIndex==-1 then
                    call PauseTimer(time)
                endif
            endif
            set index=index+1
        endloop
    endfunction

    private function f takes nothing returns boolean
        local kbDat tempDat
        if IsUnitEnemy(GetFilterUnit(),GetOwningPlayer(tempCaster)) then
            set tempDat=kbDat.create()
            set tempDat.pushee=GetFilterUnit()
            set tempDat.degDirection=bj_RADTODEG*Atan2(GetUnitY(GetFilterUnit())-GetUnitY(tempCaster),GetUnitX(GetFilterUnit())-GetUnitX(tempCaster))
            set tempDat.power=20
            set dbIndex=dbIndex+1
            set kbDB[dbIndex]=tempDat
            if dbIndex==0 then
                call TimerStart(time,.03,true,function p)
            endif
        endif
        return false
    endfunction
    
    private function c takes nothing returns boolean
        if GetSpellAbilityId()==BLASTID then
            set tempCaster=GetSpellAbilityUnit()
            call GroupEnumUnitsInRange(grp,GetUnitX(GetSpellAbilityUnit()),GetUnitY(GetSpellAbilityUnit()),500,Filter(function f))
        endif
        return false
    endfunction
    
    private function i takes nothing returns nothing
        local trigger t=CreateTrigger()
        call TriggerRegisterAnyUnitEventBJ(t,EVENT_PLAYER_UNIT_SPELL_EFFECT)
        call TriggerAddCondition(t,Condition(function c))
    endfunction
endscope


http://www.hiveworkshop.com/forums/pastebin.php?id=xf1wu4

Edit: This spell uses vJass, which requires JassHelper to compile. The easiest way to do this is by using Jass Newgen Pack (http://www.wc3c.net/showthread.php?t=90999)

Edit2: Thanks Preskooldude for pointing out the leak.
 
Last edited:
Level 17
Joined
Jan 21, 2006
Messages
2,545
Alright, I'm in. Here's my idea:


Jeru'phalek
Dark Templar

Dark Plate
Harvesting the power of dark matter, the Dark Templar forces all nearby ranged attacks to be redirected towards the Dark Templar. When the dark plate absorbs an incoming attack, a discharge is released that deals damage to enemy units. The Dark Templar only takes 40% of the damage from incoming ranged attacks while Dark Plate is active.

Level 1 – Each discharge deals 40 damage.
Level 2 – Each discharge deals 60 damage.
Level 3 – Each discharge deals 80 damage.
Level 4 – Each discharge deals 100 damage.

Cooldown: 16 seconds



I am planning on using the projectiles library that I have been working on for quite some time now to build the demo map, and basically what this spell will do is cause nearby ranged attacks (which will be controlled with the projectiles library) to alter their targets to focus on the Dark Templar, and this will react with the armor and release "lasers" that deal damage to enemies (lasers = line damage).
 
Level 8
Joined
Jul 23, 2005
Messages
329
I really need a beta key, so I guess I'm in too.

Do they have to be hero spells? I've got an idea for a spell based off of the vultures in SC1, but it's a unit spell.
 
Level 17
Joined
Jan 21, 2006
Messages
2,545
In my demo I plan on using a projectiles library (that is my own work) to control ranged attacks is this allowed? The spell uses features of the system but there is still a large amount of code that is not going to be handled by the library, and I was wondering if this violates the rule of not using large "all-powerful" systems.
 
Top