Spell Rocket Launcher

Kazuga

Let the game begin...
Reaction score
110
Rocket Launcher!
Made by Kazuga aka Nicke724

Jass/Gui? GUI
Leakless? Yes
MUI? Yes
Laggless? As far as I know yes

Description:
Lanches a rocket towards your enemies. When exploding it will deal damage to all enemies within range.
The rocket is very sensitive and will explode if it hits any wall, enemy unit or flies out over an edge.
Level 1 Damages 200.
Level 2 Damages 250.
Level 3 Damages 300.
Screenshots:
Code:
Cast
Code:
Rocket launcher
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        Or - Any (Conditions) are true
            Conditions
                (Ability being cast) Equal to Rocket launcher Unchoosable
                (Ability being cast) Equal to Rocket launcher Choseable
    Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                RocketLauncherCounter Greater than or equal to 100
            Then - Actions
                Set RocketLauncherCounter = 2
            Else - Actions
                Set RocketLauncherCounter = (RocketLauncherCounter + 1)
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Ability being cast) Equal to Rocket launcher Choseable
            Then - Actions
                Set RocketLauncherRocketPoint = (Position of (Triggering unit))
                Set RocketLauncherRocketPoint2 = (Target point of ability being cast)
                Set RocketLauncherDirection[RocketLauncherCounter] = (Angle from RocketLauncherRocketPoint to RocketLauncherRocketPoint2)
                Custom script:   call RemoveLocation(udg_RocketLauncherRocketPoint)
                Custom script:   call RemoveLocation(udg_RocketLauncherRocketPoint2)
            Else - Actions
                Set RocketLauncherDirection[RocketLauncherCounter] = (Facing of (Triggering unit))
        Set RocketLauncherBoolean[RocketLauncherCounter] = True
        Set RocketLauncherCaster[RocketLauncherCounter] = (Triggering unit)
        Set RocketLauncherRocketPoint2 = (Position of (Triggering unit))
        Set RocketLauncherRocketPoint = (RocketLauncherRocketPoint2 offset by 50.00 towards RocketLauncherDirection[RocketLauncherCounter] degrees)
        Custom script:   call RemoveLocation(udg_RocketLauncherRocketPoint2)
        Sound - Play CannonTowerMissile1 <gen> at 100.00% volume, located at RocketLauncherRocketPoint with Z offset 0.00
        Unit - Create 1 Rocket launcher dummy for (Owner of (Triggering unit)) at RocketLauncherRocketPoint facing RocketLauncherDirection[RocketLauncherCounter] degrees
        Set RocketLauncherRocket[RocketLauncherCounter] = (Last created unit)
        Custom script:   call RemoveLocation(udg_RocketLauncherRocketPoint)
        Trigger - Add to Rocket Triggering <gen> the event (Unit - A unit comes within 100.00 of RocketLauncherRocket[RocketLauncherCounter])
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                RocketLauncherCounter Equal to 1
            Then - Actions
                Countdown Timer - Start RocketLauncherTimer as a Repeating timer that will expire in 0.05 seconds
            Else - Actions
Movement
Code:
Rocket movement
    Events
        Time - RocketLauncherTimer expires
    Conditions
    Actions
        For each (Integer RocketLauncherInteger) from 1 to RocketLauncherCounter, do (Actions)
            Loop - Actions
                Set RocketLauncherRocketPoint = (Position of RocketLauncherRocket[RocketLauncherInteger])
                Set RocketLauncherRocketMoveTo = (RocketLauncherRocketPoint offset by 35.00 towards RocketLauncherDirection[RocketLauncherInteger] degrees)
                Unit - Move RocketLauncherRocket[RocketLauncherInteger] instantly to RocketLauncherRocketMoveTo
                Custom script:   call RemoveLocation(udg_RocketLauncherRocketMoveTo)
                Set RocketLauncherRocketMoveTo = (RocketLauncherRocketPoint offset by 100.00 towards RocketLauncherDirection[RocketLauncherInteger] degrees)
                Set RocketLauncherRocketPoint2 = (Position of RocketLauncherRocket[RocketLauncherInteger])
                Set RocketLauncherGroup2 = (Units within 200.00 of RocketLauncherRocketPoint matching ((((Matching unit) belongs to an enemy of (Owner of RocketLauncherRocket[RocketLauncherInteger])) Equal to True) and (((Matching unit) is alive) Equal to True)))
                Destructible - Pick every destructible within 200.00 of RocketLauncherRocketPoint and do (Actions)
                    Loop - Actions
                        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                            If - Conditions
                                ((Picked destructible) is alive) Equal to True
                            Then - Actions
                                Set RocketLauncherBoolean2[RocketLauncherInteger] = True
                            Else - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        Or - Any (Conditions) are true
                            Conditions
                                (Number of units in RocketLauncherGroup2) Greater than or equal to 1
                                (Terrain pathing at RocketLauncherRocketMoveTo of type Walkability is off) Equal to True
                                (Distance between RocketLauncherRocketPoint2 and RocketLauncherRocketPoint) Less than or equal to 10.00
                                RocketLauncherBoolean2[RocketLauncherInteger] Equal to True
                    Then - Actions
                        Set RocketLauncherBoolean2[RocketLauncherInteger] = False
                        Trigger - Run Rocket Triggering <gen> (ignoring conditions)
                        Set RocketLauncherRocket[RocketLauncherInteger] = RocketLauncherRocket[RocketLauncherCounter]
                        Set RocketLauncherDirection[RocketLauncherInteger] = RocketLauncherDirection[RocketLauncherCounter]
                        Set RocketLauncherBoolean[RocketLauncherInteger] = RocketLauncherBoolean[RocketLauncherCounter]
                        Set RocketLauncherCounter = (RocketLauncherCounter - 1)
                        Set RocketLauncherInteger = (RocketLauncherInteger - 1)
                    Else - Actions
                Custom script:   call RemoveLocation(udg_RocketLauncherRocketPoint)
                Custom script:   call RemoveLocation(udg_RocketLauncherRocketPoint2)
                Custom script:   call RemoveLocation(udg_RocketLauncherRocketMoveTo)
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        RocketLauncherCounter Equal to 0
                    Then - Actions
                        Countdown Timer - Pause RocketLauncherTimer
                    Else - Actions
Triggering
Code:
Rocket Triggering
    Events
    Conditions
        And - All (Conditions) are true
            Conditions
                RocketLauncherBoolean[RocketLauncherInteger] Equal to True
                ((Triggering unit) is A flying unit) Equal to False
    Actions
        Set RocketLauncherBoolean[RocketLauncherInteger] = False
        Set RocketLauncherRocketPoint = (Position of RocketLauncherRocket[RocketLauncherInteger])
        Sound - Play CannonTowerMissile2 <gen> at 100.00% volume, located at RocketLauncherRocketPoint with Z offset 0.00
        Special Effect - Create a special effect at RocketLauncherRocketPoint using Abilities\Spells\Other\Doom\DoomDeath.mdl
        Special Effect - Destroy (Last created special effect)
        Special Effect - Create a special effect at RocketLauncherRocketPoint using Abilities\Spells\Human\FlameStrike\FlameStrike1.mdl
        Set RocketLauncherSpecial[RocketLauncherInteger] = (Last created special effect)
        Set RocketLauncherGroup[RocketLauncherInteger] = (Units within 250.00 of RocketLauncherRocketPoint matching ((((Matching unit) belongs to an enemy of (Owner of RocketLauncherRocket[RocketLauncherCounter])) Equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) is A flying unit)
        Unit Group - Pick every unit in RocketLauncherGroup[RocketLauncherInteger] and do (Actions)
            Loop - Actions
                Unit - Cause RocketLauncherCaster[RocketLauncherInteger] to damage (Picked unit), dealing ((((Real((Level of Rocket launcher Choseable for RocketLauncherCaster[RocketLauncherInteger]))) + (Real((Level of Rocket launcher Unchoosable for RocketLauncherCaster[RocketLauncherInteger])))) x 50.00) + 200.00) damage of attack type Chaos and damage type Normal

        Unit - Remove RocketLauncherRocket[RocketLauncherInteger] from the game
        Custom script:   call RemoveLocation(udg_RocketLauncherRocketPoint)
        Wait 1.00 seconds
        Special Effect - Destroy RocketLauncherSpecial[RocketLauncherInteger]

Thanks to all who helped me with making the spell.
A great thanks to darkbeer who helped me make this into mui.

Enjoy:p

Edits:
Fixed the bugg that sometimes made the rocket to glide around a unit.
Fixed the damage bug.
The rocket now explodes when hiting trees and other destructebles.
 

Attachments

  • Rocket launcher MUI.w3x
    37.8 KB · Views: 547
Yes, this is the right place just incase you were wondering

PS: Good spell (Y)

EDIT: A moderator will hopefully come around soon and test it and then move it to the spells section!
 
The rocket sometimes goes around units, and doesn't blow up. Like when I targeted the gnoll at the start, it was heading towards it, then moved to the side of it.

Other than that, it is a good spell :thup:.
 
Hm I thought I fixed that before... It has with the detection range, it is set to 200 so a unit has to be within 200 range when the unit moves in order to make it explode. I will look over it after school.

Edit: Fixed, I had forgotten a condition...^^
 
what defines the spell level damage, i can only find one action that sets the damage dealt and it's a static 200 damage, not 200/250/300.

Not that hard to fix myself but would still like to know :)?

PS: Neat spell, +rep, helped alot :D
 
Thanks for pointing that out, strange I'm 99% sure I fixed that part... anyway fixed that to now. Surely hopes that there isn't anything else that needs to be edited in order to get this approved.
 
Hehe no problem mate^^, I got alot of help from darkbeer so it's no problem.:thup:
 
I acually found it rather amusing shooting those rockets at poor defenceless creatures. I didn't go through the code though since GUI bores the crap out of me. Great work + rep.
 
oo, pretty rocket launcher ability, but does a unit needs to carry a rocket launcher so he can shoot from it?

+rep
 
No, all you need is enough mana and no cooldown;).

Ty:p

your welcome

but do that unit needs to carry rocket launcher

so it would make it more realistic

but okay, anyway

(can the mortars do the shot?)
 
but do that unit needs to carry rocket launcher

so it would make it more realistic
Not in this spell, I can edit one for you that require rockets if you want but this one is not to be changed unless it's some sort of bug or leak that I have forgot about.

but okay, anyway

(can the mortars do the shot?)
Yes, any unit can. Just pick a hero and teach him the spell and there you go.:thup:
You can also let normal units use it by going into the spell in object editor, go to stats and find "Hero ability - true", change that to false and then you can teach it to normal units.
 
ive found a bug...
im shooting the rocket and its sliding along the trees
 
Ye, I know about that and it's been taken up before... Of what I know there is no way too solve that problem=/ But if you can think of one I will be forever greatful.
 
Pick every destructible in X range, then, within the loop, increase an integer's value by 1. If (integer) greater than 0, theres a destructible in range, so you can destroy your rocket.

Or, if possible, count the number of destructibles in range of a point (would be easier than the group)
None of those is possible, atleast not with gui, just tried it and there is no actions that counts destructebles or even any destructeble/group destructeble variables...

Edit: Sorry for my spelling, I just can't learn to spell that word..
 
I don't think destructible groups leak (at least that's what I have heard)

Code:
Destructible - Pick every destructible in (Region centered at (Position of (Triggering unit)) with size ((Real(Collision radius)), (Real(Collision radius)))) and do (Actions)
    Loop - Actions

Obviously without the region and location leaks :D

You could see whether it leaks by using lots of Pick every Destructable every 0.05 seconds (just CnP the action until you get bored?) and see if your FPS counter makes a noticeable drop at any stage
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    Check out my new teeth in my profile pic :)
  • The Helper The Helper:
    Fucking bionic
  • The Helper The Helper:
    Zirconium
  • V-SNES V-SNES:
    Looks great!
    +1
  • The Helper The Helper:
    Happy Thursday!
    +1
  • The Helper The Helper:
    Added new Crab Bisque Soup recipe - which is badass by the way - Crab Bisque - https://www.thehelper.net/threads/soup-crab-bisque.196085/
  • The Helper The Helper:
    I feel like we need to all meet up somewhere sometime. Maybe like in Vegas :)
    +2
  • The Helper The Helper:
    Would love to go to Vegas I have never been and it would be an adventure! Who is in?
  • The Helper The Helper:
    at least the full on bot attack has stopped it was getting ridiculous there for a while and we use cloudflare and everything
  • jonas jonas:
    I'm sure my wife would not be happy if I went to Vegas, but don't let that stop you guys - would be hard for me to attend anyways
    +1
  • jonas jonas:
    Do you know why the bot attack stopped?
  • The Helper The Helper:
    maybe they finally got everything lol
  • Ghan Ghan:
    There's lots of good food in Vegas.
  • Ghan Ghan:
    Everything tends to be pretty expensive though so bring your wallet.
    +1
  • The Helper The Helper:
    I have to wait longer if I am going for food because my teeth are still messed up from the work and I still cannot eat right. Going to be a couple more months before that gets better
    +1
  • The Helper The Helper:
    I would immediately hitting the dispensary though :)
    +1
  • Varine Varine:
    My Xbox account got hijacked, and apparently I have a different one from like 10 years ago that Microsoft keeps telling me is the right one
  • Varine Varine:
    Like NO, I mean for some reason that one is attached to my email, but it's not the right one
  • Varine Varine:
    I have a different one, and that one has my credit card attached to it and I would like that credit card to not be attached to it if I can't get it back
  • Varine Varine:
    Anyway Microsoft is not very helpful with this, they just keep telling me to fill out the Account Recovery form, but that just redirects me to the other account
  • The Helper The Helper:
    They should not allow you to put a credit card on a account that does not have human customer service you can call
  • Varine Varine:
    That's the only thing that got hijacked at least. I don't totally know how these integrate together, but it seems like I should be able to do this via the gamertag. Like my email is still mine, but they changed the email to that account I'm guessing.
    +1
  • Blackveiled Blackveiled:
    I went to Vegas a few weeks ago to visit my mom. I had never been either, lol! But I'm working in Salt Lake City at the moment so it's not a far trip.
    +1
  • The Helper The Helper:
    I have never been to Vegas and it is on the bucket list so...

      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