Eekelmo's Macros

Discussion in 'Basic Tutorials' started by eekelmo, Dec 31, 2015.

Thread Status:
Not open for further replies.
  1. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    [​IMG]
    I'm currently learning how to script macros and I decided that I'd post them here, advice and feedback is appreciated. If you plan on using my macros please watch the thread as I will be updating them.

    [​IMG]

    - How to Install Macros -
    There are a few things you need to know in order to install macros, first of all creating a text file.

    Creating a Text File
    This is super easy, press SHIFT + ~ (Grave Key) at the same time, it should open up the following menu:
    [​IMG]
    Click on the [​IMG] in the bottom right corner of the menu. This opens up the text file creator.
    [​IMG]
    This menu is really easy to navigate, on the left hand column you have the list of text files you have already created, double click them to edit the code within them. Click on the X to delete (There is a confirmation message for this) and the pencil to change the name. Create a text file by typing the name of the text file into the text box under 'Create a New File' and then clicking 'Create'.
    This will open up this screen:
    [​IMG]
    This is where you will copy and paste the code, for example my Core Macro code.
    [​IMG]
    Remember to click save after making changes.


    So now you know how to make a text file, the next step is binding that text file to something.

    Binding Text Files
    ]This is really, really easy. Press SHIFT + ~ to go to the menu I showed you earlier.
    You will get a picture of a keyboard, if the instructions say to bind a text file to a key, click on the key you want and type '$$<filename.txt>'. For example if the text file is called eekmacros_example, you'd do $$<eekmacros_example.txt>. If you already have macros or text files bound to a key or event, separate them with a pipe, which is the character above your enter key that looks like this: |.
    In order to bind to an event, go to the menu with the keyboard and at the top of the screen you'll see some text that says 'Macro Bindings: Keys'.
    [​IMG]
    You'll want to click the yellow arrow to right of that to get to the events screen.
    [​IMG]
    This has the list of events and you bind text files and commands to them just like you would a normal key.

    That's all there is to it as far as my macros go, I hope this helped.

    [​IMG]

    - Core Macro -

    I highly recommend installing this macro if you plan on installing the others. It adds /help sections about the various macros I create. There are currently 2 pages of macros, /help eekmacros 1 and /help eekmacros 2 to access these pages.
    Installation
    Code:
    Code:
    $${
      IFMATCHES(%CHAT%, "^/help (eekmacros|eekmacro) 1")
            FILTER
            LOG("&e--- &c&leekelmo's macros &e---")
            LOG("&eType '&b/help <macroname>&e' &e for information on each macro.")
            LOG("&eType '&b/help eekmacros 2&e' to go to the next page.
            LOG("&e&l'Me' Macro")
            LOG("&e&l'Hunger Reminder' Macro")
            LOG("&e&l'Panic Spawn' Macro")
            LOG("&e&l'Zoom' Macro")
            LOG("&e&l'AFK' Macro")
      ENDIF
      IFMATCHES(%CHAT%, "^/help (eekmacros|eekmacro) 2")
      FILTER
      LOG("&e--- &c&leekelmo's macros &e---")
      LOG("&eType '&b/help <macroname>&e' for information on each macro.")
      LOG("&e&l'Trade Sign Maker' Macro")
      ENDIF
      IFMATCHES(%CHAT%, "^/help voteblocker")
      FILTER
      LOG("Blocks vote reminders, type /votereminder to toggle.")
      ENDIF
      IFMATCHES(%CHAT%, "^/help me")
            FILTER
            LOG("&e--- &c&leekelmo's macros &e---")
            LOG("&eThe ""Me" macro is a macro that tells you basic&e information &eabout your character.)
            LOG("&eIt adds the command '/me'.")    
      ENDIF
      IFMATCHES(%CHAT%, "^/help hungerreminder")
      FILTER
      LOG("&e--- &c&leekelmo's macros &e---")
      LOG("&eThis macro will send you a message when your hunger is low &eenough.")
      ENDIF
      IFMATCHES(%CHAT%, "^/help panicspawn")
      FILTER
      LOG("&e--- &c&leekelmo's macros &e---")
      LOG("&eThis macro will send you to spawn when your health is low.")
      ENDIF
      IFMATCHES(%CHAT%, "^/help zoom")
      FILTER
      LOG("&e--- &c&leekelmo's macros &e---")
      LOG("&ePress the key that you bound the macro to and you will zoom&e in&e. Release it &eto reset &eyour FOV.")
      ENDIF
      IFMATCHES(%CHAT%, "^/help afk")
      FILTER
      LOG("&e--- &c&leekelmo's macros &e---")
      LOG("&eType /afk and you will vanish and be put into /afk. Type it &eagain &eto &ereverse &ethis.")
      ENDIF
      IFMATCHES(%CHAT%, "^/help tradesignmaker")
      LOG("Press the button you bound it to and it'll make a trade sign.")
    ENDIF
    }$$
    
    
    Text file name: eekmacros_help
    Bind to: onSendChatMessage

    [​IMG]

    - Me Macro -

    This macro adds the command /me, it tells you your balance and time online. In the future I plan on adding more information such as your current chat channel, but I have to learn to do so first.
    Installation
    Code:
    Code:
    $${
        IFMATCHES(%CHAT%, "^/me")
        FILTER
        LOG("&e--- &c&leekelmo's macros &e---")
        LOG("&e&lLet's see...")
        ECHO("/bal")
        ECHO("/seen %PLAYER%")
        LOG("&eCO-ORDS - XYZ" &b%XPOS%/%YPOS%/%ZPOS%)
    ENDIF
    }$$
    Text file name: eekmacros_me.txt
    Bind to: onSendChatMessage
    [​IMG]

    - Hunger Reminder -

    This macro will log a message in your chat whenever your hunger goes below 3 drumsticks.
    Installation
    Code:
    Code:
    $${
    IF(HUNGER < 6);
    
            LOG("Remember to eat your fruits and vegetables.");
    ENDIF;
    }$$
    Text File Name: $$<eekmacros_hunger>
    Bind to: onFoodChange

    [​IMG]

    - Panic Spawn-

    This macro will teleport you to spawn when your health reaches 4 hearts, you can modify the amount of health by changing the number in the 'IF(HEALTH=8)' line.
    Installation
    Code:
    Code:
    $${
    IF(HEALTH = 8);
    ECHO(/spawn)
    LOOP
    ENDIF
    }$$
    
    Text File Name: eekmacros_panic.txt
    Bind to: onSendChatMessage AND onHealthChange

    [​IMG]


    - Zoom -
    This macro is similar to the zoom feature in optifine. The installation is slightly different to others though.
    Installation
    Code: Key down: $${FOV(20)}$$|$${SENSITIVITY(30)}$$
    Key Up: $${FOV(100)}$$|$${SENSITIVITY(100)}$$


    Bind to: Click on a key of your choice, then go to the Key State Macro tab at the top of the screen and copy paste the code.

    [​IMG]

    - AFK -
    This macro requires access to vanish to work. When typing /afk it will /ch afk and /v you at the same time, also included is a label that will tell you if you are /ch afk'd or not.
    Installation
    /AFK
    Code:
    Code:
    $${
    IFMATCHES(%CHAT%, "^/afk")
        FILTER
        LOG("&e&lGoing AFK...")
        ECHO("/v")
        ECHO("/ch afk")
    ENDIF
    }$$
    Text File Name: eekmacros_afk
    Bind to: onSendChatMessage

    Label
    Code:
    Code:
    $${
    STRIP(&chat,%CHAT%)
    IFMATCHES(%&chat%,^You are now AFK.)
        MATCH(%&chat%,^You are now AFK.,(True})
        SETLABEL(eekmacros_afk,AFK: &4%True%)
    ENDIF
    IFMATCHES(%&chat%,^You are no longer AFK.)
        MATCH(%&chat%,^You are no longer AFK.,(False})
        SETLABEL(eekmacros_afk,AFK: &9%False%)
    ENDIF
    }$$
    Text File Name: eekmacros_afklabel
    Bind to: onChat and ingame labels. Control name is eekmacros_afk

    [​IMG]

    - Survival Games Essentials -

    This macro should come in handy for the SG enthusiast. It adds a class system where you can type /class <name> and it will give you a group of kits. You will have to configure these yourself, it's very easy to do so. It also adds the commands /sg1, /sg2, /sg3 and /sg4, these simply allow you to join arenas, if you use these commands to join arenas you will automatically vote to start the match. /sgl is also added, this is short for /sg leave.
    Installation
    Code:
    Code:
    $${
    IFMATCHES(%CHAT%, "^/kit classes")
    FILTER
    LOG(&e--- &c&l%PLAYER%'s kit classes &e---)
    LOG(&eType '&b/class <name>&e' to get kits. All classes include&e &evsg.)
    LOG(Standard. MIQ, BFR, GRND, PF)
    LOG(Annoying. MIQ, BFR, SPY, GRND)
    LOG(Damage. EA, CC, BFR, GRND)
    ENDIF
    IFMATCHES(%CHAT%, "^/class standard")
    ECHO("/kit miqpp,bfrpp,grndpp,pfpp,vsg")
    FILTER
    ENDIF
    IFMATCHES(%CHAT%, "^/class annoying")
    ECHO("/kit miqpp,bfrpp,spypp,grndpp,vsg")
    ENDIF
    IFMATCHES(%CHAT%, "^/class damage")
    FILTER
    ECHO("/kit eapp,ccpp,bfrpp,grndpp")
    ENDIF
    IFMATCHES(%CHAT%, "^/sg1)
    ECHO(/sg join 1)
    WAIT(3)
    ECHO("/sg vote")
    FILTER
    ENDIF
    IFMATCHES(%CHAT%, "^/sg2)
    ECHO(/sg join 2)
    WAIT(3)
    ECHO("/sg vote")
    FILTER
    ENDIF
    IFMATCHES(%CHAT%, "^/sg3)
    FILTER
    ECHO("/sg join 3")
    WAIT(3)
    ECHO("/sg vote")
    ENDIF
    IFMATCHES(%CHAT%, "^/sg4)
    FILTER
    ECHO("/sg join 4")
    WAIT(3)
    ECHO("/sg vote")
    ENDIF
    IFMATCHES(%CHAT%, "^/sgl)
    FILTER
    ECHO(/sg leave)
    ENDIF
    }$$
    
    
    
    Text File Name: eekmacros_sgclasses.txt
    Bind to: onSendChatMessage

    [​IMG]

    - Trade Sign Maker -
    This macro will place down a sign with the format of a trade sign already written on it for you at the press of a button. When using it, replace 'receive' with the price of the item (EG 10 stone/4 ecd), 'give' with the item you're selling and how many (EG 1 dirt) and stock with how much of the item you're stocking (eg 256). Click done and it'll work.
    Installation
    Code:
    Code:
    $${
    &receive = $$[WhatYouWillReceive]
    &give = $$[WhatYouAreGiving]
    &stock = $$[Stock]
    PLACESIGN("[Trade]","%&receive%","%&give%:%&stock%","",true)
    }$$
    Text File Name: eekmacros_tradesign
    Bind to: A key of your choice


    - Coding Your Own Macros -

    Macro mod is a little bit difficult to pick up, in order to learn how to code scripts I looked at other scripts (By people such as 314, Jakeyray, emongolab and more) and using these two pages: http://mkb.bplaced.net/wiki/variables http://mkb.bplaced.net/wiki/commands - they provide up to date information about macromod.
    [​IMG]
    - To Do -

    Lotto data.
     
    • Winner Winner x 3
    • Useful Useful x 2
    • Friendly Friendly x 1
    • List
    #1 eekelmo, Dec 31, 2015
    Last edited: Jan 18, 2016
  2. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    Will be using this first post for any updates.
     
    #2 eekelmo, Dec 31, 2015
    Last edited: Jan 1, 2016
  3. 8MasterBlaster8

    8MasterBlaster8 Yucky Charms
    Builder ⛰️ Ex-President ⚒️⚒️ Premium Upgrade

    Joined:
    Sep 13, 2014
    Messages:
    292
    Trophy Points:
    30,690
    Gender:
    Male
    Ratings:
    +182
    Nice eek, im going to install the panic macro next time im online, thank you for these.

    A quick question. What about SG? Is the panic macro disabled during sg?
     
  4. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    No it isn't, I'll see if I can figure out how to do that.
     
  5. AdmiralD

    AdmiralD IsleTradingCo
    President ⛰️⛰️ Ex-EcoLegend ⚜️⚜️⚜️⚜️ Prestige ⭐ V ⭐ Premium Upgrade

    Joined:
    Jul 26, 2013
    Messages:
    6,105
    Trophy Points:
    97,160
    Gender:
    Male
    Ratings:
    +4,290
    Nice job :eek: It is awesome to see you contributing to the community!
     
  6. 8MasterBlaster8

    8MasterBlaster8 Yucky Charms
    Builder ⛰️ Ex-President ⚒️⚒️ Premium Upgrade

    Joined:
    Sep 13, 2014
    Messages:
    292
    Trophy Points:
    30,690
    Gender:
    Male
    Ratings:
    +182
    One could simply turn it off, but It would be nice if it was possible to have it automatically disabled during sg for ppl like me who forget everything lol
     
  7. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    I have no idea how to turn off macros, I literally started yesterday, but I'll work on it in a few hours.
     
  8. CodeTrooper

    CodeTrooper Builder
    Builder ⛰️ Ex-Resident ⚒️

    Joined:
    Dec 10, 2015
    Messages:
    246
    Trophy Points:
    12,070
    Gender:
    Male
    Ratings:
    +376
    Do you mean a macro that is repeating?
     
  9. 8MasterBlaster8

    8MasterBlaster8 Yucky Charms
    Builder ⛰️ Ex-President ⚒️⚒️ Premium Upgrade

    Joined:
    Sep 13, 2014
    Messages:
    292
    Trophy Points:
    30,690
    Gender:
    Male
    Ratings:
    +182
    As far as I understand it you would have say the panic macro bound to a key or mouse button to turn it on and off. Im not all that familiar with macros as ive just gotten started my self.
     
  10. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    Added the zoom macro and updated the Core Macro accordingly.
    edit: I seem to be having some issues with the panic macro, will attempt to fix.
     
    #10 eekelmo, Jan 1, 2016
    Last edited: Jan 1, 2016
  11. 314

    314 Irratioπal President, former ServerAdmin
    President ⛰️⛰️ Ex-President ⚒️⚒️ Premium Upgrade

    Joined:
    Apr 1, 2014
    Messages:
    6,963
    Trophy Points:
    87,660
    EcoDollars:
    $27,000,000
    Ratings:
    +4,866
    Pi have an idea about the SG disabling - unless you are planning something yourself, I'd like to contribute my idea soon. :p
     
  12. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    I honestly have no idea what to do, go ahead :p
     
  13. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    Added AFK macro and updated core macro.
     
  14. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    I've changed Panic Home to Panic Spawn, it just teleports you to spawn now. Core Macro updated.
     
  15. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    Added SG Essentials and updated core macro accordingly, trade sign maker was also added.
    @andrewkm I also added a macro that blocks out vote reminders earlier, if you deem that to be illegal I'm fine with removing it.
    edit: Jamie told me that it was illegal, vote reminder removed.
     
    #15 eekelmo, Jan 2, 2016
    Last edited: Jan 2, 2016
  16. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    [​IMG]
    As you can see I have 9 labels telling me 9 things, my Y level, direction, FPS, balance, chat channel, game time, AFK status, EXP and real time. I'm just going to teach you how to set these up.
    First the Y-level. If you're looking to have a full co-ordinate display go here - I don't need that though, so I just added the Y co-ord.
    Go onto the ingame GUI screen and click add label, set the binding to YPOS. In the label text type Y Level: %% - add colour codes where you wish. It should work.
    Now for the direction I'm facing. Go onto the ingame GUI screen and click add label, set the binding to direction and in the label text type: Facing: %% - again, you can add colour codes where you want.
    The FPS counter - open the ingame GUI screen and click add label. Set the binding to FPS and the label text to FPS: %% - yet again you can add colour codes where you like.
    Tutorials for the balance display and chat channel display can be found here
    Game time can be added by opening the ingame GUI screen and clicking add label, setting the binding to DAYTIME and making the label text Game Time: %% - add colours where you want.
    Instructions for the AFK label can be found in the main post. Alternatively you can find a version that doesn't require vanish here
    The EXP counter can be created by going into the in game GUI screen and clicking add label, setting the binding to TOTALEXP and then the labelt text to EXP: %% - add colours where you want.
    Finally the real time label, the time on the label is the same as your computer's time. Open the in game GUI screen and click add labe, set the binding to TIME and the label text to Real Time: %% - add colour where you want.

    Other variables can be found here
     
    • Like Like x 1
    • Informative Informative x 1
    • Potato Potato x 1
    • List
    #16 eekelmo, Jan 2, 2016
    Last edited: Jan 9, 2016
  17. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    Credit to @rockboy2000 for the improved version of the trade sign creator.
     
  18. goblizz

    goblizz The One and Only
    Builder ⛰️ Ex-Tycoon ⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Dec 25, 2013
    Messages:
    1,789
    Trophy Points:
    45,160
    Gender:
    Male
    Ratings:
    +1,576
    @eekelmo

    Just from my other coding experience, I adjusted "/sg vote" in the SG Macro for redundancy. The edited code looks something like this, basically executing /sg join, wait, then executing /sg vote.

    Code:
    IFMATCHES(%CHAT%, "^/sg1")
    ECHO(/sg join 1)
    WAIT(3)
    ECHO("/sg vote")
    FILTER
    ENDIF
    
    IFMATCHES(%CHAT%, "^/sg2")
    ECHO(/sg join 2)
    WAIT(3)
    ECHO("/sg vote")
    FILTER
    ENDIF
    
    IFMATCHES(%CHAT%, "^/sg3")
    FILTER
    ECHO("/sg join 3”)
    WAIT(3)
    ECHO("/sg vote")
    ENDIF
    
    IFMATCHES(%CHAT%, "^/sg4")
    FILTER
    ECHO("/sg join 4”)
    WAIT(3)
    ECHO("/sg vote")
    ENDIF
    
    I would assume this works; feel free to let me know if it doesn't.
     
    #18 goblizz, Jan 2, 2016
    Last edited: Jan 2, 2016
  19. eekelmo

    eekelmo Builder
    Builder ⛰️ Ex-EcoMaster ⚜️⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Jul 19, 2012
    Messages:
    3,289
    Trophy Points:
    69,090
    Ratings:
    +7,789
    I'll try it in a moment, if it works are you alright with me adding it into the main post?
     
    • Like Like x 1
    • Potato Potato x 1
    • List
  20. goblizz

    goblizz The One and Only
    Builder ⛰️ Ex-Tycoon ⚜️⚜️⚜️ Premium Upgrade

    Joined:
    Dec 25, 2013
    Messages:
    1,789
    Trophy Points:
    45,160
    Gender:
    Male
    Ratings:
    +1,576
    Absolutely. Just a little debugging is all :)
     
Thread Status:
Not open for further replies.