• 0

    posted a message on Text tag change color trigger not work

    Make sure your custom text colors are within text styles. So if a style was by default of color red, different colors would need to be inserted within the style. Because this is annoying, I made a function for myself:

    Text with Style, Color
        Options: Function
        Return Type: Text
        Parameters
            Style = "" <String>
            Color = "<c val="000000">" <Text>
            Text = No Text <Text>
        Grammar Text: Text with Style (Style), Color(Color)
        Hint Text: (None)
        Custom Script Code
        Local Variables
        Actions
            General - If (Conditions) then do (Actions) else do (Actions)
                If
                    Text Color has been set
                Then
                    General - Return (Combine ("<s val="", (Text(Style)), "">", Color, Text, "</c></s>"))
                Else
                    General - Return (Combine ("<s val="", (Text(Style)), "">", Text, "</s>"))
    
    Posted in: Triggers
  • 0

    posted a message on Dialog or Leaderboard?

    @XGDragon: Go

    Took a bit longer than I thought because I didn't read your requirements correctly. No matter.

    And by the way, my incomplete tutorial does give you enough to figure out what I did. The rest would merely explain how to edit Blizzard's UI. I haven't gone round to it because I'm lazy.

    Posted in: Triggers
  • 0

    posted a message on Dialog or Leaderboard?

    I like a challenge, especially when they're easy. Let's see how fast I can do this, using this post as my starting timer.

    Posted in: Triggers
  • 0

    posted a message on sc2editor subreddit

    Hey everyone,

    If you use Reddit.com sometimes, you might want to check out the new www.reddit.com/r/sc2editor. It's just another way for discussing and asking questions about our favorite program!

    Posted in: General Chat
  • 0

    posted a message on Starcraft: the Board Game [implementation of a board game]

    I created a website!

    Posted in: Project Workplace
  • 0

    posted a message on Need a ultra-simple placeholder model!

    That's a.. semisphere. Where the rounded cap on top of it? The sphere needed to be at the bottom and the cap at the top.

    No matter though, I received a model through PM which was sufficient. Thanks for trying to help though, appreciated!

    Posted in: Requests
  • 0

    posted a message on Need a ultra-simple placeholder model!

    @Zolden: Go

    I don't mind at all. Just a dark brown color would suffice.

    Posted in: Requests
  • 0

    posted a message on Need a ultra-simple placeholder model!

    Hey guys,

    I need something very simple that would take you less than 10 minutes to create. I think.

    I just need a shape with a shitty texture on it.

    See attachment for shape. Should be about as large as a 7x7 building or 140% the size of a Terran Command Center. Or not and I'll just scale it up/down.

    The shitty texture should be something like dirt. Brownish? I don't know, not too flashy.

    Don't underestimate the importance I vest in this shape. It will be my placeholder for many testings and I will use it a huge amount.

    Thanks for considering!

    Posted in: Requests
  • 0

    posted a message on [UI] How to create dialogs and edit Blizzard UI using the UI and trigger editor

    Hey everyone,

    I know there are lots of questions on how to be able to make easy dialogs with minimal amount of dialog triggers (instead of create dialog item, set size, move/attach dialog item to dialog item, set dialog item text, set dialog item style ... this list goes on..). In addition, the information here (Helral's override method) is outdated and not efficient anymore. (but kudo's for it!)

    Now I don't have a lot of time as I have exams coming up this week, so no cool pictures and other funny business, but I still wanted to get people started on how to smoothly edit all Blizzard UI and how to create templates so you can use those to easily create new dialogs (items).

    Introduction to the UI editor

    To create a template dialog, you first need to understand how XML works. There are many tutorials on the internet. It's not hard, and all the information is relevant to the UI editor. You should be able to learn it in an evening. Just be sure that you know what elements and attributes are and how to properly open/close these trees.

    Anyways! The UI editor is basically a compilation of all of Blizzards UI info. It is the exact same you find in the ingame UI editor. You will need to understand how both work to be able to work efficiently. Let's just start at the beginning. In the UI editor, you will find many files or layouts. These are all read-only and you cannot edit them at all. Within these files you will find many frames, images, labels and so on. How the structure exactly works will become clear as you create your first dialog with items using the UI editor.

    Creating a custom dialog item

    Now, before I begin (and this is the last time I will delay) I want to talk about resolution and aspect ratios for a moment. Starcraft II is based on a 1600x1200 resolution. This means that any dialog wider than 1600 will fall out of the screen if the user's resolution width is smaller than 1600. Therefore, your dialogs may never exceed 1600 or it will result in overlapping for smaller resolution. This does indeed mean that there will be gaps for larger resolutions, and we will all have to deal with this until someone comes with a solution.

    So, for those who want to create completely custom UIs, I strongly recommend you to set up multiple dialogs. I will explain this later this month. For the purposes of this tutorial however, just create a dialog using triggers, set it to full screen and set it to a variable. We'll call it GlobalDialog. We do not create dialogs using the UI editor. We use the UI editor to create templates from which we can copy dialog items into dialogs.

    Create a layout in the UI editor (Ctrl+L) and name it CustomUI. Copy the following XML code and paste it between <Desc></Desc>:

        <Frame type="Frame" name="DialogFrame">
            <Height val="250"/>
            <Width val="250"/>
            <Frame type="Image" name="DialogImage">
                <Height val="25"/>
                <Width val="25"/>
                <Anchor side="Top" relative="$parent" pos="Min" offset="5"/>
                <Anchor side="Left" relative="$parent" pos="Min" offset="5"/>
            </Frame>
    
            <Frame type="Label" name="DialogBody">
                <Style val="DialogBody"/>
                <Height val="250"/>
                <Width val="200"/>
                <Anchor side="Top" relative="$parent" pos="Min" offset="0"/>
                <Anchor side="Left" relative="$parent" pos="Min" offset="50"/>
            </Frame>
        </Frame>
    

    Save the project. You will find that that your layout now has content in the tree view!

    Let's go over this code. I am assuming you know how XML works. It's really simple and nothing to brag about. We have created three frames. DialogFrame is our invisible frame that we will use to mark the anchor for the children frames. See it as a container, with inside labels and images (and some other stuff). DialogImage is our image. No image has been set, we do this in triggers. The height, width and positioning however, has been already set. It will be 25x25 and will be anchored to DialogFrame's Top,Left with offsets 5,5. Note that $parent basically tells it to anchor to its parent. Easy! DialogBody works the exact same as DialogImage, but I added the Style element. Let's go off on a tangent.

    Open the Text editor. Go to Font Styles and add a style. Name it "DialogBody". Give it some style. You may see the connection here. DialogBody will use the "DialogBody" font style in its text.

    Now that our UI template is set up, we can go ahead and create a copy. There are two very important triggers that we will use: "Create Dialog Item From Template" and "Hookup Dialog Item". Create a trigger with Map Initialization and add the action "Create Dialog Item From Template" and create the dialog item variable DialogFrame.

            Dialog - Create a Panel for dialog GlobalDialog using the template Template CustomUI/DialogFrame
            Variable - Set DialogFrame = (Last created dialog item)
    

    Then, we will edit the templates children. Use "Hookup Dialog Item".

            Dialog - Hook up an existing Image called DialogImage in dialog item DialogFrame
            Dialog - Set (Last created dialog item) image to Assets\Textures\btn-unit-terran-marine.dds for (Active Players)
            Dialog - Hook up an existing Label called DialogBody in dialog item DialogFrame
            Dialog - Set (Last created dialog item) text to "This is a marine. There are many li..." for (Active Players)
    

    We don't necessarily need to give these items variables unless you plan to change them later on.

    Editing Blizzard UI

    This is as far as I will write my tutorial for now. I'll add more next week.

    Todo list

    • Edit Blizzard UI
    • How to use the ingame UI editor
    • Some limitations

    Quick notes for those who can figure it out themselves and/or can't wait and love badly formatted scribblings:

    Edit blizzard UI: Hookup Standard Blizzard UI Dialog - Hooks up an existing Panel in the standard UI called "UIContainer/ConsoleUIContainer/CommandPanel/CommandButton00" edit size and positioning. Set CommandPanel to fullscreen and you can individually move around all command buttons. This works for everything in the blizzard UI (such as the minimap). GameUI works with templates, but hookups are runtime so the above will work. You can't create new unapproved types in your CustomUI layout. I don't know them all, but approved examples are Label, Image, Panel, Button, Slider. Unapproved examples are all specific panel types "LogMessagePanel", "SocialManagementPanel". Some other stuff too. For a complete list of all the field/value for each type, see http://www.sc2mapster.com/paste/7445/ In ingame UI editor, I don't know how to move stuff but I don't really mind. Frame Tree is edittime, Desc Tree is runtime. Or something. Press F11 to show anchors neatly. Press F10 for dimension and parent information. I recommend selecting frames using the trees. Trees.

    Posted in: Tutorials
  • 0

    posted a message on Starcraft: the Board Game [implementation of a board game]

    Project is not dead. Was just waiting for the expansion so I could continue!

    Posted in: Project Workplace
  • 0

    posted a message on Starcraft: the Board Game [implementation of a board game]

    Work has been resumed

    Posted in: Project Workplace
  • 0

    posted a message on Starcraft: the Board Game [implementation of a board game]
    Quote from GrimGoddy: Go

    Hello guys, I registered here just to say that you are making awesome work with converting board game into real SC2 map. It's my dream to have digitalised SCtBG - I love this game but I have big trouble with finding competitive players. About the graphics - I know there is made Starcraft the Board Game module, which works with VASSAL. Basically, it has every one component scanned with good quality.

    Maybe you could use some of its components graphics into your map?

    Creator of this module is Zackreaver (http://bit.ly/TrJ9mS) - maybe he could share his scans for higher purpose? :)

    Not sure what I can use the graphics for, but this is pretty cool though.

    In other news, I'm continuing this project on January. Stay tuned. Likely to be finished Q3 2013 :)

    Posted in: Project Workplace
  • 0

    posted a message on Starcraft: the Board Game [implementation of a board game]
    Quote from ScorpSCII: Go

    Great UI, nice job on that

    Thanks, just to confirm: there's nothing we can do about people playing on low resolutions right? The ui gets screwy at some lower limit of resolution.

    Posted in: Project Workplace
  • 0

    posted a message on Starcraft: the Board Game [implementation of a board game]

    @minq1: Go

    I didn't have any trips planned for last summer as all money was spent on the exchange program I'm currently experiencing. Made this into a huge summer project. Can't work on it now though, my laptop is a little slow unlike my computer back home. I'll start again at Christmas.

    Posted in: Project Workplace
  • 0

    posted a message on Starcraft: the Board Game [implementation of a board game]

    @minq1: Go

    I'm aware of time issues, which is why I have given the ability to assign workers for gas/minerals and build stuff without being in a build order. Once it's your turn, all you'd need to do is review your plan and press confirm build order.

    You can also browse tech cards at any time. Aswell as your combat cards. There's a lot to do even when out of turn.

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