Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local mouse = {
- [1] = {buttonX = 1, buttonY = 2, command = "print('Hi')"}
- }
- local function she()
- shell.run("shell")
- end
- local function getMouse()
- while true do
- event, p1, p2, p3 = os.pullEvent()
- if event == "click" then
- for k, v in ipairs(mouse) do
- if mouse[k].buttonX == p1 and mouse[k].buttonY == p2 then
- print("hi")
- end
- end
- end
- end
- end
- getMouse()
Add Comment
Please, Sign In to add comment