Vanish display Macro

Discussion in 'Basic Tutorials' started by Inamine, Oct 10, 2014.

  1. Inamine

    Inamine Builder
    Builder ⛰️ Ex-President ⚒️⚒️

    Joined:
    Feb 2, 2014
    Messages:
    791
    Trophy Points:
    22,640
    Gender:
    Male
    Ratings:
    +231
    Hey, so this is mostly script from @jakeyray18 on this tutorial http://www.ecocitycraft.com/forum/threads/afk-display-macro-tutorial.67591/#post-324137
    but in this tutorial I'll show you how to have a true or false display for vanish, rather than afk.
    Step 1:
    Create new text file called vanishdisplay.txt and insert the following code into the text box.
    Code:
    $${
    STRIP(&chat,%CHAT%)
    IFMATCHES(%&chat%,"^You have vanished\. Poof\.")
        SET(@&vanish,Vanish: &4True)
    ELSE
        IFMATCHES(%&chat%,"^You have become visible\.")
            SET(@&vanish,Vanish: &bFalse)
        ENDIF
    ENDIF
    }$$
    Step 2:
    After you create the text file bind it to the onChat event and use the | between any other binds in there.
    Use the following to bind it.
    Code:
    $$<vanishdisplay.txt>


    Step 3:

    Now for when you join the game for it to set it to False for vanished you need to paste the following into onJoinGame events.
    Code:
    $${SET(@&vanish,Vanish: &bFalse)}$$

    Step 4:
    Go to the button/label screen on the ingame section which you an get to with GUI editor at the bottom.
    Ignore the Command name, and name the label "%%" (without quotes) and make the binding @&vanish

    This is my first tutorial for macros, let me know if you need any help, I'm not great at macros, but this one works for me. :)

    - Inamine
     
  2. NickLA3107

    NickLA3107 Builder
    Builder ⛰️ Ex-EcoLeader ⚜️⚜️⚜️

    Joined:
    May 18, 2012
    Messages:
    677
    Trophy Points:
    30,140
    Gender:
    Male
    EcoDollars:
    $0
    Ratings:
    +206
    Been using this for a few days, thanks! its super helpful and works perfectly