API:TextLogGetNumEntries
From RoR Wiki
UI Lua API · TextLog functions
Version: WAR 1.4.8
Returns how many entries a text log holds.
count = TextLogGetNumEntries(logName)
Arguments
- logName
string– Name of the text log.
Returns
- count
number– Number of entries currently stored. Never more than the log's entry limit.
Details
- Valid indexes for TextLogGetEntry are
0tocount - 1. - The stock UI never calls this function.
Errors
Error in function call 'TextLogGetNumEntries': Text Log %s does not exist
Example
A minimal example built from the documented signature:
for i = 0, TextLogGetNumEntries( "Chat" ) - 1 do
local timestamp, filterType, text = TextLogGetEntry( "Chat", i )
end
