• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!

[Spell] I need Feedback is this is the best way to make this.

Status
Not open for further replies.
Level 7
Joined
Jan 22, 2013
Messages
293
I have came up with this spell for as a request. I would like to know if I have missed anything, I had to stop in the middle of it then resume it several hours later so I figured I'd post it to get some extra eyes to scope it.

The spell generally has two sets, One on cast another that detects. The entire thing is MUI so if you do not understand it, then you still wont understand it lol.

  • Fire Tricks
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to Fire Tricks [ Custom Spell ]
    • Actions
      • Set New_Que_Active = True
      • For each (Integer MUI) from 0 to 200, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • MUI_Que_Boolean[MUI] Equal to False
              • New_Que_Active Equal to True
            • Then - Actions
              • -------- The True/False Condition that lets the Loop grab only 1 open ofr use Integer Array. --------
              • Set New_Que_Active = False
              • Set Player_MUI[MUI] = (Owner of (Triggering unit))
              • -------- The True/False Condition that tells the loop Trigger if the this Integer is in use at this time. --------
              • Set MUI_Que_Boolean[MUI] = True
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Level of (Ability being cast) for (Triggering unit)) Equal to 1
                • Then - Actions
                  • -------- Blink Explosion Damage --------
                  • Set Damage_MUI[MUI] = 750.00
                  • -------- Dummy Explosion Damage --------
                  • Set Dummy_Damage_MUI[MUI] = 500.00
                • Else - Actions
              • -------- Grabs Casting Unit and adds it to the MUI Integer --------
              • Set Unit_MUI[MUI] = (Triggering unit)
              • -------- Grabs all the Leak Locations --------
              • Set LocationLeak1_MUI = (Position of (Triggering unit))
              • -------- Adds the Dummy to the MUI integer Then creates him --------
              • Unit - Create 1 Shadow image [Custom Dummy for Player_MUI[MUI] at LocationLeak1_MUI facing (Facing of Unit_MUI[MUI]) degrees
              • Set Dummy_MUI[MUI] = (Last created unit)
              • -------- Damage Location blinked at --------
              • Set LocationLeak3_MUI = (Target point of ability being cast)
              • Set UnitGroup_MUI[MUI] = (Units within 300.00 of LocationLeak2_MUI matching ((((Triggering unit) belongs to an enemy of Player_MUI[MUI]) Equal to True) and (((Triggering unit) is A structure) Not equal to True)))
              • Unit Group - Pick every unit in UnitGroup_MUI[MUI] and do (Actions)
                • Loop - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (Number of units in UnitGroup_MUI[MUI]) Greater than or equal to 1
                    • Then - Actions
                      • Unit - Cause Unit_MUI[MUI] to damage (Triggering unit), dealing Damage_MUI[MUI] damage of attack type Chaos and damage type Normal
                    • Else - Actions
              • Custom script: call RemoveLocation(udg_LocationLeak1_MUI)
              • Custom script: call DestroyGroup(udg_UnitGroup_MUI[udg_MUI])
              • Custom script: call RemoveLocation(udg_LocationLeak3_MUI)
              • Custom script: set udg_LocationLeak1_MUI = null
              • Custom script: set udg_UnitGroup_MUI[udg_MUI] = null
              • Custom script: set udg_LocationLeak3_MUI = null
            • Else - Actions
  • Dummy Sensoring
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • For each (Integer MUI) from 0 to 200, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • MUI_Que_Boolean[MUI] Equal to True
            • Then - Actions
              • Set LocationLeak2_MUI = (Position of Dummy_MUI[MUI])
              • Set UnitGroup_MUI[MUI] = (Units within 300.00 of LocationLeak2_MUI matching ((((Triggering unit) belongs to an enemy of Player_MUI[MUI]) Equal to True) and (((Triggering unit) is A structure) Not equal to True)))
              • Unit Group - Pick every unit in UnitGroup_MUI[MUI] and do (Actions)
                • Loop - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (Number of units in UnitGroup_MUI[MUI]) Greater than or equal to 1
                    • Then - Actions
                      • Special Effect - Create a special effect at LocationLeak2_MUI using Objects\Spawnmodels\Other\NeutralBuildingExplosion\NeutralBuildingExplosion.mdl
                      • Set Special_Effect_MUI[MUI] = (Last created special effect)
                      • Unit - Remove Dummy_MUI[MUI] from the game
                      • Unit - Cause Unit_MUI[MUI] to damage (Triggering unit), dealing Dummy_Damage_MUI[MUI] damage of attack type Chaos and damage type Normal
                    • Else - Actions
              • Special Effect - Destroy Special_Effect_MUI[MUI]
              • Custom script: call DestroyGroup(udg_UnitGroup_MUI[udg_MUI])
              • Custom script: set udg_UnitGroup_MUI[udg_MUI] = null
              • Custom script: call RemoveLocation(udg_LocationLeak2_MUI)
              • Custom script: set udg_LocationLeak2_MUI = null
              • Set MUI_Que_Boolean[MUI] = False
            • Else - Actions
If you find something I will give +rep for the aid.

While this is here I will be working on Anothers spell.
 
Last edited:
Level 7
Joined
Jan 22, 2013
Messages
293
why are u looping 201 times ? that doesnt make sense at all.
your setting the same unit Set Unit_MUI[MUI] = (Triggering unit)
201 times in a row ?

I am not setting him 201 times in a row read closer.

At the beginning only 1 time takes in all the triggers. Every time the spell is casted the 0-200 integers act like a storage that holds up to 200 executions of the spells that can be used on the map together at the same time.

The dummy shadows are left behind after each cast so the I have a Boolean that is true/false that runs to check to see if that integer storage is being used, if so it picks the closest number that is available then uses that.

The rest do absolutely nothing it just runs every time its casted. Now the Second trigger only checking for integers that are active, if they are it runs triggers on them, if not nothing happens.

Please read the trigger rather then parts of it please.
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
first u loop from 0 to 200. which is 201 instances

in the then block in the first trigger u do this
Set Unit_MUI[MUI] = (Triggering unit)
you are setting all 201 instances of Unit_MUI[0-200] to Triggering Unit.
then you set all 201 points to position of triggering unit
Set LocationLeak1_MUI = (Position of (Triggering unit))

Also i always read the whole thread. i dont read parts of it

This is also not MUI
 
Level 7
Joined
Jan 22, 2013
Messages
293
first u loop from 0 to 200. which is 201 instances

in the then block in the first trigger u do this
Set Unit_MUI[MUI] = (Triggering unit)
you are setting all 201 instances of Unit_MUI[0-200] to Triggering Unit.
then you set all 201 points to position of triggering unit
Set LocationLeak1_MUI = (Position of (Triggering unit))

Also i always read the whole thread. i dont read parts of it

The Then block turns one of the condition for the IF Block to False meaning it basically cancels out all other uses after the single cast.

If (All Conditions are True) then do (Then Actions) else do (Else Actions)
  • If - Conditions
  • MUI_Que_Boolean[MUI] Equal to False
  • New_Que_Active Equal to True
  • Then
  • set New_Que_Active Equal to false
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
i saw this Set MUI_Que_Boolean[MUI] = True and thought it was the same one.
You have a very strange way of doing this. it is also a lot more work than indexing and a lot less efficient.
You should look up some MUI guides and learn indexing. The way you do it is very inneficient.

It is MUI but only up to 201 units after that the spell will break.
 
Level 7
Joined
Jan 22, 2013
Messages
293
first u loop from 0 to 200. which is 201 instances

in the then block in the first trigger u do this
Set Unit_MUI[MUI] = (Triggering unit)
you are setting all 201 instances of Unit_MUI[0-200] to Triggering Unit.
then you set all 201 points to position of triggering unit
Set LocationLeak1_MUI = (Position of (Triggering unit))

Also i always read the whole thread. i dont read parts of it

This is also not MUI

Multiple Instance for for one line of trigger to work for a near unlimited about of casts while one is alreadly be preformed no?

Well the problem I'm having just now that I tested. I can spam it constantly. My issue is no damages are being dealt anywhere. Any Solutions to prevent me from making the same mistake later on?
 
Level 7
Joined
Jan 22, 2013
Messages
293
read what i said in post 6 lol

I did and I found this: http://www.hiveworkshop.com/forums/...279/mui-spells-using-artificial-waits-223315/

Anyway, I can fix the index easy, what I need to ensure is the damages are working. lol.

Don't you find it entertaining for me to brainstorm something and have it work yet I knew nothing of the proper index. yet it worked lol.

Anyway, I highly appreciate the conversation his led towards I can now make it in a way that produces way less "FPS reduce" now that it wont run an entire Loop integer set.

Unfortunately I can't give you Rep yet, because the forums told me I have to spread some around first lmao. So I owe you one.
 
Level 19
Joined
Feb 25, 2009
Messages
2,004
I don't think running 201 instances is efficient at all.
You can always use a secondary integer to declare amount of instances that are being run at the moment.

Also, there's no way to run the spell 201 times in the map, if you keep that way of triggering, you might want to reduce the loop to something like 10-20.
 
Level 7
Joined
Jan 22, 2013
Messages
293
I don't think running 201 instances is efficient at all.
You can always use a secondary integer to declare amount of instances that are being run at the moment.

Also, there's no way to run the spell 201 times in the map, if you keep that way of triggering, you might want to reduce the loop to something like 10-20.

I'm alreadly converting the Index to the proper use. No need to comment on the index part of it. I will be back with fix in a few
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
you can also do something like this if u want to make a wait in a trigger. Both ways are 100% MUI. This waits 10 seconds then damages unit again.
  • Untitled Trigger 001
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to mySpell
    • Actions
      • Custom script: local unit u1 = GetTriggerUnit()
      • Custom script: local unit u2 = GetSpellTargetUnit()
      • Wait 10.00 seconds
      • Custom script: set udg_caster = u1
      • Custom script: set udg_target = u2
      • Unit - Cause caster to damage target, dealing 500.00 damage of attack type Spells and damage type Normal
      • Custom script: set u1 = null
      • Custom script: set u2 = null
This one damages the target unit 10 more times after a 10 second wait
  • Untitled Trigger 001 Copy
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to mySpell
    • Actions
      • Custom script: local unit u1 = GetTriggerUnit()
      • Custom script: local unit u2 = GetSpellTargetUnit()
      • Wait 10.00 seconds
      • Custom script: set udg_caster = u1
      • Custom script: set udg_target = u2
      • For each (Integer tempInt) from 1 to 10, do (Actions)
        • Loop - Actions
          • Unit - Cause caster to damage target, dealing 500.00 damage of attack type Spells and damage type Normal
      • Custom script: set u1 = null
      • Custom script: set u2 = null
 
Level 7
Joined
Jan 22, 2013
Messages
293
you can also do something like this if u want to make a wait in a trigger. Both ways are 100% MUI. This waits 10 seconds then damages unit again.
  • Untitled Trigger 001
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to mySpell
    • Actions
      • Custom script: local unit u1 = GetTriggerUnit()
      • Custom script: local unit u2 = GetSpellTargetUnit()
      • Wait 10.00 seconds
      • Custom script: set udg_caster = u1
      • Custom script: set udg_target = u2
      • Unit - Cause caster to damage traget, dealing 500.00 damage of attack type Spells and damage type Normal
      • Custom script: set u1 = null
      • Custom script: set u2 = null
This one damages the target unit 10 more times after a 10 second wait
  • Untitled Trigger 001 Copy
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to mySpell
    • Actions
      • Custom script: local unit u1 = GetTriggerUnit()
      • Custom script: local unit u2 = GetSpellTargetUnit()
      • Wait 10.00 seconds
      • Custom script: set udg_caster = u1
      • Custom script: set udg_target = u2
      • For each (Integer tempInt) from 1 to 10, do (Actions)
        • Loop - Actions
          • Unit - Cause caster to damage traget, dealing 500.00 damage of attack type Spells and damage type Normal
      • Custom script: set u1 = null
      • Custom script: set u2 = null

you must not understand the spell.

The spell is a blink, You leave a Shadow image behind at location you casted the spell. You blink to a location and you set off a explosion dealing 750 damage where you blinked dealing damage. It leaves beyond this bastard of a shadow that needs to keep checking to see if an enemy unit comes in range of him then he explodes dealing 500 damage, while its waiting for that unit, it produces a problem with MUI Indexing, I need to ensure the index knows if they general index is in use for the detection intervals just waiting for these units to walk up to these shadows so they explode.

It can't just be a "wait" it needs to be a consistant along with MUI. It makes it rather annoying.

IF your trying to teach me something by beating around the bush I wont pick it up at all. you gotta show it. Then I learn it forever lol.
 
Level 7
Joined
Jan 22, 2013
Messages
293
ok then the way i posted wont work for this.

I know, that's why im like. The tutorials are pointless in this situation. Need creativity going on. The proper index field I can use, but I need a way to flush older ones and then go back and use them after that particular index is done its detection stage for the cloned image, Even then it has to WAIT till a unit comes into that range. so it has to have a constant detection as well. I picked it thinking it was a simple spell Oh I'd do this in like an hour tops since its so simple. This shit hit me in the face with a unexpected need of complex index.

Here is how the Branching must work, I will use hidden tags to open it like a branched out tree.

I must check to make sure the Loop is being used properly, the problem I have with searching for them is that I can't just keep doing [(Index) + 1] because then I can't check for the nearest ones available. Pushing me to use a Loop in the first and second MUI trigger.
This has to run then check to see if the consitant checking for that particular index number is running for the shadow image in that index number. Otherwise it looks for the next available index to use and that search loops

The Consistent checker I have constantly looking at every single index looking for a active Boolean to run pick units around the dummy unit to check for units near it. The Problem with that is these Loops make this spell rather fail triggering wise.


Read the above Hidden Tags before reading this. Oh wait to late you read this.

The overall situation is uncharted area for me, I need a solution so I can continue.
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
I know, that's why im like. The tutorials are pointless in this situation. Need creativity going on. The proper index field I can use, but I need a way to flush older ones and then go back and use them after that particular index is done its detection stage for the cloned image, Even then it has to WAIT till a unit comes into that range. so it has to have a constant detection as well. I picked it thinking it was a simple spell Oh I'd do this in like an hour tops since its so simple. This shit hit me in the face with a unexpected need of complex index

u can always use a hashtable. that would make it MUI without the use of indexing.
 
Level 7
Joined
Jan 22, 2013
Messages
293
u can always use a hashtable. that would make it MUI without the use of indexing.

Yeah well tutorials never seem to give you all the info one needs every time I have followed one someone pops up out of the blue and says "You can't do that, it does "this , this and this" that's fail triggering. well I'm only following the tutorial bro. Anyway I'm not taking that path again. to many un-answered issues. Could you explain and show me examples of it in the multiple instance use like you explain.
 
Just loop it for its max indexes. 200 is not enough,and 8192 is the max array size.
constant integer JASS_MAX_ARRAY_SIZE = 8192

Also,deathismyfriend,i would prefer indexing than hashtables,coz they are slower.Why? Saving,Loading,Saving,Loading,blah blah and so on,which is a lot of function calls,that makes the code slower,but look at indexing,just caches it in variables and voila.
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
Just loop it for its max indexes. 200 is not enough,and 8192 is the max array size.
constant integer JASS_MAX_ARRAY_SIZE = 8192

Also,deathismyfriend,i would prefer indexing than hashtables,coz they are slower.Why? Saving,Loading,Saving,Loading,blah blah and so on,which is a lot of function calls,that makes the code slower,but look at indexing,just caches it in variables and voila.

ik that hashtables are slower and i like indexing more. just forgot to mention that thanks.

off topic
@ almia
sweet new pic lol
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
What if you just add a Goblin Mine's AoE damage ability that activates on death and add it to the shadow image? No need of this stupid index at all in that case.

thats probably a good idea.

Hashtables fits on systems(excep Projectile,which needs speed) due to that they have infinite spaces(Table explained). Indexing are recommended for spells,even though it have 8192 max instances,but who cares,is there such that can reach this limit?

ya ik what u mean there i use Table a lot in my systems lol.
 
Level 7
Joined
Jan 22, 2013
Messages
293
After Several failed attempts, it became clear what I had to do was what I didn't want to do. that was to make 2 index's.

Here is the Successful and 100% working Trigger. I don't know if I got everything correct (leak wise) so please take a look. (also Mortar your idea didn't work so I gave you rep for something that was fail X.X)
  • Fire Tricks
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Fire Tricks [ Custom Spell ]
    • Actions
      • -------- Customize Configs (here is where you should set the damages according to the level of spell) --------
      • -------- You can put them in yourself since you never listed amount of levels. Or you can tell me the amount --------
      • Set Blink_Damage = 750.00
      • Set Blink_Explosion_AOE = 300.00
      • Set Dummy_Damage = 500.00
      • Set Sensor_And_Dummy_Bomb_AOE = 300.00
      • -------- End of Customization --------
      • Set MaxIndex1 = (MaxIndex1 + 1)
      • For each (Integer CurrentIndex1) from 1 to MaxIndex1, do (Actions)
        • Loop - Actions
          • Set StoreCaster[CurrentIndex1] = (Casting unit)
          • Set PointLeaks1[CurrentIndex1] = (Position of StoreCaster[CurrentIndex1])
          • Set StoreOwningPlayer[CurrentIndex1] = (Owner of StoreCaster[CurrentIndex1])
          • Unit - Create 1 Shadow image [Custom Dummy for StoreOwningPlayer[CurrentIndex1] at PointLeaks1[CurrentIndex1] facing (Facing of StoreCaster[CurrentIndex1]) degrees
          • Custom script: call RemoveLocation(udg_PointLeaks1[udg_CurrentIndex1])
          • Custom script: set udg_PointLeaks1[udg_CurrentIndex1] = null
          • -------- Traveling Data over to Second Trigger --------
          • Set MaxIndex2 = (MaxIndex2 + 1)
          • Set StoreDummy[MaxIndex2] = (Last created unit)
          • Game - Display to (All players) for 30.00 seconds the text: (Setting data to Max Index 2 = + (String(MaxIndex2)))
          • Set StoreCaster[MaxIndex2] = (Casting unit)
          • Set StoreOwningPlayer[MaxIndex2] = (Owner of StoreCaster[CurrentIndex1])
          • Set Index_is_in_use[MaxIndex2] = True
          • -------- Right after I clear out of anti_leak, I use it again to remove the leak from create unit. --------
          • Set PointLeaks1[CurrentIndex1] = (Position of (Last created unit))
          • Custom script: call RemoveLocation(udg_PointLeaks1[udg_CurrentIndex1])
          • Custom script: set udg_PointLeaks1[udg_CurrentIndex1] = null
          • -------- Right after I clear out two leaks I instantly use it for damaging units --------
          • Set PointLeaks1[CurrentIndex1] = (Target point of ability being cast)
          • Set Targets1[CurrentIndex1] = (Units within Blink_Explosion_AOE of PointLeaks1[CurrentIndex1])
          • Unit Group - Pick every unit in Targets1[CurrentIndex1] and do (Actions)
            • Loop - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • ((Picked unit) is A structure) Not equal to True
                  • ((Picked unit) is alive) Equal to True
                  • ((Picked unit) belongs to an enemy of StoreOwningPlayer[CurrentIndex1]) Equal to True
                • Then - Actions
                  • Unit Group - Add (Picked unit) to Victim1[CurrentIndex1]
                  • Unit Group - Pick every unit in Victim1[CurrentIndex1] and do (Unit - Cause StoreCaster[CurrentIndex1] to damage (Picked unit), dealing Blink_Damage damage of attack type Chaos and damage type Normal)
                  • Unit Group - Remove (Picked unit) from Victim1[CurrentIndex1]
                • Else - Actions
          • Custom script: call RemoveLocation(udg_PointLeaks1[udg_CurrentIndex1])
          • Custom script: set udg_PointLeaks1[udg_CurrentIndex1] = null
          • Custom script: call DestroyGroup(udg_Targets1[udg_CurrentIndex1])
          • Custom script: set udg_Targets1[udg_CurrentIndex1] = null
          • -------- Recycle Index --------
          • Set MaxIndex1 = (MaxIndex1 - 1)
          • Set CurrentIndex1 = (CurrentIndex1 - 1)
  • Dummy Tricks
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • For each (Integer CurrentIndex2) from 1 to MaxIndex2, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Index_is_in_use[CurrentIndex2] Equal to True
            • Then - Actions
              • Set PointLeaks2[CurrentIndex2] = (Position of StoreDummy[CurrentIndex2])
              • Set Targets2[CurrentIndex2] = (Units within Sensor_And_Dummy_Bomb_AOE of PointLeaks2[CurrentIndex2])
              • Unit Group - Pick every unit in Targets2[CurrentIndex2] and do (Actions)
                • Loop - Actions
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • ((Picked unit) is A structure) Not equal to True
                      • ((Picked unit) is alive) Equal to True
                      • ((Picked unit) belongs to an enemy of StoreOwningPlayer[CurrentIndex2]) Equal to True
                    • Then - Actions
                      • Special Effect - Create a special effect at PointLeaks2[CurrentIndex2] using Objects\Spawnmodels\Other\NeutralBuildingExplosion\NeutralBuildingExplosion.mdl
                      • Set SpecialEffect[CurrentIndex2] = (Last created special effect)
                      • Unit Group - Add (Picked unit) to Victim2[CurrentIndex2]
                      • Unit Group - Pick every unit in Victim2[CurrentIndex2] and do (Unit - Cause StoreCaster[CurrentIndex2] to damage (Picked unit), dealing Dummy_Damage damage of attack type Chaos and damage type Normal)
                      • Unit Group - Remove (Picked unit) from Victim2[CurrentIndex2]
                      • Special Effect - Destroy SpecialEffect[CurrentIndex2]
                      • Unit - Remove StoreDummy[CurrentIndex2] from the game
                      • Set Index_is_in_use[CurrentIndex2] = False
                    • Else - Actions
              • -------- Index Recycle --------
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • Index_is_in_use[CurrentIndex2] Equal to False
                • Then - Actions
                  • Set CurrentIndex2 = (CurrentIndex2 - 1)
                  • Set MaxIndex2 = (MaxIndex2 - 1)
                • Else - Actions
              • -------- Leak Destroying --------
              • Custom script: call DestroyGroup(udg_Targets2[udg_CurrentIndex2])
              • Custom script: call RemoveLocation(udg_PointLeaks2[udg_CurrentIndex2])
              • Custom script: set udg_Targets2[udg_CurrentIndex2] = null
              • Custom script: set udg_PointLeaks2[udg_CurrentIndex2] = null
            • Else - Actions
This has surely made me good on Indexing, I am sure some of you that have seen my past work will see a major improvement in my work from the feedback people give me.
 
Last edited:
Level 29
Joined
Oct 24, 2012
Messages
6,543
(also Mortar your idea didn't work so I gave you rep for something that was fail X.X)

ill review it now i just wanted to reply to this. This is something i always do i always give rep to anyone that tries to help. My way of thinking is even if there answer wasnt the correct one it may of lead you the correct way. Also its not like they had to take there time to try to help. This is your choice to give rep or not and im not trying to sway u either way but i believe this to be the right way to give rep.

A few things i see right off the bat is u dont need an arrayed point variable since it is only a tempPoint. also your create a unit in ur first trig but i dont see where u remove it / kill it.

Edit: i see were u store the unit now. Just as a note u should store them to the variable right after they are created.

Another thing to suggest is the indexing integers i would name them cIndexFireTrick1 and cIndexFireTrick2.
This way you dont accidently use this index in another spell. it keep it from getting overwritten.
 
Level 7
Joined
Jan 22, 2013
Messages
293
ill review it now i just wanted to reply to this. This is something i always do i always give rep to anyone that tries to help. My way of thinking is even if there answer wasnt the correct one it may of lead you the correct way. Also its not like they had to take there time to try to help. This is your choice to give rep or not and im not trying to sway u either way but i believe this to be the right way to give rep.

That makes a good amount of sense.


think of both triggers as one, they both treat eachother as one trigger sharing data even though they have 2 separate index's.

Anyway. The Remove/Kill created unit is in trigger 2. I chuck a bunch of data over to trigger 2 then use it there.

Edit: Massive improvement since the first time eh? lol.
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
That makes a good amount of sense.


think of both triggers as one, they both treat eachother as one trigger sharing data even though they have 2 separate index's.

Anyway. The Remove/Kill created unit is in trigger 2. I chuck a bunch of data over to trigger 2 then use it there.

i noticed this after look at the trigger above. lol i edited it as i was going. i use c for current and then use e for end that way the names stay short but also have a descriptive name.
 
Level 7
Joined
Jan 22, 2013
Messages
293
ya it was a very good improvement. i would change the things i suggested. especially setting the unit immediately after its created. The others are more for simplicity and to keep from using the same variable in another spell.

Alright, I will have to do that then re-upload the map. real fast. I make spells for people in the Spell Workshop in requests. sooo yeah lol. You just helped a-lot.
All of you helped a lot, improved my skills dramatically from this thread. +rep
 
Status
Not open for further replies.
Top