Lua:getScreenCanvas

From Cheat Engine
Jump to navigation Jump to search
<> Function

function getScreenCanvas() : Canvas

Returns a Canvas object that can be used to draw or write directly to the screen.

Note: This function is not as useful as it may seem, since drawing directly to the screen is usually temporary and can be overwritten by normal screen updates.

Function Parameters

This function has no parameters.

Returns

Canvas — A Canvas object that can be used to draw or write to the screen.

Examples

local canvas = getScreenCanvas()
canvas.TextOut(100, 100, "Hello World")

See also

Lua
Script Engine