MineX Graphics and Sound API



MineX is an API that implements easy-to-use ASCII graphics and sound using a special note block setup. Before you use the sound features, you must set up a bundled cable note block setup:


SOUND-CARD SETUP:

Order of Notes: (For sound-card setup)

List Number. color - note - clicks on noteblock to attain this.
white - A - 3
orange - A#/Bb - 4
magenta - B - 5
lightBlue - C - 6
yellow - C#/Db - 7
lime - D - 8
pink - D#/Eb - 9
gray - E - 10
lightGray - F - 11
cyan - F#/Gb - 12
purple - G - 13
blue - G#/Ab - 14


Documentation:
SYSTEM:
sys.version() - var=sys.version(). Returns the version of MineX.

AUDIO:
audio.note(note) - audio.note(A#) OR audio.note(A) OR audio.note(Cb). doesn't matter about the letter being capitalized, but the flat and sharp must be correct (flat must be a lower-case :(/>/>. Note listing below.
audio.side(side) - audio.side(back). For if the bundled cable is on the back of the computer.

UTIL:
util.sprint(text to slow print) - This just slow prints the text.
util.openAll() - Opens all ports.
util.ejectAll() - Ejects all disks from surrounding disk drives.
util.bytecode("infile","outfile") - util.bytecode("path/to/input_file","path/to/output_file"). Turns a file into bytecode.

DRAW:
draw.clear() - Clears the screen and sets the cursor to 1,1.
draw.square(char,topleftx,toplefty,bottomrightx,bottomrighty) - draw.square("x",1,1,6,6). draws a square with the 1 and 1 being the x and y of the top left corner, and the 6 and 6 being the x and y of the bottom right corner.
draw.dChar(char,x,y) - draw.dChar("X",1,4). Draws an X at 1,4.
draw.line(char,dir,xTo,yTo,len) - draw.line("O","right",4,6,5). Draws a 5 long line, at 4,6, going to the right, with O as the character.


Download:
http://pastebin.com/NRhKThPY

Feel free to use this as you wish, thank you ;)/>/>.
- Sledger721