The Wiki for Tale 5 is in read-only mode and is available for archival and reference purposes only. Please visit the current Tale 11 Wiki in the meantime.

If you have any issues with this Wiki, please post in #wiki-editing on Discord or contact Brad in-game.

VeggieTales/srKeyEvent

From ATITD5
Revision as of 05:55, 15 December 2010 by Jimbly (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search
void srKeyEvent(const char *s)

Sends a character or sequence of characters to the captured window. Example:


loadfile("luaScripts/screen_reader_common.inc")();

function doit()
	askForWindow();
	
	lsSleep(250); -- wait for shift release to make it to the window
	srKeyEvent('username\tpassword');
	lsSleep(250); -- wait a moment before submitting so we can see it work, that's more fun!
	srKeyEvent('\n');
end

This will send the string "username" followed by a tab (\t) and then the string "password" and then enter (\n).