Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // You need the FarHit module for the range finder to work
- // http://www.minecraftforum.net/forums/mapping-and-modding/minecraft-mods/mods-discussion/1405026-macro-keybind-mod-modules
- // To install a module, drag the .jar file into .minecraft/macros/modules
- // You need to create a label for this to work.
- // Go to Macro Mod keybind editor menu
- // Click the icon on the very top left corner of the screen, then "Gui Editor".
- // Double-click on "ingame" in the left menu. http://i.imgur.com/Cq2bL7p.png
- // On the bottom left, click "Button panel commands", then select "Adjust grid".
- // Click on the far left column in the grid, then change the grid settings to Rows: 22, Columns: 15, Column Width: 48.
- // This is for a 1440x900 monitor. You will need to tweak this to fit your monitor. FOV effects this greatly as well; it's calibrated for 90 FOV.
- // In button panel commands, select "Add label", then click 2 cells below the center cell.
- // Set Control Name to "archerprogress", leave label text and binding blank. Click on Foreground colour, and set the opacity to 0 (drag the slider to the bottom). Do the same for background colour.
- // Set text align to "top centre", and uncheck shadow.
- // Press OK, then click and drag the bottom of the cell to make it 3 cells high. http://i.imgur.com/qkDFLVN.png
- // Bind this macro to the onjoingame event, and it will run in the background, only displaying the HUD when you have a bow selected.
- do;
- // Bow HUD
- if(%ITEM% = "bow");
- // Get distance to target
- #dx = %FARHITX%-%XPOS%;
- #dy = %FARHITY%-%YPOS%;
- #dz = %FARHITZ%-%ZPOS%;
- #dsquare = (%#dx%*%#dx%)+(%#dy%*%#dy%)+(%#dz%*%#dz%);
- #targetdist = SQRT(%#dsquare%);
- if(quickbow);
- if(%ITEM% = "bow");
- key(use);
- endif;
- endif;
- // Zoom HUD
- if("%ALT%" = "True");
- setlabel(archerprogress,"");
- setlabel(distancetotarget,"%#targetdist%");
- setlabel(archersightszoom,"18 ^\n ^\n ^\n27 ^\n ^\n ^\n36 ^\n ^\n ^\n ^\n45 ^\n");
- // Non-zoom HUD
- else;
- setlabel(archersightszoom,"");
- setlabel(distancetotarget,"%#targetdist%");
- setlabel(archerprogress,"18 | ^ |\n27 | ^ |\n36 | ^ |");
- endif;
- else;
- setlabel(distancetotarget,"");
- setlabel(archerprogress,"");
- setlabel(archersightszoom,"");
- endif;
- loop;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement