Spell is Causing Fatal Error

AdventCore

New Member
Reaction score
2
Why is my spell causing a fatal error? Warcraft III only crashes when you cast the ability on enemy units however it doesn't fatal when I just cast it on empty terrain.

Here is the Trigger:

Code:
Flames of Ruin
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Flames of Ruin 
    Actions
        Set CPoint = (Position of (Casting unit))
        For each (Integer A) from 1 to 12, do (Actions)
            Loop - Actions
                Set TempPoint = (CPoint offset by 256.00 towards (30.00 x (Real((Integer A)))) degrees)
                Unit - Create 1 Dummy for (Owner of (Triggering unit)) at TempPoint facing Default building facing degrees
                Unit - Add Flames of Ruin (Hidden) to (Last created unit)
                Unit - Set level of Flames of Ruin (Hidden) for (Last created unit) to (Level of Flames of Ruin  for (Casting unit))
                Unit - Order (Last created unit) to Human Blood Mage - Flame Strike TempPoint
                Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
                Custom script:   call RemoveLocation (udg_TempPoint)
        Custom script:   call RemoveLocation (udg_CPoint)

Or if you want the map it's attached below.

All I want to know is how I can edit what I have to stop it from causing fatal errors rather than creating the spell from scratch I've tried it before but no way works properly. This is the closest I have gotten so far and I'd rather not scrap it all to find out it doesn't work (It's happened multiple times). This is what the spell is supposed to look like:

jg3595.jpg


This is the fatal:

2r6e82e.jpg


Thanks in advance.
 

Attachments

  • Pyromancer.w3x
    18.5 KB · Views: 177

wraithseeker

Tired.
Reaction score
122
I'm not sure but you should remove the leaks at the end of the trigger and not inside the loop, try that and tell me if it works.
 

Cheesy

some fucker
Reaction score
95
Move
Trigger:
  • Custom script: call RemoveLocation (udg_TempPoint)
outside of the loop.
 

Cookiemaster

New Member
Reaction score
36
Custom script: call RemoveLocation (udg_TempPoint)
Should be in the loop because the variable is also create in the loop. (12x, if you move the script out the loop it would memory leak.)




Do the dummy units have the "Flames of Ruin" ability by default? (This could be causing it.)
 

AdventCore

New Member
Reaction score
2
Yes that's why I put it in the loop in the first place ;) The dummy doesn't have it by default. Maybe you should take a look around the map it's in the first post. The map is entirely devoted to that hero but I've only manged to start that spell so it can't be interference from any of the other triggers.

EDIT: I've changed the trigger a bit.

Code:
Flames of Ruin
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Flames of Ruin 
    Actions
        Set CPoint = (Position of (Casting unit))
        For each (Integer A) from 1 to 10, do (Actions)
            Loop - Actions
                Set TempPoint = (CPoint offset by 256.00 towards (36.00 x (Real((Integer A)))) degrees)
                Unit - Create 1 Dummy for (Owner of (Triggering unit)) at TempPoint facing Default building facing degrees
                Unit - Add Flames of Ruin (Hidden) to (Last created unit)
                Unit - Set level of Flames of Ruin (Hidden) for (Last created unit) to (Level of Flames of Ruin  for (Casting unit))
                Unit - Order (Last created unit) to Human Blood Mage - Flame Strike TempPoint
                Unit - Add a 5.00 second Generic expiration timer to (Last created unit)
                Custom script:   call RemoveLocation (udg_TempPoint)
        Custom script:   call RemoveLocation (udg_CPoint)
 

eXirrah

New Member
Reaction score
51
Ok so here is what is causing the crash. As i told you you put too many buffs on the units. Just remove the buffs of Flame Ruin (hidden) and the map should work just fine....
 

AdventCore

New Member
Reaction score
2
Ok so here is what is causing the crash. As i told you you put too many buffs on the units. Just remove the buffs of Flame Ruin (hidden) and the map should work just fine....

Well you may have said it but not in those words. I just have trouble understanding what you are saying.

EDIT: I only have one buff on Flames of Ruin (Hidden) and that is the Flame Strike buff :)
EDIT 2: However, I DO have the Flame Strike buff and the Stunned (Paused) buff on my War Stomp edited Flames of Ruin. By removing the Flame Strike buff I got it working. That's what I mean by clarify. Thanks anyway.
 

Akolyt0r

New Member
Reaction score
33
i experimented with the map, and when i set the AoE-range of flames of ruin to 0 it didnt crash ...seems like some bug with thunderclap and flamestrike 0.o

EDIT: exirrah was somehow right remove the flamestrike fuff on "Flames of ruin (NOT hidden)"
 

eXirrah

New Member
Reaction score
51
Well you may have said it but not in those words. I just have trouble understanding what you are saying.

EDIT: I only have one buff on Flames of Ruin (Hidden) and that is the Flame Strike buff :)
EDIT 2: However, I DO have the Flame Strike buff and the Stunned (Paused) buff on my War Stomp edited Flames of Ruin. By removing the Flame Strike buff I got it working. That's what I mean by clarify. Thanks anyway.

Well in my last post I said that it is wrong to put many times the same buff to the same unit. Seems like I was right. But in your case I have to spend 10-15 minutes testing the map you uploaded to determine that this is the problem. I might have made some mistakes in my explanations which caused confusion, but after all i'm a human being and it is in human nature to make mistakes :).
 

Cookiemaster

New Member
Reaction score
36
Apparently, the fact that they are flamestriking temppoint crashes the game.

Even by removing the loop, and adding a wait before casting, it crashes.


Yet, changing:
Set TempPoint = (CPoint offset by 256.00 towards (36.00 x (Real((Integer A)))) degrees)

to:
Set TempPoint = (CPoint offset by 1.00 towards (36.00 x (Real((Integer A)))) degrees)

Makes it no longer crash the game.

wtfisthisshit.
 

eXirrah

New Member
Reaction score
51
Like I said it's the buff that causes the crash not the distance between cast point and the point where the dummyes should appear. Probably it worked for you cause the peasants are outside the range of the dummyes spell and don't get the buff.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top