Jump to content
  • 0

Help:Need the resources of chat (like history..file ..text)


Drako

Question

Hey guys.

I need the resources of the chat.. it is like history or something like that..some file contains the whole chat since i have been playing MTA..or file contain the chat ..even though it will remove later..but i need what contain the current chat

i am trying to find it in MTA folder but failed to..so help me

P.S : thx ,and sry for the bad english

Link to comment

6 answers to this question

Recommended Posts

  • 0

I guess it's saved nowhere. If the server where you want to save chat history is yours then you can make a script to save it.

Use my function that I made for one of the Neo Playgrounds' gamemodes:

-- output to log, returns: boolean - true if saved successfully, false otherwise 
function outputLog( sz ) 
    if( not sz ) then return false end 
    if( not type( sz ) == "string" ) then return false end 
    local pLogFile = fileOpen( "log/server.log", false ) 
    if( pLogFile ) then 
        local aTime = getRealTime( ) 
        local szCurrentTime = "[" .. aTime.month + 1 .. "/" .. aTime.monthday .. "/" .. aTime.year .. " " .. aTime.hour .. ":" .. aTime.minute .. ":" .. aTime.second .. "]" 
        if( fileWrite( pLogFile, szCurrentTime .. " " .. sz ) ) then 
            return true 
        end 
        fileClose( pLogFile ) 
    end 
    return false 
end 
  

With onPlayerChat event.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...