summaryrefslogtreecommitdiffstats
path: root/src/plugins/factoids/sandbox.lua
blob: 282a903eec6ffe83338c837e1d2c4b6e5b85eeab (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
function send(text)
  len = #output
  if len < 1 then
    output = { text }
  else
    output[len] = output[len] .. text
  end
end

function sendln(text)
  send(text)
  table.insert(output, "")
end

local env = { print = send,
              println = sendln,
              args = args,
              input = input,
              user = user,
              channel = channel,
              request = download,
              pairs = pairs,
              table = table,
              string = string,
              tostring = tostring,
              math = math }

load(factoid, nil, nil, env)()