With the introduction of minification, I must thank Mathias Bynens for his wonderful luamin utility.
This Application Requires Java 8 or above. Windows versions are distributed with the Java SE 8 update 40 Runtime Environment. This is to allow for a cleaner, native-ish GUI and to allow access to the Nashorn Scripting Engine allowing leverage of JavaScript scripts.
The niche Autotyper program, completely re-written under a new brand. This program is currently entirely written in Java and JavaScript and operates around your Minecraft instance. Simply execute the program as desired and move to the Minecraft window, from there it will start type out the file it was given into the game!
It's quite simple to run anyway. Eventually I will throw in a batch script and shell script just for fun. When there is a GUI, the program will be available as an executable (for Windows and Unix) and will launch directly into a more friendly GUI. As of v2.0a this is via JavaFX providing a much more consistent and friendly user experience, although a Swing version is provided should JavaFX not be available.
Currently this is meant to produce functional programs, not readable programs. Therefore, comments and whitespace are mostly stripped out. Indenting I will look into adding back in. It's fast and has worked on the 3 programs I have tried so far:
- Adavanced Calculator by Cranium
- Milkshake GUI Proof Of Concept by lednerg
- Bubbles! by KingofGamesYami
Source : CCAutotyper GitHub
Changes : GitHub Changelog
Issues : GitHub Issues
Executable Shell Script (Unix) and Windows Executables Available. Follow the proceeding instructions for commandline execution.
How To:
java -jar ccautotyper.jar [file|url|paste|gui] <location> [-wait] [-inDelay]
// Usage available through:
java -jar ccautotyper.jar
// Example (20 ms Input Delay, 5 second Wait):
java -jar ccautotyper.jar paste JCR8YTww -inDelay 20 -wait 5
// or
java -jar ccautotyper.jar gui
As of v0.2a pressing alt + P will toggle pausing and alt +S will terminate the autotyper see release for details.
It is recommended you let the program go to completion, the Robot will continue to type once you leave the Window. I will see if I can do anything about that but it's difficult to listen for arbitrary keypresses outside of a Java GUI in Java. Looking for changes in Window Focus is unlikely but possible… But not without a GUI.
Parameter Descriptions:
The Required Parameters (In Specific Order):
[file|url|paste|gui] <location>
[indent=1][flag|url|paste|gui] - Simply choose one of the 3 selections. File indicates a file will be given on the local file system. 'url' indicates a VALID URL will be given. 'paste' indicates a Pastebin Code will be given. Putting 'gui' does not require a location and should be the only argument.[/indent]
[indent=1]<location> - This is dependent on the flag selection. For 'file' a Path is given (relative or absolute), for 'url' a valid URL is supplied (e.g. http://www.computercraft.info), for 'paste' a valid Pastebin code is given (i.e. JCR8YTww [Which is the 'Bubbles!' Program]).[/indent]
The Optional Parameters (No Specific Order):
[indent=1][-wait] - A flag to indicate how long the Autotyper should wait before parsing the file and typing.[/indent]
[indent=1]Example: '-wait 5' will wait 5 seconds. [Default: 10][/indent]
[indent=1][-inDelay] - A flag to indicate how long the Autotyper should wait between keypresses. In milliseconds. You might say "1 millisecond of couse!" but this does not always work if Minecraft is expriencing severe FPS and input lag. Minecraft is pretty good… I can run at 10 milliseconds but the default is 40 milliseconds. Which can be a while. [Default: 40][/indent]
Copyright 2014 Matthew Crocco under the GPL v3
What does this mean, you ask? Here is a TL;DR Legal Summary
But seriously, feel free to create derivatives of this work as long as you keep it Open Source and Free.
Technical Details will be found on GitHub for those interested when I get to it. It's unfortunate my super-fast Copy and Paste solution failed…
Any and All Issues or Requests should be posted on GitHub… but I will check here of course. :)/>
Most Recent Changes
v3.0.0 M&P to v3.0.1 WinFix[Notes]
- Resolves bug on windows machines where attempts to set POSIX permissions on cache files would cause an exception.
- Improved minification performance using cached files and Google Good Fast Hash as found in the hidden .cctyper-cache directory
- This is a statically sized evicting queue removing the Least Recently Accessed files when space is needed
- Better LuaString repair method using regular expressions
- Tooltip Updates for final release
v2.1.1 to v3.0.0 – Minification and Polish Update, It's been a while.
[Primary]
- New 'scripts' directory in which any non-java scripts will be stored for use later on
- Primarily included as of this update to allow for use of luamin
- Minification of Lua Code is now possible (to reduce character count and speed up the typing process) using luamin through nashorn
- Files downloaded from Pastebin or some URL are now stored in a '.cctyper-cache' hidden directory (Up to 20 files are stored)
- This likely warrants an uninstall script to handle removing any hidden directories/files
- Fixes for autotyping in which Multi-line comments and in-line comments were not handled correctly
- This was likely due to API restructuring and not an ages old bug
- Small fix to try and ensure that icons appear in Ubuntu-based OS' on load, not on show
- Multiple URL (non-pastebin) files are now cached, moved away from calling them all "cc-auto-file" and now uses a random crc32c based naming system
- Cleaned up certain text snafus
- Added a minification checkbox which has it's state saved between each instance
- Added tooltips to certain things of importance such as the minification check box, location field, menubar buttons (top left)
- Code Preview now loads Minified code instead of original code so that the user may deem if the Minification was worth it or too dangerous
- New links to the Github Page and the Developer Website on the Copyright dialog
- New 'minify' package where any minification APIs will reside, currently this is all centralized in a single 'Minifier' class that uses luamin to minify Lua Code using the Nashorn Scripting Engine.
- Moved setAppIcons to Resources instead of FXAutotyperWindow
- Further documentation effort… hopefully some day….
- Reticulated splines
- New TimedTooltip that allows modificaiton of the Open Time (time between hover and showing the tooltip) using Reflection to create a TooltipBehavior
- New WebLink that puts the basic function of a Hyperlink in one call. Creates a Hyperlink with a URL location to go to using HostServices or something similar
- More debug information as well as more readable documentation (i.e. Loading and Saving Preferences)
- FXGuiUtils.buildLongAlert now allows you to specify a list of Nodes to include at the bottom of the dialog
- GuiAccessors must now provide a openSite method that opens a URL in a web browser
- TypingMethodology fixed to handle spaces, comments and multi-line comments correctly
- Console.empty() now prints an empty line
- Web Files (non-pastebin) are now stored in the cache using a Random filename that is dervied from the result of CRC32C and then turned into a hex string
- Much better than just "cc-auto-file"
- Cleaned up legacy stuff, especially in the console interface. Swing needs to be cleaned.
- Updated libraries as necessary and ensured compatibility