Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- script_author('imring')
- script_name('chatlogger')
- function main()
- while not isSampAvailable() do wait(0) end
- if not doesDirectoryExist('moonloader\\logs') then createDirectory('moonloader\\logs') end
- name = os.date("%d.%m %H %M")..".log"
- while true do
- wait(0)
- if text ~= sampGetChatString(99) then
- text = sampGetChatString(99)
- local f = io.open('moonloader/logs/'.. name, 'a')
- f:write('\n['..os.date("%H:%M:%S")..'] '..text)
- f:close()
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement