L2Tower Discord Let's keep the community alive with discord. Discussions about plugins and scripts L2Tower Discord

Thread Closed 
 
Thread Rating:
  • 1 Vote(s) - 2 Average
  • 1
  • 2
  • 3
  • 4
  • 5
catch "screen text"
Author Message
wasty Offline
VIP Member
***

Posts: 5
Joined: Jan 2012
Reputation: 0
Version: 1.4.1.110
Post: #1
catch "screen text"

Hi, I tried to capture "screen text" but I have not succeeded.

Try a logger but not obtube any "display text", only the text of the system.

Any idea how to do it?

thanks

    LUA Programming
LogON = false;
 
function OnCreate()
	this:RegisterCommand("loog", CommandChatType.CHAT_ALLY, CommandAccessLevel.ACCESS_ME);
end;
 
function OnCommand_loog(vCommandChatType, vNick, vCommandParam)
 
	if (LogON == false) then 
 LogON = true;
 ShowToClient("SYS ", "Log system ON"); 
	else
 LogON = false;
 ShowToClient("SYS ", "Log system OFF");
	end;
 
end;
 
function LogMessage(message)
	local file = io.open(GetDir() .. "\\MyLog.txt", "r");
	if (file == nil) then
 file = io.open(GetDir() .. "\\MyLog.txt", "w");
	end;
 file:close();
	file = io.open(GetDir() .. "\\MyLog.txt", "a+");
	file:write('['..os.date()..']'..message..'\n');
	file:close();
end;
 
function OnChatSystemMessage(id, msg)
	--Event called some system message show up on chat (id - integer, msg - string).
 
	if (LogON == true) then 
 LogMessage(id .. " - " .. msg);
	end;
 
end;

(This post was last modified: 07-16-2013 20:42 PM by wasty.)
07-16-2013 20:01 PM
Find all posts by this user
Thread Closed 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Login screen BLACKBOX ForeverHalfAsleep 1 2,508 01-20-2015 05:58 AM
Last Post: Fox
  disconnect at login screen multiboxingtoon 5 4,389 11-13-2014 18:41 PM
Last Post: Fox
Photo critcal error before login screen vahlle 13 8,615 07-25-2013 17:29 PM
Last Post: angelychris
  Reports include screenshot of whole screen. drag0nius 5 3,992 04-09-2012 22:12 PM
Last Post: drag0nius
  Collors in your system / on screen veto 1 5,218 05-05-2011 12:44 PM
Last Post: MSR



User(s) browsing this thread: 1 Guest(s)