Color Console For AGK2.0 
Alex 'Jack' Schmidt 2018
==== online-arts.de ====

Version 1.0b

Easy Lib with some commands in order to control the console.
Beware, if you loose focus, (because you clicked on the console) you won't get input commands anymore.
This plugin is free and can be used for any work without charge.



Example Code:

#import_plugin Console


// show all errors
SetErrorMode(2)

// set window properties
SetWindowTitle( "ConsolePlugin" )
SetWindowSize( 1024, 768, 0 )
SetWindowAllowResize( 1 ) // allow the user to resize the window

// set display properties
SetVirtualResolution( 1024, 768 ) // doesn't have to match the window
SetOrientationAllowed( 1, 1, 1, 1 ) // allow both portrait and landscape on mobile devices
SetSyncRate( 60, 0 ) // 30fps instead of 60 to save battery
SetScissor( 0,0,0,0 ) // use the maximum available screen space, no black borders
UseNewDefaultFonts( 1 ) // since version 2.0.22 we can use nicer default fonts

Console.Init(30)
Console.SetTitle("Console")

line as integer
tick as integer

// this will set a new color and update the whole screen in order to apply it
Console.SetColor(46)
Console.Clear()
maxtick=600

Console.SetChar(1,2,"Soon the regular example starts, be prepared")
	
do


if GetRawKeyState(27)
	Console.SetChar(1,1,"Yes. Now its pressed          ")
else
	Console.SetChar(1,1,"[ESC] key pressed? No, not yet")
endif

	Console.SetChar(54,2,str(tick)+"/"+str(maxtick))
	
	


	inc tick
		if GetRawKeyPressed(13) then Console.Clear()
	if tick>maxtick
		maxtick=60
		inc line
		color = mod(line,255)
		Console.SetColor(color)
		Console.PrintCon("")	
		Console.PrintCon("Multi color Console Output in AGK for Windows x32")
		Console.PrintCon("Made by Jack - alex04.schmidt@gmail.com        Line: "+str(line*4-1) + "    color: "+str(color))
		Console.PrintCon("")
		tick = 0
	endif


    Print( ScreenFPS() )
    Sync()
loop