Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local function parseConsoleInput(input)
- commandInput = {}
- for i in input do
- if(string.sub(i,1,string.len("S:"))=="S:") then
- table.insert(commandInput, i)
- elseif(string.sub(i,1,string.len("I:"))=="I:" then
- table.insert(commandInput, tonumber(string.sub(i, 3))
- elseif(string.sub(i,1,string.len("B:")) =="B" then
- bStr = string.sub(i, 3)
- if(bStr == "false") then
- table.insert(commandInput, false)
- else if(bStr == "true") then
- table.insert(commandInput, true)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement