This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
Kouksi44's profile picture

mouse event not working

Started by Kouksi44, 12 August 2014 - 02:31 PM
Kouksi44 #1
Posted 12 August 2014 - 04:31 PM
Hi,

my Problem seems to be , that I am unnable to get the example code from the wiki about the "mouse_click" event working…

This is the code:

while true do
  local event, button, xPos, yPos = os.pullEvent("mouse_click")
  print("Mouse button clicked: ", button, " => Click Position X: ", xPos, " => Click Position Y: ", yPos)
end

Every time I c&p this code and execute the code the computer shows nothing on screen as if it was listening for the event, but even if I click several times nothing shows up :(/>

I really don´t get what I am doing wrong ?

Thank you in advance

Kouksi44
Lyqyd #2
Posted 12 August 2014 - 04:41 PM
Are you using an advanced computer?
Kouksi44 #3
Posted 12 August 2014 - 04:42 PM
No I don´t. I am using a normal Computer.
Lyqyd #4
Posted 12 August 2014 - 04:44 PM
Normal computers do not support mouse interaction. You will need to use an advanced computer.
Kouksi44 #5
Posted 12 August 2014 - 04:58 PM
oh okay :)/> thank you !