• 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.
  • 💡 We're thrilled to announce that our upcoming texturing contest is in the works, and we're eager to hear your suggestions! Please take this opportunity to share your ideas in this theme discussion thread for the Texturing Contest #34!
  • 🏆 Hive's 7th HD Modeling Contest: Icecrown Creature is now open! The frozen wastes of Icecrown are home to some of Azeroth’s most terrifying and resilient creatures. For this contest, your challenge is to design and model a HD 3D monster that embodies the cold, undead, and sinister essence of Icecrown! 📅 Submissions close on April 13, 2025. Don't miss this opportunity to let your creativity shine! Enter now and show us your frozen masterpiece! 🔗 Click here to enter!

Randomize Ownership

Status
Not open for further replies.
Level 5
Joined
Jul 25, 2008
Messages
155
Hello, is it possible to randomize and assign ownership to buildings with GUI? I am making a Risk-like map, and I wish to randomize the ownership of the buildings at the start, but havn't fixed it out yet, and saw a GUI-jass trigger which I didn't understand anything from, and thought it would be easier with a GUI trigger for it, would appreciate some help :wink:
 
Level 5
Joined
Jul 25, 2008
Messages
155
How do i make this random integer then?
  • check Moria
    • Events
    • Conditions
      • (Owner of Balins Tomb [Moria] 0196 <gen>) Equal to (Player((Integer A)))
      • (Owner of Khazad Dum [Moria] 0186 <gen>) Equal to (Player((Integer A)))
      • (Owner of The Hall of Moria [Moria] 0182 <gen>) Equal to (Player((Integer A)))
    • Actions
      • Set Gold_received[(Integer A)] = (Gold_received[(Integer A)] + 4)
      • Unit - Create 1 Dwarf Kings Guard for (Player((Integer A))) at (Center of Moria <gen>) facing Default building facing degrees
      • Game - Display to (Player group((Player((Integer A))))) the text: You control Moria
  • Say hintseriador
    • Events
      • Player - Player 1 (Red) types a chat message containing -hintseriador as An exact match
      • Player - Player 2 (Blue) types a chat message containing -hintseriador as An exact match
      • Player - Player 3 (Teal) types a chat message containing -hintseriador as An exact match
      • Player - Player 4 (Purple) types a chat message containing -hintseriador as An exact match
      • Player - Player 5 (Yellow) types a chat message containing -hintseriador as An exact match
      • Player - Player 6 (Orange) types a chat message containing -hintseriador as An exact match
      • Player - Player 7 (Green) types a chat message containing -hintseriador as An exact match
      • Player - Player 8 (Pink) types a chat message containing -hintseriador as An exact match
      • Player - Player 9 (Gray) types a chat message containing -hintseriador as An exact match
      • Player - Player 10 (Light Blue) types a chat message containing -hintseriador as An exact match
      • Player - Player 11 (Dark Green) types a chat message containing -hintseriador as An exact match
      • Player - Player 12 (Brown) types a chat message containing -hintseriador as An exact match
    • Conditions
    • Actions
      • Game - Display to (All allies of (Triggering player)) for 30.00 seconds the text: When you control Er...
 
Last edited:
Status
Not open for further replies.
Top