- Joined
- Apr 3, 2010
- Messages
- 1,101
Its also for Gui users and contains many GUI functions new to WE and also uses some natives instead of B.j So basically its an advanced Gui system bundled in with the Tileset map size and Doodad maximum expansion. Its not just limited to Vjass n jass users
Anyhow the system is this ...
Triggers
Hastable 6 item recipes
Hastable 5 item recipes
Hastable 4 item recipes
Hastable 3 item recipes
Hastable 2 item recipes
Hastable 1 item recipes
Hastable 6 item recipes
-Time-Elapsed game time is 0.01
Actions Hashtable - Create a Hashtable
Set Hashtablearray[0] = Last created hashtable
Hashtable - Save Itemrecipe1 as 0 of 0 in Hashtablearray[0]
Hashtable - Save item1req as 0 of 1 in Hashtablearray[0]
Hashtable - Save item2req as 0 of 2 in Hashtablearray[0]
Hashtable - Save item3req as 0 of 3 in Hashtablearray[0]
Hashtable - Save item4req as 0 of 4 in Hashtablearray[0]
Hashtable - Save item5req as 0 of 5 in Hashtablearray[0]
Hashtable - Save item6req as 0 of 6 in Hashtablearray[0]
Hashtable - Save Itemcreated as 0 of 7 in Hashtablearray[0]
Hashtable Item recipe for 5 items
Copy but use Hashtable[1] And omit Item req 6
Hashtable Item recipe for 4 items Copy and omit Itemreq4
etc etc
Alternatively you can put these all into 1 trigger. This would be better and use A Comment to seperate each recipe and A Tripple comment for each Type -- 6 5 4 3 2 and 1 Item amount for recipe.
Just for neatness and readabillity
Item creation trigger:
Unit - A unit uses an item (All Recipes should be tomes)
Condition: Item class of item being manipulated equal to powerup
Action: Comment: Resetting Checks
Do Mutiple actions for each integer A from 0 to 5 do actioins
Set item check onof Integer A = False
Do mutiple action for each integer A from 0 -7
Set count Integer A = 0
Set itemcheckcount=0
Comment: To Decide which hashtable to use and to set recipe and creation
Comment: ------------------------------------------------------------
Do mutiple actions for each integer A 0 to 10
If Item being manipulated Equal to Load integer A of 0 in hashtable array 0
Set count 0 - integer A
Set Count 1 = 0
Set itemarray 0 = Load integer A of 7 in Hashtable[0]
Repeat for each Hashtabe so
Do mutiple actions for each integer A 0 to 10
If Item being manipulated Equal to Load integer A of 0 in hashtable array 1
Set count 0 - integer A
Set Count 1 = 0
Set itemarray 0 = Load integer A of 7 in Hashtable[1]
Comment: After repeats for setting the item amount in Recipe Do
Comment: Core loops
Do mutiple Action for each integer a From 1 to 6
Set itemarray[Integer A] = Item carried by triggering unit in slot integer A
Do Action for each Integer A from 1 - 6
IF itemcheckonof[0] = flase
And Itemarray Integer A Equal Load count 0 of 1 in hashtable array Count 0
Then Set itemcheckcount = itemcheckcount+1
Set itemcheckonof = true
Set count 2 = integer A
Else Do nothing
Repeat this function for each Point so
Change -- Load count 0 of 1 hashtablearray count - to load count 0 of 2
change Itemcheckonof [0] tp [1]
and Count[2] -[3]
Then the next would be
of 3
[2]
[4]
Etc
Do this all the way up to 6 so this checks for each item in inven fi it is there
Comment: Now to check item count is = and if so remove each item as it is picked
If Itemcheckcount = 6-Count[1]
Then Do Mutiple actions for each integer a from 2-7
If Count integer A greater than 0
Then Item remove Item carried by triggering unit in slot Count integer A
Else Do nothing
-----Now to create item000----
Add the item type Load count[0] of 7 hashtablearray [count 1] to pool and give it a chance 100% to be chosen
Give triggering unit a get random item from item pool in slot 1
Reset your own pool for random items
----End----
Trigger comments
Item creation:
Tomes=powerups
If no recipe made money is returned
Recipes cant be carried but may be bought with full inventory.
Configure the loop number with how many recipes you have
This is not MUI
i dont think.
Also i think slot 1 contain one of the binding items or be free im not sure if wc3. Checks it automatically and puts into nearest slot
To create mui make every variable shown a seperate variable with an array of 11 and Do PIckedplayer owner of trigger unit -1

As at the moment it uses arrays :O
trigger comments for Hashtable:
You will want to change the string saves to Item handle saves. You can do this by creating the item then removing it. Or by picking items in a region ^^. Im not sure how else.
Or string
Triggers
Hastable 6 item recipes
Hastable 5 item recipes
Hastable 4 item recipes
Hastable 3 item recipes
Hastable 2 item recipes
Hastable 1 item recipes
Hastable 6 item recipes
-Time-Elapsed game time is 0.01
Actions Hashtable - Create a Hashtable
Set Hashtablearray[0] = Last created hashtable
Hashtable - Save Itemrecipe1 as 0 of 0 in Hashtablearray[0]
Hashtable - Save item1req as 0 of 1 in Hashtablearray[0]
Hashtable - Save item2req as 0 of 2 in Hashtablearray[0]
Hashtable - Save item3req as 0 of 3 in Hashtablearray[0]
Hashtable - Save item4req as 0 of 4 in Hashtablearray[0]
Hashtable - Save item5req as 0 of 5 in Hashtablearray[0]
Hashtable - Save item6req as 0 of 6 in Hashtablearray[0]
Hashtable - Save Itemcreated as 0 of 7 in Hashtablearray[0]
Hashtable Item recipe for 5 items
Copy but use Hashtable[1] And omit Item req 6
Hashtable Item recipe for 4 items Copy and omit Itemreq4
etc etc
Alternatively you can put these all into 1 trigger. This would be better and use A Comment to seperate each recipe and A Tripple comment for each Type -- 6 5 4 3 2 and 1 Item amount for recipe.
Just for neatness and readabillity
Item creation trigger:
Unit - A unit uses an item (All Recipes should be tomes)
Condition: Item class of item being manipulated equal to powerup
Action: Comment: Resetting Checks
Do Mutiple actions for each integer A from 0 to 5 do actioins
Set item check onof Integer A = False
Do mutiple action for each integer A from 0 -7
Set count Integer A = 0
Set itemcheckcount=0
Comment: To Decide which hashtable to use and to set recipe and creation
Comment: ------------------------------------------------------------
Do mutiple actions for each integer A 0 to 10
If Item being manipulated Equal to Load integer A of 0 in hashtable array 0
Set count 0 - integer A
Set Count 1 = 0
Set itemarray 0 = Load integer A of 7 in Hashtable[0]
Repeat for each Hashtabe so
Do mutiple actions for each integer A 0 to 10
If Item being manipulated Equal to Load integer A of 0 in hashtable array 1
Set count 0 - integer A
Set Count 1 = 0
Set itemarray 0 = Load integer A of 7 in Hashtable[1]
Comment: After repeats for setting the item amount in Recipe Do
Comment: Core loops
Do mutiple Action for each integer a From 1 to 6
Set itemarray[Integer A] = Item carried by triggering unit in slot integer A
Do Action for each Integer A from 1 - 6
IF itemcheckonof[0] = flase
And Itemarray Integer A Equal Load count 0 of 1 in hashtable array Count 0
Then Set itemcheckcount = itemcheckcount+1
Set itemcheckonof = true
Set count 2 = integer A
Else Do nothing
Repeat this function for each Point so
Change -- Load count 0 of 1 hashtablearray count - to load count 0 of 2
change Itemcheckonof [0] tp [1]
and Count[2] -[3]
Then the next would be
of 3
[2]
[4]
Etc
Do this all the way up to 6 so this checks for each item in inven fi it is there
Comment: Now to check item count is = and if so remove each item as it is picked
If Itemcheckcount = 6-Count[1]
Then Do Mutiple actions for each integer a from 2-7
If Count integer A greater than 0
Then Item remove Item carried by triggering unit in slot Count integer A
Else Do nothing
-----Now to create item000----
Add the item type Load count[0] of 7 hashtablearray [count 1] to pool and give it a chance 100% to be chosen
Give triggering unit a get random item from item pool in slot 1
Reset your own pool for random items
----End----
Trigger comments
Item creation:
Tomes=powerups
If no recipe made money is returned
Recipes cant be carried but may be bought with full inventory.
Configure the loop number with how many recipes you have
This is not MUI
Also i think slot 1 contain one of the binding items or be free im not sure if wc3. Checks it automatically and puts into nearest slot
To create mui make every variable shown a seperate variable with an array of 11 and Do PIckedplayer owner of trigger unit -1
As at the moment it uses arrays :O
trigger comments for Hashtable:
You will want to change the string saves to Item handle saves. You can do this by creating the item then removing it. Or by picking items in a region ^^. Im not sure how else.
Or string
Last edited: