• 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.

[Trigger] Need help with item combining

Status
Not open for further replies.
Level 11
Joined
Sep 12, 2008
Messages
657
Okay, so i made this code.. its suposed to cheak if you have all 6 items.. and i want it in 1 trigger :/ and quick..
if you have all items, its suposed to give a spell,
i made an extra trigger, that each 1 second, it clears screen, and write the "solarian set amount" value.. it allways showed 0.. and each time you wore 4 items out of the 5, it gave the ability.. instead of 5 items out of 5..


  • Solarian set Aquire
    • Events
      • Unit - A unit Acquires an item
    • Conditions
    • Actions
      • Set SolarianSetAquirer = (Hero manipulating item)
      • For each (Integer A) from 1 to 6, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Any (Conditions) are true
                • Conditions
                  • (Item-type of (Item carried by SolarianSetAquirer in slot (Integer A))) Equal to Solarian Hood
                  • (Item-type of (Item carried by SolarianSetAquirer in slot (Integer A))) Equal to Solarian Pants
                  • (Item-type of (Item carried by SolarianSetAquirer in slot (Integer A))) Equal to Solarian Ring 2
                  • (Item-type of (Item carried by SolarianSetAquirer in slot (Integer A))) Equal to Solarian Ring 1
                  • (Item-type of (Item carried by SolarianSetAquirer in slot (Integer A))) Equal to Solarian Amulet
            • Then - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • SolarianSetAmount[(Player number of (Owner of SolarianSetAquirer))] Greater than or equal to 9
                • Then - Actions
                  • Unit - Add Solarian Set Abilities to SolarianSetAquirer
                • Else - Actions
                  • Set SolarianSetAmount[(Player number of (Owner of SolarianSetAquirer))] = (SolarianSetAmount[(Player number of (Owner of SolarianSetAquirer))] + 1)
            • Else - Actions

Hope you can help :/
 
Level 37
Joined
Mar 6, 2006
Messages
9,243
Here's one way:

  • Untitled Trigger 018
    • Events
      • Unit - A unit Acquires an item
    • Conditions
      • (Number of items carried by (Triggering unit)) Equal to 6
      • Or - Any (Conditions) are true
        • Conditions
          • (Item-type of (Item being manipulated)) Equal to Claws of Attack +15
          • (Item-type of (Item being manipulated)) Equal to Crown of Kings +5
          • (Item-type of (Item being manipulated)) Equal to Kelen's Dagger of Escape
          • (Item-type of (Item being manipulated)) Equal to Mask of Death
          • (Item-type of (Item being manipulated)) Equal to Orb of Frost
          • (Item-type of (Item being manipulated)) Equal to Ring of Protection +5
    • Actions
      • Set Temp_Unit_1 = (Triggering unit)
      • Set Temp_Integer_1 = 0
      • For each (Integer A) from 1 to 6, do (Actions)
        • Loop - Actions
          • Set Temp_Item_Array[(Integer A)] = No item
      • Set Temp_Item_Array[1] = (Item carried by Temp_Unit_1 of type Claws of Attack +15)
      • Set Temp_Item_Array[2] = (Item carried by Temp_Unit_1 of type Crown of Kings +5)
      • Set Temp_Item_Array[3] = (Item carried by Temp_Unit_1 of type Kelen's Dagger of Escape)
      • Set Temp_Item_Array[4] = (Item carried by Temp_Unit_1 of type Mask of Death)
      • Set Temp_Item_Array[5] = (Item carried by Temp_Unit_1 of type Orb of Frost)
      • Set Temp_Item_Array[6] = (Item carried by Temp_Unit_1 of type Ring of Protection +5)
      • For each (Integer B) from 1 to 6, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Temp_Item_Array[(Integer B)] Not equal to No item
            • Then - Actions
              • Set Temp_Integer_1 = (Temp_Integer_1 + 1)
            • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Temp_Integer_1 Equal to 6
        • Then - Actions
          • Game - Display to (All players) the text: The hero has all si...
        • Else - Actions
  • Untitled Trigger 018
    • Events
      • Player - Player 1 (Red) skips a cinematic sequence
    • Conditions
    • Actions
      • Set Temp_Unit_1 = (Random unit from (Units currently selected by Player 1 (Red)))
      • Set Temp_Integer_1 = 0
      • For each (Integer A) from 1 to 6, do (Actions)
        • Loop - Actions
          • Set Temp_Item_Array[(Integer A)] = No item
      • Set Temp_Item_Array[1] = (Item carried by Temp_Unit_1 of type Claws of Attack +15)
      • Set Temp_Item_Array[2] = (Item carried by Temp_Unit_1 of type Crown of Kings +5)
      • Set Temp_Item_Array[3] = (Item carried by Temp_Unit_1 of type Kelen's Dagger of Escape)
      • Set Temp_Item_Array[4] = (Item carried by Temp_Unit_1 of type Mask of Death)
      • Set Temp_Item_Array[5] = (Item carried by Temp_Unit_1 of type Orb of Frost)
      • Set Temp_Item_Array[6] = (Item carried by Temp_Unit_1 of type Ring of Protection +5)
      • For each (Integer B) from 1 to 6, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Temp_Item_Array[(Integer B)] Not equal to No item
            • Then - Actions
              • Set Temp_Integer_1 = (Temp_Integer_1 + 1)
            • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Temp_Integer_1 Equal to 6
        • Then - Actions
          • Game - Display to (All players) the text: The hero has all si...
        • Else - Actions
 
Last edited:
Level 11
Joined
Sep 12, 2008
Messages
657
Gah.. will take time to convert into my trigger.. but thanks :p

edit:

kk the option maker sayd works.. but how do i remove the spell now? :D to just remove it each time over and over or..?
 
Last edited:
Status
Not open for further replies.
Top