Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- MOD.LastMsgUsr = {};
- local function Join(user)
- print(user.." has joined");
- end
- local function Leave(user)
- print(user.." has left");
- end
- local function Msg(user,msg)
- MOD.LastMsgUsr[user:lower()] = msg;
- end
- local function LastMsg(msg)
- local txt = MOD.LastMsgUsr[msg:lower()];
- if not txt then
- return;
- end
- print("Last msg by " .. msg .. " was: " .. txt);
- end
- MOD.SetUserJoinEvent(Join);
- MOD.SetUserLeaveEvent(Leave);
- MOD.SetUserMsgEvent(Msg);
- MOD.AddCom("last",LastMsg);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement