Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ui.addTextArea(0, "thing", nil, nil, nil, nil, nil, nil, nil, 0.5, true)
- string = {}
- function eventChatCommand(playerName, cmd)
- if cmd:sub(0,1)=="p" then
- table.insert(string, "<font color='#0880fe' size='16'><b>"..playerName.."</b></font> : <font size='16'>"..cmd:sub(3).."</font>")
- elseif cmd=="reset" then
- for i=0,#string do
- table.remove(string, i)
- end
- table.insert(string, "<font size='18' color='#008000f'>Updated for the longest</font>")
- elseif cmd=="input" then
- ui.addPopup(0, 2, "<font color='#00800f' size='15.4'>Input</font>", playerName, 400, 50)
- end
- end
- function eventLoop()
- ui.updateTextArea(0, table.concat(string, "\n"))
- end
- function eventPopupAnswer(iD, playerName, ans)
- if iD==0 then
- table.insert(string, "<font color='#0880fe' size='16'><b>"..playerName.."</b></font> : <font size='16'>"..ans.."</font>")
- end
- end
- system.disableChatCommandDisplay("p", true)
- system.disableChatCommandDisplay("input", true)
- system.disableChatCommandDisplay("reset", true)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement