world2.chat and its behaviours

Results 1 to 5 of 5
  1. #1
    cats addicted Zorno is offline
    MemberRank
    Apr 2010 Join Date
    GermanyLocation
    1,465Posts

    world2.chat and its behaviours

    Hello,

    if im right, world2.chat is the file with all the chat in it. Its getting bigger and bigger and bigger because it logs all chat all the time.
    First i have a questions. If i just delete it, will logservice create a new one by itself or do i have to make an empty file to kick old logs ?

    I made a php script which reads the last 20 lines and decode it. This works just fine ( its very similar to the livechat plugin for pwAdmin ) and when i do a little cosmetic it will be fine for chatting without logging in. Its only the ingame part so no chatting atm, just reading the ingame chat. I know we can inject messages into it but they are always system broadcasts ( dunno how to get it working to write in chat as a player ) and i try to find out how to inject to worldchat or trade chat ( no one uses trade chat so this one whould be perfect as "offline" chat )

    Any infos about the File and ways to inject into it whould be great.


  2. #2
    Black Magic Development das7002 is offline
    MemberRank
    Apr 2010 Join Date
    EarthLocation
    2,188Posts

    Re: world2.chat and its behaviours

    Quote Originally Posted by Zorno View Post
    Hello,

    if im right, world2.chat is the file with all the chat in it. Its getting bigger and bigger and bigger because it logs all chat all the time.
    First i have a questions. If i just delete it, will logservice create a new one by itself or do i have to make an empty file to kick old logs ?

    I made a php script which reads the last 20 lines and decode it. This works just fine ( its very similar to the livechat plugin for pwAdmin ) and when i do a little cosmetic it will be fine for chatting without logging in. Its only the ingame part so no chatting atm, just reading the ingame chat. I know we can inject messages into it but they are always system broadcasts ( dunno how to get it working to write in chat as a player ) and i try to find out how to inject to worldchat or trade chat ( no one uses trade chat so this one whould be perfect as "offline" chat )

    Any infos about the File and ways to inject into it whould be great.
    It's a log file...
    Not a read and output data file

    add this line to your crontab (adjusting paths as needed)
    0 0 * * * gzip /PWSever/logservice/world2.chat && echo > /PWServer/logservice/world2.chat

    That compresses the current log at midnight and when its done it then erases truncates the file for new data to be added

  3. #3
    cats addicted Zorno is offline
    MemberRank
    Apr 2010 Join Date
    GermanyLocation
    1,465Posts

    Re: world2.chat and its behaviours

    Quote Originally Posted by das7002 View Post
    It's a log file...
    Not a read and output data file
    I know that it is a log file. Mah question was a bit wrong. I want to know how to kickout messages to the server that are not system broadcasts
    Quote Originally Posted by das7002 View Post
    add this line to your crontab (adjusting paths as needed)
    0 0 * * * gzip /PWSever/logservice/world2.chat && echo > /PWServer/logservice/world2.chat

    That compresses the current log at midnight and when its done it then erases truncates the file for new data to be added
    I dont want to have compressed data, i want to thrash the whole data and start a fresh file lol. So i just want to know if it is ok to delete the file or if i have to create an empty file for that.

  4. #4
    Black Magic Development das7002 is offline
    MemberRank
    Apr 2010 Join Date
    EarthLocation
    2,188Posts

    Re: world2.chat and its behaviours

    Quote Originally Posted by Zorno View Post
    I know that it is a log file. Mah question was a bit wrong. I want to know how to kickout messages to the server that are not system broadcasts


    I dont want to have compressed data, i want to thrash the whole data and start a fresh file lol. So i just want to know if it is ok to delete the file or if i have to create an empty file for that.
    You can empty it... that is what the second part does

  5. #5
    cats addicted Zorno is offline
    MemberRank
    Apr 2010 Join Date
    GermanyLocation
    1,465Posts

    Re: world2.chat and its behaviours

    Quote Originally Posted by das7002 View Post
    You can empty it... that is what the second part does
    perfect Thanks again



Advertisement