Spell Desperate Explosion

Vestras

Retired
Reaction score
248
Jass/Gui: Gui
Leakless: Yes
Lagless: Should be
Mui: Negative
Import difficult: No, very easy.

This spell it from my map, Infiltration of the Mountains

Type: Explosion
Buff: None
Cooldown: 90s

Creates a massive explosion around the caster, dealing incredible damage. Very powerfull, even though the caster is weakened much.

Code:
Desperate Explosion Cast
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Desperate Explosion 
    Actions
        Unit - Pause De_Caster[De_TempInteger]
        Set De_TempInteger = (Player number of (Owner of (Triggering unit)))
        Set De_Caster[De_TempInteger] = (Casting unit)
        Set De_CasterLoc[De_TempInteger] = (Position of De_Caster[De_TempInteger])
        Set De_Region[De_TempInteger] = (Region centered at De_CasterLoc[De_TempInteger] with size (700.00, 700.00))
        Set De_UnitGroup[De_TempInteger] = (Units within 700.00 of De_CasterLoc[De_TempInteger] matching (((Owner of (Matching unit)) is an enemy of (Owner of De_Caster[De_TempInteger])) Equal to True))
        Set De_Life[De_TempInteger] = (Percentage life of De_Caster[De_TempInteger])
        Set De_Integer[De_TempInteger] = ((Integer(De_Life[De_TempInteger])) / 2)
        Countdown Timer - Start De_Timer[De_TempInteger] as a Repeating timer that will expire in 0.30 seconds
        Wait 10.00 seconds
        Set De_TempInteger = (Player number of (Owner of (Triggering unit)))
        Countdown Timer - Pause De_Timer[De_TempInteger]
        Unit - Unpause De_Caster[De_TempInteger]
        Unit - Set life of De_Caster[De_TempInteger] to De_Life[De_TempInteger]
        Custom script:   call RemoveLocation(udg_De_CasterLoc[udg_De_TempInteger])
        Custom script:   call RemoveRect(udg_De_Region[udg_De_TempInteger])
        Custom script:   call DestroyGroup(udg_De_UnitGroup[udg_De_TempInteger])

Code:
Desperate Explosion Periodic
    Events
        Time - De_Timer[1] expires
        Time - De_Timer[2] expires
        Time - De_Timer[3] expires
        Time - De_Timer[4] expires
        Time - De_Timer[5] expires
        Time - De_Timer[6] expires
        Time - De_Timer[7] expires
        Time - De_Timer[8] expires
        Time - De_Timer[9] expires
        Time - De_Timer[10] expires
        Time - De_Timer[11] expires
        Time - De_Timer[12] expires
    Conditions
    Actions
        For each (Integer A) from 0 to 12, do (Actions)
            Loop - Actions
                Custom script:   exitwhen GetExpiredTimer() == udg_De_Timer[GetForLoopIndexA()]
        Set De_RandomPoint = (Random point in De_Region[(Integer A)])
        Set De_RandomPoint2 = (Random point in De_Region[(Integer A)])
        Set De_RandomPoint3 = (Random point in De_Region[(Integer A)])
        Unit Group - Pick every unit in De_UnitGroup[(Integer A)] and do (Actions)
            Loop - Actions
                Unit - Pause (Picked unit)
                Special Effect - Create a special effect attached to the origin of (Picked unit) using Environment\LargeBuildingFire\LargeBuildingFire1.mdl
                Unit - Cause De_Caster[(Integer A)] to damage (Picked unit), dealing 4.00 damage of attack type Spells and damage type Normal
                Special Effect - Destroy (Last created special effect)
                Unit - Unpause (Picked unit)
        Special Effect - Create a special effect at De_RandomPoint using Objects\Spawnmodels\Human\FragmentationShards\FragBoomSpawn.mdl
        Unit - Cause De_Caster[(Integer A)] to damage circular area after 0.00 seconds of radius 700.00 at De_CasterLoc[De_TempInteger], dealing 3.00 damage of attack type Spells and damage type Normal
        Special Effect - Destroy (Last created special effect)
        Special Effect - Create a special effect at De_RandomPoint2 using Objects\Spawnmodels\Demon\InfernalMeteor\InfernalMeteor.mdl
        Unit - Cause De_Caster[(Integer A)] to damage circular area after 0.00 seconds of radius 700.00 at De_CasterLoc[De_TempInteger], dealing 3.00 damage of attack type Spells and damage type Normal
        Special Effect - Destroy (Last created special effect)
        Special Effect - Create a special effect at De_RandomPoint3 using Objects\Spawnmodels\Other\NeutralBuildingExplosion\NeutralBuildingExplosion.mdl
        Unit - Cause De_Caster[(Integer A)] to damage circular area after 0.00 seconds of radius 700.00 at De_CasterLoc[De_TempInteger], dealing 3.00 damage of attack type Spells and damage type Normal
        Special Effect - Destroy (Last created special effect)
        Custom script:   call RemoveLocation(udg_De_RandomPoint)
        Custom script:   call RemoveLocation(udg_De_RandomPoint2)
        Custom script:   call RemoveLocation(udg_De_RandomPoint3)

WC3ScrnShot_011708_102846_02copy.jpg


WC3ScrnShot_011708_102844_01copy.jpg


WC3ScrnShot_011708_102857_03copy.jpg

Hope you like it.

New version update! Now MPI!
 

cr4xzZz

Also known as azwraith_ftL.
Reaction score
51
Damages everything? Well.. that can't be very nice :p
You need to destroy De_UnitGroup because it leaks. Move this
Set De_UnitGroup = (Units within 700.00 of De_CasterLoc matching (((Owner of (Matching unit)) is an enemy of (Owner of De_Caster)) Equal to True))

in the second trigger and in the end put call DestroyGroup(udg_DeUnitGroup)

EDIT: You don't need to set special effects into a variable and then destroy them. Just put Destroy (Last created special effect) after every effect and you're done! Like this:
Special Effect - Create a special effect at De_RandomPoint2 using Objects\Spawnmodels\Demon\InfernalMeteor\InfernalMeteor.mdl
Special Effect - Destroy (Last created special effect)
 

Vestras

Retired
Reaction score
248
Damages everything? Well.. that can't be very nice :p
You need to destroy De_UnitGroup because it leaks. Move this
Set De_UnitGroup = (Units within 700.00 of De_CasterLoc matching (((Owner of (Matching unit)) is an enemy of (Owner of De_Caster)) Equal to True))

in the second trigger and in the end put call DestroyGroup(udg_DeUnitGroup)

EDIT: You don't need to set special effects into a variable and then destroy them. Just put Destroy (Last created special effect) after every effect and you're done! Like this:
Special Effect - Create a special effect at De_RandomPoint2 using Objects\Spawnmodels\Demon\InfernalMeteor\InfernalMeteor.mdl
Special Effect - Destroy (Last created special effect)

They said it didn't leak.

in this thread
 

cr4xzZz

Also known as azwraith_ftL.
Reaction score
51
Well, I guess you can leave it this way... Anyway, you can get rid of the SFX variables because they aren't needed ;)
 

Quauhtli

I have the right to remain silent.
Reaction score
62
Powerful is with one L. (just letting you know)

Exactly how does the caster get self damage? (I didn't find anything (just overlooked though) so).
 

Tom Jones

N/A
Reaction score
437
You know that the Unit - Damage Area damages everything, including allies. A better way is to pick all units in the region, and then use Unit - Damage Target on picked unit.
 

Quauhtli

I have the right to remain silent.
Reaction score
62
Well it's a Desperate Explosion, perhaps he wanted it that way?
 

0zaru

Learning vJASS ;)
Reaction score
60
Also sometimes is bugged. When I used it and test it with one Damage_Show_System then i saw that the damage was the half of the dmg that it was suppoused to deal.
 

Vestras

Retired
Reaction score
248
Also sometimes is bugged. When I used it and test it with one Damage_Show_System then i saw that the damage was the half of the dmg that it was suppoused to deal.

Woot? That is very wierd.. Why?

Tom Jones>

I know. I wanted it.

Quauhtli>

Unit - Set life of De_Caster to (Real(De_Integer))
 

Tom Jones

N/A
Reaction score
437
Use arrays for each of your variables, and use the player number of the owning player as index. You can change your periodic event to timer expires, and then use a timer for each player instead.
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    The bots will show up as users online in the forum software but they do not show up in my stats tracking. I am sure there are bots in the stats but the way alot of the bots treat the site do not show up on the stats
  • Varine Varine:
    I want to build a filtration system for my 3d printer, and that shit is so much more complicated than I thought it would be
  • Varine Varine:
    Apparently ABS emits styrene particulates which can be like .2 micrometers, which idk if the VOC detectors I have can even catch that
  • Varine Varine:
    Anyway I need to get some of those sensors and two air pressure sensors installed before an after the filters, which I need to figure out how to calculate the necessary pressure for and I have yet to find anything that tells me how to actually do that, just the cfm ratings
  • Varine Varine:
    And then I have to set up an arduino board to read those sensors, which I also don't know very much about but I have a whole bunch of crash course things for that
  • Varine Varine:
    These sensors are also a lot more than I thought they would be. Like 5 to 10 each, idk why but I assumed they would be like 2 dollars
  • Varine Varine:
    Another issue I'm learning is that a lot of the air quality sensors don't work at very high ambient temperatures. I'm planning on heating this enclosure to like 60C or so, and that's the upper limit of their functionality
  • Varine Varine:
    Although I don't know if I need to actually actively heat it or just let the plate and hotend bring the ambient temp to whatever it will, but even then I need to figure out an exfiltration for hot air. I think I kind of know what to do but it's still fucking confusing
  • The Helper The Helper:
    Maybe you could find some of that information from AC tech - like how they detect freon and such
  • Varine Varine:
    That's mostly what I've been looking at
  • Varine Varine:
    I don't think I'm dealing with quite the same pressures though, at the very least its a significantly smaller system. For the time being I'm just going to put together a quick scrubby box though and hope it works good enough to not make my house toxic
  • Varine Varine:
    I mean I don't use this enough to pose any significant danger I don't think, but I would still rather not be throwing styrene all over the air
  • The Helper The Helper:
    New dessert added to recipes Southern Pecan Praline Cake https://www.thehelper.net/threads/recipe-southern-pecan-praline-cake.193555/
  • The Helper The Helper:
    Another bot invasion 493 members online most of them bots that do not show up on stats
  • Varine Varine:
    I'm looking at a solid 378 guests, but 3 members. Of which two are me and VSNES. The third is unlisted, which makes me think its a ghost.
    +1
  • The Helper The Helper:
    Some members choose invisibility mode
    +1
  • The Helper The Helper:
    I bitch about Xenforo sometimes but it really is full featured you just have to really know what you are doing to get the most out of it.
  • The Helper The Helper:
    It is just not easy to fix styles and customize but it definitely can be done
  • The Helper The Helper:
    I do know this - xenforo dropped the ball by not keeping the vbulletin reputation comments as a feature. The loss of the Reputation comments data when we switched to Xenforo really was the death knell for the site when it came to all the users that left. I know I missed it so much and I got way less interested in the site when that feature was gone and I run the site.
  • Blackveiled Blackveiled:
    People love rep, lol
    +1
  • The Helper The Helper:
    The recipe today is Sloppy Joe Casserole - one of my faves LOL https://www.thehelper.net/threads/sloppy-joe-casserole-with-manwich.193585/
  • The Helper The Helper:
    Decided to put up a healthier type recipe to mix it up - Honey Garlic Shrimp Stir-Fry https://www.thehelper.net/threads/recipe-honey-garlic-shrimp-stir-fry.193595/
  • The Helper The Helper:
    Here is another comfort food favorite - Million Dollar Casserole - https://www.thehelper.net/threads/recipe-million-dollar-casserole.193614/

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top