This works. Put in an appropriate array size, based on what you believe will be a maximum. If the array size is exceeded, the array will be automatically expanded to accommodate it. (Expanding an array in-game is inefficient, but this works, and you shouldn't exceed 50... you can have 200 or 500 as a preset, and it will work just fine too... avoiding expanding the array).
Mob, I'm a 13 year old in 7th grade and I can do JASS loops and local variables...Looks interesting though, so I'll probably download and take a look..
-checking for areas being pathable is only accessible in JASS
-locals are only accessable through JASS
-the only possible loop in GUI sucks.
PS. this took about 10s to write, if you want more examples, ask
I already addressed the issue of locals. You can work around them.
I'm not sure which loop you are talking about (please be more specific when you refer to loops).
I asked for examples that are more like "create this multicastable skill", or something like that (can be more complicated). Not a list of features not offered in the normal editor!
The point I am trying to prove is that ALMOST ANYTHING can be done in the normal editor that can be done in Jass (it may take a little more work in the normal editor, but CAN be done).
Please quit it with the ignorant crap, though. Read what I have to ask, fully. I have asked you, and you said it takes you very little time.
The only one thing I think was valid that you said is pathable areas. Otherwise, please give me some valid examples... (I would offer to create a skill as a challenge, but I am lazy... so you can challenge me with creating a skill without Jass... just don't be unreasonable).
That's all i wanted to know. Oh ya, and I'm working on a spell for my second map for a masochist hero. Basicly what it is is he deals 200 damage to himself and creats a blood effect and deals 10 damage for each unit within 200 range of him to each unit within that area, but when i use it, it only does the damage to him.
you can never work around JASS, it will always be a low-born mimic. Arrays are not the solution
If this is true, could you please give me three different, non-similar situations in which Jass is the ONLY solution (where one cannot use the normal editor). I will probably get shot down, but I will take a challenge...
You don't need Jass... If you don't know Jass, you can work around Jass (if you're good enough) without any problems.
actually, it happens to be that you are wrong, and Rising_Duck is right( hi rising_dusk, btw i gave up on that damn flame strike thing )
you can never work around JASS, it will always be a low-born mimic. Arrays are not the solution.
And third- What the fuck are locals?
ask about locals after you have ALOT more experience. Alot of people know what they are, but there are few who know how to use them.
Locals are the same as in Object-Oriented programming. Variables defined within a function that are only accessible through that function ( exeption of KaTTaNa's Local Handle Vars system )
Ya i got that, I read everything you said, and I understand that you can do almost anything in the editor. I was actually just wondering what locals were. And I made it so that the spell cant be cast on himself(exept the damage).
There is no workaround to using locals. It can be almost MUI, but if you do have maybe an army all casting this at once, eventually the arrays will get overwritten.
This could also be very easily put into an (Integer A) action, and reduce a great amount of your triggering, and make it a lot better.
You really need to have read what I said. I really hate it when people give a quick comment, correcting what they think I was pointing out!
I was saying that practically anything can be done in the normal editor that can be done in Jass. This does not mean you can do locals. This means you can WORK AROUND needing locals, where you use certain lines of code. This does not mean you can use the same functions as you are offered in Jass, this means you can WORK AROUND using these functions, in order to achieve the same goal. If done properly, the way you do it in the normal editor will be almost just as efficient (as in not being laggy) as using Jass.
Wait, first of all, i think i fixed that ad you probably dled the wrong version, because i just tested it and used it like 7 times and it worked- Seconde, using the (Integer A) thing doest work for this because they're at diferent places (im sure it actually does but i dont get it yet) And third- What the fuck are locals?
Each time this trigger is run it leaks 30 times.... you really need to clean this up.
Point with offset leaks twice each (well since you used the starting location as loc, it only leaks once in your trigger, but loc leaks.)
> You don't need Jass... If you don't know Jass, you can work around Jass (if you're good enough) without any problems.
There is no workaround to using locals. It can be almost MUI, but if you do have maybe an army all casting this at once, eventually the arrays will get overwritten.
This could also be very easily put into an (Integer A) action, and reduce a great amount of your triggering, and make it a lot better.
Ok, i can tell that your very experienced and that you probably got skeelz, so thank you. The problem is i have no fucking clue how to use the "Do actions for each integer A" or whatever that was. And for the multiple conditions, i realize that it is alot easier to do the other thing, and i didn't know about that before. I'll try and fix the bugs and re-submit it.
One bug that PurplePoot pointed out was that the caster can be affected by the spell. This spell also affects allied units. You can do a simple "pick every unit in units within 300 of target point of ability being cast and do if-then-else, and then for conditions put in the conditions for the units you want to be affected). You also want to change your event to "Unit starts the effect of an ability", rather than a specific event for that pre-defined hero. Under the conditions, it is far more easily read and changed if you select "And, multiple conditions", rather than your "And" function where you can't drag and drop conditions. You can also fix some of your triggering up by doing a "For each integer A" loop, adding in a temporary real/integer (that increases in increments of 30), and create the summons based on that. Another thing you did was you defined at the very start "picked unit" as something, which I have no idea why (it does nothing).
Now, It is quite easy to fix a problem (similar to your example). For example:
Let's say a unit casts an ability. That unit is now defined as "bob", and is paused. There is a five second polled wait, and "bob" will then be unpaused. Another unit casts the same ability, which makes that unit become defined as "bob", and that unit is paused. Now, the first unit that cast the ability will not be unpaused, because it is no longer "bob".
The fix is simple (can be done one of many ways): You can choose to have "bob" as an array of size 12, where 12 is the number of possible players in the game. When the unit casts the ability, you define the unit as "bob[player number of triggering/casting unit]". Then, five seconds later, the trigger will unpause that same "bob[player number of triggering/casting unit]". This fix works to allow multiple players to have the same one hero. Now, if you want this to work in an unlimited multi-castable situation, where you can have 500 units from any player(s) casting the same spell (being defined as bob), you will want to do this:
(you will need 3 variables: two arrays of integers (default value of 0), and one array for a unit)
(The trigger above is completely multi-castable, and the arrays are of size 50... you can make the arrays the size you wish, depending on how many spells you think will be cast all in one time)
anything using variables that is not coded in JASS with locals will interrupt anything else that uses those variables, causing screwed up bugs
ex.
Pause ( bob ) // where bob is a variable unit
wait 5 seconds
unpause ( bob )
now, if this was ran again in 5 seconds with a different bob, bob would be unpaused when the old bob should have been, and the old bob will never be unpaused.
MobKing said that with Jass you can do anything easily, if you know how. This is true. Jass takes time to learn, but once you know it... it is pretty easy.
@MobKing:
You can do a lot in the normal editor that you can do in Jass. In fact, I haven't found many important things that can be done in Jass that can't be done in the editor (though, arguably, there are some very useful Jass functions that can reduce lag more).
Anyways, personally I don't like this skill (needs some debugging, and maybe a little more work). The idea is cool, though.
I've used the editor, and haven't done any Jass, and I've been able to recreate/make whatever I want. I haven't found anything that I couldn't do in the normal editor (being efficient and just fine). The only functions in Jass I really want to know are how to account for "unit comes within range of", where that unit is one of your variables that you have set in game (in the editor, to use "unit has come withing range of", the unit must be pre-defined... as in set down in the editor... ya...)
And BTW i didn't make this with JASS. It's with triggers so i cant really compare what we do because you can do anything with jass easily if you know how to read it. (which i dont) But for triggers i think it's pretty good, and I've only been doing WE for like 4 months.
Cast it on yourself. you will be paused and turned invuln. as soon as the spell ends you are ordered to recast it same place. this loops forever
anyways, when you said that you do requests ( in the other spell ) do you take challenges? if so, make a 100% multiinstanceable spell that spins to a point ( BM model ) and damages units along the way. the unit should still be able to do stuff while in it. Btw, i made one already, and i would like to compare
( oh yeah, thats the one in the third row called Whirlwind )