How to make this spell work?

Crimson

Member
Reaction score
3
So, I'm trying to make an MUI meteor spell. I've finished the trigger but the spell won't work as if the unit was only casting the dummy spell. Here's the trigger. Can anyone see what's wrong with it? I've checked everything else. The heroes have the right skill, dummy units have a model...etc.

Trigger:
  • Meteorain Setup
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Meteorain
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • MR_Index Less than 1000
        • Then - Actions
          • Set MR_Index = (MR_Index + 1)
        • Else - Actions
          • Set MR_Index = 0
      • Set MR_caster[MR_Index] = (Triggering unit)
      • Set MR_loc[0] = (Target point of ability being cast)
      • Set MR_Rect[MR_Index] = (Region centered at MR_loc[0] with size (400.00, 400.00))
      • Set MR_damage[MR_Index] = (120.00 + ((Real((Level of Meteorain for MR_caster[MR_Index]))) x (Real((Strength of MR_caster[MR_Index] (Include bonuses))))))
      • Trigger - Turn on Meteorain Periodic <gen>

Trigger:
  • Meteorain Periodic
    • Events
      • Time - Every 0.30 seconds of game time
    • Conditions
    • Actions
      • Set MR_integer[MR_Index] = (MR_integer[MR_Index] + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • MR_integer[MR_Index] Equal to (Level of Meteorain for MR_caster[MR_Index])
        • Then - Actions
          • Custom script: call RemoveLocation(udg_MR_loc[0])
          • Custom script: call RemoveLocation(udg_MR_loc[1])
          • Custom script: call RemoveLocation(udg_MR_loc[2])
          • Trigger - Turn off (This trigger)
        • Else - Actions
          • Set MR_loc[1] = (Random point in MR_Rect[MR_Index])
          • Unit - Create 1 Meteors for (Owner of MR_caster[MR_Index]) at MR_loc[1] facing (Random angle) degrees
          • Set MR_Meteor[MR_Index] = (Last created unit)
          • Set MR_loc[2] = (Position of MR_Meteor[MR_Index])
          • Unit - Add a 3.00 second Generic expiration timer to MR_Meteor[MR_Index]
          • Special Effect - Create a special effect at MR_loc[2] using Objects\Spawnmodels\Other\NeutralBuildingExplosion\NeutralBuildingExplosion.mdl
          • Special Effect - Destroy (Last created special effect)
          • Set MR_Group[MR_Index] = (Units within 150.00 of MR_loc[2] matching (((Matching unit) belongs to an enemy of (Owner of MR_caster[MR_Index])) Equal to True))
          • Custom script: set bj_wantDestroyGroup = true
          • Unit Group - Pick every unit in MR_Group[MR_Index] and do (Actions)
            • Loop - Actions
              • Unit - Cause MR_caster[MR_Index] to damage (Picked unit), dealing MR_damage[MR_Index] damage of attack type Chaos and damage type Normal

WE also gives me errors when trying to save it saying that MR_Index is an undeclared variable so I couldn't use the usual custom scripts to some clear stuff up, making me resort to using that bj_wantDestroyGroup. Can anyone tell me how to write this trigger better? Oh and sorry if the spoiler tags don't work.
 

Happy

Well-Known Member
Reaction score
71
i think using call DestroyGroup(udg_MR_Group[udg_MR_Index]) works...just put it after the every group action and it should be it.
 

Crimson

Member
Reaction score
3
That's the first thing I tried but it seems that every custom script that has MR_Index gives an error because MR_Index is an 'undefined variable'. I also tried testing the map without the custom scripts but the trigger still won't work.
 

NeuroToxin

New Member
Reaction score
46
I think your meaning to do a loop at the top of the every .3 seconds thing, from 1 to MRIndex, because MRIndex will simply increase and there wont be anything in it.
 

Crimson

Member
Reaction score
3
Okay...I'll try doing that but will that fix the errors that MR_Index causes? You know, the one that comes after trying to save a map? I can't write any custom scripts referring to it, making the spell leak.
 

Crimson

Member
Reaction score
3
Wait...actually the whole problem is more serious than I thought. None of the triggers are working in the map now. So what could the problem be?
 

Shadow

TH.net Regular
Reaction score
23
if its says your trigger have errors it usually disables all your triggers i think. try disabling your spell triggers and see if it will save
 

NeuroToxin

New Member
Reaction score
46
No thats not it. If you have multiple arrays over 1000ish size, the map cannot initialize all that space, and it won't be running any triggers, reduce the array sizes.
 

Grobak

New Member
Reaction score
1
This may be stupid but the event of the first trigger should be : unit begins casting an ability?
 

NeuroToxin

New Member
Reaction score
46
Nonono, that is before any mana has been taken or anything, it should be Unit Starts the Effect of An Ability
 

Crimson

Member
Reaction score
3
No thats not it. If you have multiple arrays over 1000ish size, the map cannot initialize all that space, and it won't be running any triggers, reduce the array sizes.

Oh, I think that's what I did. So when trying to make an MUI spell, what's the best size for the arrays?
 

Crimson

Member
Reaction score
3
Thanks and I'll ask again to make it clear. I should not set all the arrays of an MUI spell to the maximum of 8912, right? 200-500 should be plenty good enough, yes?
 

NeuroToxin

New Member
Reaction score
46
Yes. As that gives enough time to recycle too. and 8192 just is too much for the game to initialize.
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Ghan Ghan:
    Howdy
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?
  • The Helper The Helper:
    Happy Thursday!
    +1
  • Varine Varine:
    Crazy how much 3d printing has come in the last few years. Sad that it's not as easily modifiable though
  • Varine Varine:
    I bought an Ender 3 during the pandemic and tinkered with it all the time. Just bought a Sovol, not as easy. I'm trying to make it use a different nozzle because I have a fuck ton of Volcanos, and they use what is basically a modified volcano that is just a smidge longer, and almost every part on this thing needs to be redone to make it work
  • Varine Varine:
    Luckily I have a 3d printer for that, I guess. But it's ridiculous. The regular volcanos are 21mm, these Sovol versions are about 23.5mm
  • Varine Varine:
    So, 2.5mm longer. But the thing that measures the bed is about 1.5mm above the nozzle, so if I swap it with a volcano then I'm 1mm behind it. So cool, new bracket to swap that, but THEN the fan shroud to direct air at the part is ALSO going to be .5mm to low, and so I need to redo that, but by doing that it is a little bit off where it should be blowing and it's throwing it at the heating block instead of the part, and fuck man
  • Varine Varine:
    I didn't realize they designed this entire thing to NOT be modded. I would have just got a fucking Bambu if I knew that, the whole point was I could fuck with this. And no one else makes shit for Sovol so I have to go through them, and they have... interesting pricing models. So I have a new extruder altogether that I'm taking apart and going to just design a whole new one to use my nozzles. Dumb design.
  • Varine Varine:
    Can't just buy a new heatblock, you need to get a whole hotend - so block, heater cartridge, thermistor, heatbreak, and nozzle. And they put this fucking paste in there so I can't take the thermistor or cartridge out with any ease, that's 30 dollars. Or you can get the whole extrudor with the direct driver AND that heatblock for like 50, but you still can't get any of it to come apart
  • Varine Varine:
    Partsbuilt has individual parts I found but they're expensive. I think I can get bits swapped around and make this work with generic shit though
  • Ghan Ghan:
    Heard Houston got hit pretty bad by storms last night. Hope all is well with TH.
  • The Helper The Helper:
    Power back on finally - all is good here no damage
    +2
  • V-SNES V-SNES:
    Happy Friday!
    +1

      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