• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Triggering Help...

Status
Not open for further replies.
Level 2
Joined
Jul 5, 2005
Messages
16
Well, I am creating a map, well, i´m not giving its name, but its an hero arena with no tomes...Cause tomes sux...in my opinion..

Well i want to know the following things:

How do\When do I use the Integer A/B and for what?

Intergers Array are used to store more than one "option"/"Number"/"value"...if no, what does it do?

Can I make Heroes/Units casts custom spells with triggers?? Like, I created the Hell Beam. And I want it to cast on a target or area, how do I make him cast...

Well, I want to create a Multiboard/Leaderboard that stores the NAme of the Player, How many enemies heroes he killed, how many times he died and if he is alive... I use Multiboard for that?? Or Leaderboard??And how do I do that?? (I know how to use leaderboards, but not too much...)

Can Someone please give me a hand???
 
Level 12
Joined
Apr 29, 2005
Messages
999
Integer A/B sounds like the functions "For each integer A do actions" is that what you mean? If so then this is used for loops. The loop will be executed as many times as the given integer.

Interger arrays... do you mean what it does if it is not an array? Then it stores just one single vaule.

About casting spells, yes just use the function "Issue order target" and choose the order depending on which ability you spell is based on.
 
Level 13
Joined
Jul 4, 2005
Messages
1,064
You can also use JASS functions to be sure you order order (it sounds stupid, i know :)) using right order string:

For "Issue order targeting a unit":
Use "Custom Script" action and type "call IssueTargetOrderBJ( udg_x, "z", udg_y )" as custom script, where x is ordered unit and y is target of an order, and z is an order string.

For "Issue order targeting a point":
As above, but type "call IssuePointOrderLocBJ( udg_x, "z", GetRectCenter(gg_rct_y) )", where x is ordered unit, y is a region (GetRectCenter -> Center of region()), and z is an order string.

For "Issue order with no target":
As above, but type "call IssueImmediateOrderBJ( udg_x, "z" )", where x is ordered unit and z is an order string.

But if you are, as I see, beginning triggerer, you should not use JASS for this moment.

If you want to use multicolumn table, you must use multiboard. It is very similar to trigger to leaderboard, but of course there are some differences.

First of all, you must know how many rows and cols you want to have in your board. If you know this, use "Multiboard - Create a multiboard with x columns and y rows, titled z". z is a title of your board (it is on the top of the multiboard), just type there "Player Stats" or sth else.
Then, you should assign it to a variable. Use "Set Variable" action (it should look like: Set x = (Last created multiboard)), but first you must create new variable of type multiboard.

Now some explains of multiboard functions:
To change or set text of a cell, use "Set text for m item in column x, row y to z".
To set the width of a cell, use "Set the width for m item in coulmn x, row y to z% of total screen width". z is an real-type variable.
To show/hide text or icon for item, use "Set display style for m item in column x, row y to Show/Hide text and Show/Hide icons".
To chcange color and transparency, use "Set the color for m item in coumn x, row y to (r%, g%, b%) with z% transparency". r, g, b, and z are real-type variables. r = red, g = green, b = blue.
If you want to set icons for items, use "Set the icon for m item in column x, roz y to ReplaceableTextures\CommandButtons\z.blp". z is an icon.

To show/hide your board in game, use "Multiboard - Show/Hide" action.
To maximize/minimize it, use "Multiboard - Minimize/Maximize.

If you want to show integer values in board cells (number of kills - stored in integer), you must use conversion action (Conversion - Convert Integer To String): "Multiboard - Set the text for m item in column x, row y to (String(iPlayer1Kills))".

In all above examples m is your multiboard.

I hope i helped you. :)

PS Oh, I forgot about Integer A/Integer B you asked.

Well, if you use "For" loop in your trigger, in most cases you need these vars to know which repeat of loop it is. I'll explain it using example:

We have, e.g., unit-type array. You want to assign to all items of this array the same unit type. You just need to create "For each integer A do multiple actions" action: For each integer from 1 to 10 do (Actions), and to "Loop - actions" section add action "Set iUnitTypeArray[(Integer A)] = Footman". (Integer A) var shows which repeat loop is doing.

I'm not sure i explained it, but i tried :p
 
Level 13
Joined
Jul 4, 2005
Messages
1,064
Of course, but in these actions you cannot specify order string, just an action. If you are not sure which order points which action, you can use above scripts or search for order strings in object editor (which is of course easier).

But I like to have everything clear and understandable in my trigers. "Why the **** i added here Night Elf - Mountain Giant - Taunt", if I want to cast my custom ability? [of course if JASS can be clear and understandable :p]
 
Level 2
Joined
Jul 5, 2005
Messages
16
Then...

There's an option in world editor, in unit editing, the "Can Flee - True/False" - What does this do?

I think this is a nooob question, but, i think its the last one, well, how do I "lock" the races for the players, and where do I change the name of them like, I would like to change the name of Human to Demon, and I don't want that the players change it.. Pls..explain me...
 
Level 6
Joined
Mar 18, 2005
Messages
153
as for the "can't flee" im not sure but it might be an option for the a.i. to retreat a unit if it's low on hp: as far as i know it doesnt concern human players at all.

to "lock" the race just go in scenario - force properties. activate "use custom forces" and "fixed player settings". nobody will be allowed to change his race now (unless u set his race to "selectable" of course)

i never tried to change the basic names for races but you should find something in advanced - game interface. use "use custom game interface" and search for the names of the races to be replaced.
 
Level 2
Joined
Jul 5, 2005
Messages
16
Thx

Well thx man...I´m happy now!! "Laughs"...

Well, If I have problens with another thing I edit this post....thx to yu people...
 
Status
Not open for further replies.
Top