• 💀 Happy Halloween! 💀 It's time to vote for the best terrain! Check out the entries to Hive's HD Terrain Contest #2 - Vampire Folklore.❗️Poll closes on November 14, 2023. 🔗Click here to cast your vote!
  • 🏆 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!
  • 🏆 HD Level Design Contest #1 is OPEN! Contestants must create a maze with at least one entry point, and at least one exit point. The map should be made in HD mode, and should not be openable in SD. Only custom models from Hive's HD model and texture sections are allowed. The only exceptions are DNC models and omnilights. This is mainly a visual and design oriented contest, not technical. The UI and video walkthrough rules are there to give everyone an equal shot at victory by standardizing how viewers see the terrain. 🔗Click here to enter!

[Trigger] How to set up game modes

Status
Not open for further replies.
Level 9
Joined
Nov 24, 2007
Messages
229
I was just wondering how to set up game modes right as the game starts. It should be like......

(Everyone finishes loading) Please vote on a game mode. (A list pops up for all players that says "Short mode - 15 minutes" "Medium mode - 30 minutes" "Long mode - 45 minutes" and "Tournament mode - 1 hour")

Can anyone help me out please? Thank you in advance :)

Rep for help will be given of course :D
 
Level 8
Joined
Feb 15, 2009
Messages
463
you have to let a dialog pop up for every player with your 3 categories and whenever 1 is kliked destroy that dialog for that player and let the categorie specific integerglobal grow by 1 (set integer = integer +1)
after all voted u compare and then go for if then else and activate the mode u want
 
Level 9
Joined
Nov 24, 2007
Messages
229
you have to let a dialog pop up for every player with your 3 categories and whenever 1 is kliked destroy that dialog for that player and let the categorie specific integerglobal grow by 1 (set integer = integer +1)
after all voted u compare and then go for if then else and activate the mode u want

uuummmm could you show me what the trigger would look like? I'm kinda confused sry XD
 
Level 8
Joined
Feb 15, 2009
Messages
463
no i cant coz i want u to learn =D
search for dialog in the trigger section do what i told u with them

and u need 3 integer variables

and 3 detecting triggers like:
  • event : a dialogbutton is clicked
  • cond: clicked dialogbutton == easy
  • actions:
  • set udg_IntegerEasy = udg_IntegerEasy + 1
then if the vote time is over u need something like :

  • event: elapsed game time = 60.
  • cond:---
  • actions
  • if udg_IntegerEasy > udg_IntegerMedium then
    • RunTrigger(Your easy Setup Trigger)
  • else
    • RunTrigger(Your medium Setup Trigger)
this is just an example for 2 modes figure out how to do for three =D its just mathematics =D

GL to you i give you most tips how to do but you also have to learn something =D
 
Level 16
Joined
Mar 3, 2006
Messages
1,564
Shit i can't get it to work right T_T

I'll give you something about dialogues I have made it long ago


  • -------- Hotkeys --------
  • Set Hotkey[1] = 65
  • Set Hotkey[2] = 82
  • Set Hotkey[3] = 78
  • Set Hotkey[4] = 83
  • Set Hotkey[5] = 80
  • Set Hotkey[6] = 84
  • Set Hotkey[7] = 85
  • Set Hotkey[8] = 69
  • Set Hotkey[9] = 68
  • For each (Integer A) from 1 to 9, do (Actions)
    • Loop - Actions
      • Custom script: set udg_Class[GetForLoopIndexA()] = DialogAddButtonWithHotkeyBJ(udg_ClassSelectionDialog,udg_Label[GetForLoopIndexA()],udg_Hotkey[GetForLoopIndexA()])
  • Wait 0.10 seconds
  • Dialog - Change the title of ClassSelectionDialog to Choose your Hero Cl...
  • Dialog - Show ClassSelectionDialog for AP1_Player
  • Class Selected
    • Events
      • Dialog - A dialog button is clicked for ClassSelectionDialog
    • Conditions
    • Actions
      • For each (Integer A) from 1 to 9, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Clicked dialog button) Equal to Class[(Integer A)]
            • Then - Actions
              • Set aHeroIndex = (Integer A)
              • Set HeroClass = ClassName[(Integer A)]
              • Set HeroProperName = ClassProperName[(Integer A)]
              • Unit - Create 1 ClassTypeUnit[(Integer A)] for AP1_Player at (Center of AP1 HeroStart <gen>) facing Default building facing degrees
            • Else - Actions
      • Set PlayerHero = (Last created unit)


forget about anything isn't related to the dialogue it was belonging to my old project which was deemed to failure.
 
Status
Not open for further replies.
Top