1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Tooltip Writing, Hex codes, and auto generation

Discussion in 'Map Making' started by Woodenplank, Jan 20, 2018.

  1. Woodenplank

    Woodenplank Brigand Map Maker

    Trophy Points:
    Hey! In this short tutorial I will try to teach you how to efficiently write Warcraft 3 style tooltips.

    Part 1 - Hex Codes and linebreaks
    When writing tooltips there are a few essential snippets of code you should know. All these begin with a vertical line '|', and some will also need a segment to end the code.

    Line Breaker Operation |n
    This is the equivalent to hitting the "Enter" key in text. For example:
    Hexal Colour Codes
    When you're writing the Learn/Use tooltips for abilities, you generally want the hotkey to show up in that nice "orange'ish yellow" that Warcraft uses. It's simple to make, and will be greatly appreciated by anyone who plays your map!

    To colourize text in Warcraft 3, start with a vertical line and a c "|c"
    After that, you must put in the HEX colour code. The hex code for Warcraft 3's Hotkey colour is |cffffcc00. Once you've typed in the HEX code, remember to end the colourized segment with "|r" - if you don't ALL of your text will stay in that colour.

    Storm Bolt [|cffffcc00Q|r] - [|cffffcc00Level 1|r]
    In Game: Storm Bolt [Q] - [Level 1]

    HEX code is a - more or less - universal language of colourization. Meaning you can change your tooltips to almost any colour you like, if you know the HEX code. But I've compiled a list here of the ones most normally used in Warcraft 3.
    ////////////////Player Colours////////////////
    |c00FF0303Player 1|r
    |c000042FFPlayer 2|r
    |c001CE6B9Player 3|r
    |c00540081Player 4|r
    |c00FFFC01Player 5|r
    |c00fEBA0EPlayer 6|r
    |c0020C000Player 7|r
    |c00E55BB0Player 8|r
    |c00959697Player 9|r
    |c007EBFF1Player 10|r
    |c00106246Player 11|r
    |c004E2A04Player 12|r

    |cffffcc00 TOOL-TIP-YELLOW |r
    |cffc3dbff Auto-cast Light-blue |r

    Fun (?) Fact:
    Brigandshaven also uses HEX codes, but you need to type them differently from Warcraft 3.
    For the website, "|cffffcc00" corresponds to "COLOR=#FFCC00"

    Part 2 - Calling Editor Values
    Tired of having to rewrite your tooltips every time you make a nerf or buff?
    (deals X damage, Y seconds stun)--->(deals x2 damage, y2 seconds stun)

    Well you don't have to for most abilities! Just write your tooltips with built in "reference codes" used by Warcraft 3. Let's take the standard tooltip for Storm Bolt as an example
    Notice that the tooltip doesn't write Level 1 - 100 damage... level 2 - 200 damage.
    It references the object data through its Editor code; that is <AHtb,DataA1>... <AHtb,DataA2>. These values point to the level 1 and level 2 damage dealt of the basic Mountain King Storm Bolt.

    But how do you find codes for other abilities? Or more importantly; the codes for new abilities you make!?
    In the Object Editor, try hitting "Ctrl+D" - this will display everything as "Raw Data". Your categories (to the left) will look like this...
    Here you see that each ability has its own rawcode. My "Cleaving Strikes" ability is called "A00W:ANca" by the editor.
    (Note: Only the first 4 characters -A00W- are actually unique to this ability. "ANca" denotes that it's based on Cleaving Attack. Similarly; any ability based on Storm Bolt will be <XXXX:AHtb>)

    If we check my Cleaving Strikes ability, the Ability Values look like this
    The interesting here is the Data in A1, A2, and A3. This is the Cleaving Percentage for the ability. So when I write the tooltips, I simply put in
    "<A00W:ANca,DataA1,%>%" and the game will display that as "30%"
    Using these codes in your tooltips means never having to rewrite the tooltip! Every time you change the damage/duration/healing/whatever of a spell, the tooltip updates itself because it always refers to the same data field!

    (Of course, you only include the ",%" end if it's a percentage value. For simple values (like the Area of Effect) we could write <A00W:ANca,Area1> and it comes out as "200")

    Part 3 - Misc. Advice
    Use the "Auto Fill Levels" tool.
    Simply right click on a value in a multi-leveled spell and use "Auto Fill Levels".
    For tooltips; this will replace any number "1" with the value of the level, so level 2 tooltip "1->2", level 3 tooltip "1->3" and so on.

    You can also use this on extended tooltips. So for Storm Bolt we could use Auto Fill to turn <AHtb,DataA1> into <AHtb,DataA2>... <AHtb,DataA3>, and the level variations write themselves as 100 damage... 200 damage... 300 damage.

    You can also use Auto Fill Levels to make "Ability Scaling" calculations.
    For Spell Values (such as damage of Storm Bolt) you can set in a formula.
    • Like Like x 4
    Last edited: Feb 12, 2018


    Trophy Points:
    The tooltip for Banish in the picture does not mention that ethereal units can't be attacked by non-magic attacks. :] (It's a stock Wc3 spell lol so even Blizzard did not do it perfectly)
  3. Woodenplank

    Woodenplank Brigand Map Maker

    Trophy Points:
    Well yeah; my point was the hotkey, level information, nice spacing, etc.
    • This This x 1