• 0.961077844311377

    posted a message on [Terrain/Doodads] General new editor questions

    For the dependency, it depends. Usually only "Void (Mod)" can be fine. If you notice that you want doodads that are taken in picture but does not appear in your list when searching for them it might be because you need "Void (Campaign)". The Nova ops dependency can be interesting as well as it contains quite a couple nice looking doodads. The warcraft 3 mod is not necessairy except if you wish to use stuff from that game, but there is way enough to explore within the sc2 doodads and they are usually looking better than the Wc3 arts.

     

    About bridges, there are some doodads that can do just that and have pathing on them, but it can be tricky to place between 2 cliffs and can sometimes have some issues near the edges where a unit would look like falling far down and then come back up while moving across or entering it. Note as well there is no multi level pathing in sc2. You cannot have a bridge over another bridge for example, or passing under a bridge.

     

    There are different way of creating a bridge.

    1. Using doodads. 

    Pro: Easy to setup, looks great

    Con: Changing cliff heigh can be buggy and require painting pathing, a bridge above lowest ground level will not work great, not all doodads has pathing on them (although you can use one of the new doodads that is a plane with pathing so any sort of doodads can look like a bridge even a fallen tree or clouds)

    (Picture 1)

     

    2. Using terrain and hide cells.

    Pro: Works great whatever the cliff heigh

    Con: Trickier to setup, must hide cells and thus must hide the holes that it creates in the wall with other doodads, the doodads used can have footprint that you must remove in the data, it's much harder to make it look good.

    (Picture 2)

     

    3. Using terrain and textures.

    Pro: Easy to setup, efficient, looks great

    Con: You can see the cliff's wall, you can always hide it behind other doodads or try to place something to make it look black... Up to you.

    (Picture 3)

     

    After that it depends how much time you want to invest, what you want to do, what you consider great / good looking, and you can trick around by using water, fog, and other stuff like that to hide parts of the terrain that looks bad. (Picture 4)

    Posted in: Miscellaneous Development
  • 0.96551724137931

    posted a message on Can anyone make 3 triggers or 1 of them for me pls?

    Most people already have their own creations and won't do the other's ideas for them. People will help you learn and achieve your goals but not do it for you. Take a chair, sit and read through tutorials and stuff and you will be able to use the editor like everyone does.

    Posted in: Triggers
  • 0.963343108504399

    posted a message on How to create a faction customization screen?

    With this example with the trigger Game Initialization you can then pick eatch player and create their unit based on the race they choosed (the variable "Player Has Choosed")

     

    Feel free to PM me if you need so. You can also write back here and hopefully I'll get the notice. Dialogs is one part in the triggers that I'm very familiar with, except for custom dialogs appearance. But I guess at that point it would be easy to learn.

    Posted in: Triggers
  • 0.962962962962963

    posted a message on How to create a faction customization screen?

    I made one example of how you could do it. There are probably better ways, more efficient, etc. But it still gives you a first glimpse and can improve it as you go.

     

    Map example:

    https://ufile.io/cuhi3

    Posted in: Triggers
  • 0.963289280469897

    posted a message on How to create a faction customization screen?

    I'll elaborate a bit.

    The variable Player has voted would be the number of players for your map.

     

    So now, you have a new triggers, let's call it "Player choosing". As event you would have, dialog item used, as condition which dialog item was used (the button).

     

    In the actions, you would have a set variable for "Player has voted [triggering player]" == true.

     

    Then something along the lines of a For eatch int from 1 to (your number of players). (You could add a local variable for temporary counting, say "Votes")

    If Player has voted [int] == true

    Then set variable votes +1

    Else (nothing)

     

    Then another if then else:

    If number of active players == Votes (which means all active players voted)

    Then do the actions to start the game and stop the timer.

     

    So everytime a player votes, it will cycle through the array and see if everyone voted. It probably not "the most efficient way" but its not a big enough trigger to have any noticeable lags or issues. It's not trying to cycle through thousands of stuff you know...

     

    Is that better?

    Posted in: Triggers
  • 0.962686567164179

    posted a message on How to create a faction customization screen?

    It's kind of tricky to know why the default units spawn without seeing the triggers.

     

    I want to point out though that in the trigger you show here there is:

    • Show "User Interface" for All Players
      • and right after
    • Show "Last created dialog" for All Players
      • which refers exacly to the same dialog because last created dialog is what you set to "User Interface"

    You could simply keep one of those two and it should still work fine.

    Posted in: Triggers
  • 0.962630792227205

    posted a message on How to create a faction customization screen?

    1: If something is created, it means you might still have on map initialization the actions that creates the starting structures for all players (you know the default triggers you can see when making a new map) Then, if nothing appears other than your dialogs to pick a faction / race, you create the unit for it when voting is finish.

     

    2: There are many ways of doing this, the examples I give might not be the "optimal" ones, but ones that can work. There are always better or different ways of doing thing based on your needs. To make what you wish here you need at least:

     

    • Some sort of Timer. Can be the default one that can be found in the action list about timers or you can make your own using dialogs and dialog items Label and variables and some basic mathematics such as
      • Set X = 30
        • Repeat forever: (Note: Could also be repeat X number of times)
          • If: X > 30
          • Then: set the dialog item text to X
          •            wait 1 sec
          •            set variable X -1. 
          • Else: Timer is over.
    • A condition that checks if all players voted when a player votes. So the last player that votes will make the game starts. Using variable, like an Boolean (True/False)  Array "Player has voted". When a player votes it sets that player to true. Then you run a loop to check if eatch value is an active player (to prevent leavers) and if it's set to true. Then this means all players voted and the trigger can continue on making the game start.
    • About the end of the timer, you check if eatch player is an active player, and if it has voted to true, if not, you can do a simple local variable integer that you can do "Set variable random integer between X and Y" based on the number of races you have. Then you assign that race based on the random int.

    Note:

    1. You might enconter some minor bugs. For example: make sure that if all players votes and the game starts, to stop the timer, otherwise it will keep going down and spawn once again the starting structures.
    2. You might want to have an action that disables the triggers about winning/losing conditions for example if a player has no building end game. Since during voting in the beginning no players have structure it would end right there.

    You will most likely go through some stupid / annoying bugs just like anyone ;) If you need a more specefic example using the editor just ask. But I think you might be able to understand the idea. Hopefully my explainations are clear enough.

     

    Note: Are you on discord? I'm Fenix there. https://www.sc2mapster.com/forums/general/general-chat/184298-sc2mapster-discord

     

    Posted in: Triggers
  • 0.962518740629685

    posted a message on How to create a faction customization screen?

    Are you sure the Set variable is After the create button action? The variable itself is fine, it just has to be dialog item which is correct here.

    Posted in: Triggers
  • 0.962574850299401

    posted a message on How to create a faction customization screen?

    You must make sure that you first create the dialog or dialog item and only then set the variable to last created dialog or dialog item (or any action at all like showing it; the dialog must be created first). Dialog item like images are not necessarily needed to be set as a variable. Variables are there mostly to be able to track what is happening with what specefic dialog. For example it's very usefull to set a button as a variable, but not an image or a label (text). If you hide the dialog containing dialog items, they all get hide, so no need to hide all of them individually.

     

     

    So first, create the "Dialog". Set it's variable. Then do any action on it like hiding its background, changing scale, etc. Then create your dialog item like an image, label, etc. and only if needed (if you need to keep track of it, say if you want to change the image, or the text, or the values of the dialog item, you have to save it as a variable, if you don't need to keep track of it for futur changes, you can just create it and leave it there all fine. When the time comes to destroy the "Dialog" all the dialog items it contain will be deleted as well.

     

    Then create your button and set a variable to it (after your created it). Then your other trigger will be able to work because the condition will have a valid reference of what is "Amon Zerg[1]".

     

    The use of array is to prevent having many many variables for the same kind of stuff. For example, say you want a variable that changes based on "is player alive". (for whatever "is alive" mean like still having structure or whatever).

     

    The long way would be variables:

    • Is player 1 alive
    • Is player 2 alive
    • Is player 3 alive...

    And using array for this woudl be:

    • Is player alive [integer]

    Where integer is from 0 to the number you set the size of the array. Then you can use stuff like:

     

    For eatch Int from 1 to 8:

    If: Is player alive [Int] == true

    Then: this player is alive

    Else: this player is dead

     

    Instead of having to check eatch variable individually.

     

    Maybe you would not have to use array in your situation although, you said you have 15 different faction, so you could use an array for that, like variable integer with array size 15: "Faction [15]" (depending on what you want to do of course). You could also create what is called a "Preset" which basicly changes an integer into text, kind of.

     

    You could create a Preset and add a value for eatch faction with their name. 

    Then when you want to get the race picked as an integer, you can choose "preset" and find the preset you created. For you visually it will be the text, for the editor it gives an integer.

    Posted in: Triggers
  • 0.963018867924528

    posted a message on How to create a faction customization screen?

    Hey, Dialogs work like this:

     

    First you have the "Dialog" which is a big container. What it contains are "Dialog Item". If you create a new dialog you have to make sure to "Show/Hide Dialog" to show it which is what you are missing. You can also hide the background of the "Dialog" to only show what it contains.

     

    Second you have to create "Dialog Item" and also save a variable like the dialog but as a "Dialog Item" variable. This will allow to track click Events and add a condition to know which dialog item was clicked.

     

    Third, when creating dialog and dialog items the size, offset, etc. numbers are in pixels. So for your example, your dialog's scale is 500 pixels by 400 pixels. You can copy paste dialog items you created, like buttons, but remember to change the offset or it will be created behind the other button you copied.

     

    Here is an example: 

     

     

     

    A more advanced way that would save you time is by using variable position when creating your dialogs. It's a bit more complicated and you have to use what is called "Array" where you can find by clicking on your variable then checking the Array box and giving it a size.

     

     

    That gives you this:

     

     

    Then you can do whatever with it by adding a condition to your Event checking for which button got clicked. Here I did a simple thing that cycle through the variable and check if it's that one that got clicked and then it sends a text message based on it.

     

     

     

    Posted in: Triggers
  • To post a comment, please or register a new account.