• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[Trigger] Items wont sell!!!

Status
Not open for further replies.
Level 2
Joined
Aug 23, 2008
Messages
6
Hey I am new to the forum and I am working on a map callled Ultimate Footmen Special Edition (the unreleased version of ultimate footmen that was believed to have dissapeared two years ago)

During AR (All Random) mode I cannot sell items. Here is the trigger:
  • ModePick
    • Events
      • Dialog - A dialog button is clicked for ModePick
    • Conditions
    • Actions
      • -------- FIX --------
      • Game - Force Player 1 (Red) to press the key A
      • Set Boolean = True
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to AllRandom
        • Then - Actions
          • Player Group - Pick every player in PlayersPlaying and do (Actions)
            • Loop - Actions
              • Set BuyingPlayer = (Picked player)
              • Player - Set (Picked player) Current gold to (((Picked player) Current gold) - 1700)
              • Unit - Create 1 RANDOM_HERO_ARRAY[(Random integer number between 1 and NUM_HEROES)] for BuyingPlayer at (BuyingPlayer start location) facing Default building facing degrees
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • Hero[(Player number of (Owner of (Last created unit)))] Equal to No unit
                • Then - Actions
                  • Set Hero[(Player number of (Owner of (Last created unit)))] = (Last created unit)
                • Else - Actions
              • Hero - Create Scroll of Town portal and give it to (Last created unit)
              • Hero - Create Amulet of Power and give it to (Last created unit)
              • Hero - Create Boots of Speed and give it to (Last created unit)
              • Unit - Remove (Sold unit) from the game
          • Set TempPoint = (Position of Random Tavern 0017 <gen>)
          • Player Group - Pick every player in PlayersPlaying and do (Actions)
            • Loop - Actions
              • Unit - Create 1 Wisp for (Picked player) at TempPoint facing Default building facing degrees
          • Custom script: call RemoveLocation(udg_TempPoint)
          • Game - Display to PlayersPlaying the text: ALL RANDOM MODE HAS...
        • Else - Actions
          • Set TempPoint = (Position of Random Tavern 0017 <gen>)
          • Player Group - Pick every player in PlayersPlaying and do (Actions)
            • Loop - Actions
              • Unit - Create 1 Wisp for (Picked player) at TempPoint facing Default building facing degrees
          • Custom script: call DestroyForce(udg_TempForce)
      • Custom script: set udg_TempPoint = null
      • Custom script: call DestroyTrigger( GetTriggeringTrigger() )
Variables:
Players playing-Player Group-Empty Player Group
Buying player-Player- -none-
TempPoint-point - -none-
Random hero Array-unit type array(30)- -none-
NUM_Heroes-integer-20


The problem: Whenever I click on a shop to sell an item, nothing basically happens. I can click the item on the show but nothing will happen.

A friend suggested that I make a separate trigger that will let me sell items. Can someone please help me make one? I have tried many sell item triggers but they did not work.
 
Last edited by a moderator:

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,198
I do not see any reason why the above trigger should not let you sell items. Make sure you can sell items to the shop when the above trigger is not run. Also try dropping and picking the item back up again as it could be a dumb bug.

Also make sure your shop has the right abilities, just because it is a shop does not mean you can sell to it unless it has the abilities letting you.
 
Level 2
Joined
Aug 23, 2008
Messages
6
I tried dropping and picking up and there is absolutely NO triggers in the map relating to items at all. This bug is indeed a mystery. When I do AP mode (all pick) I can sell items.
 
Level 2
Joined
Aug 23, 2008
Messages
6
It doesnt really do anything except if you press A it will auto All random, but you are right, I can try removing that.

getting rid of the Press A did nothing. Does anyone know an alternative trigger I could possible write?
 
Last edited by a moderator:
Level 9
Joined
Jun 7, 2008
Messages
440
Be patient with it. You have to Disable/Enable every part of the trigger. Not just :
  • Actions
    • Game - Force Player 1 (Red) to press the key A
As well, there may be a conflicting trigger, or as DSG said, the shop itself might not be able to accept the item. (Doesn't have the right abilities). If you still get the problem perhaps consider uploading your map so one of these fine gentlemen can take a look.
 
Last edited:
Status
Not open for further replies.
Top