I want to detect a mouse hit
why cant i detect a mouse hit ie:
case EVENT_MOUSEDOWN
mhit1=mousehit(1)
why cant i detect a mouse hit ie:
case EVENT_MOUSEDOWN
mhit1=mousehit(1)
SuperStrict Local MyWindow:TGadget=CreateWindow("Panel Example", 200,200,320,240) Local MyPanel:TGadget=CreatePanel(110,30,80,80, MyWindow, PANEL_ACTIVE) Local image1:TPixmap=LoadPixmap("Button_1.jpg") Local image2:TPixmap=LoadPixmap("Button_2.jpg") Local image:TPixmap = image1 Repeat WaitEvent() Select EventID() Case EVENT_WINDOWCLOSE End Case EVENT_MOUSEDOWN SetStatusText mywindow,"Mousebutton " + EventData() + " hit" Select EventData() Case 1 image = image2 End Select Default image=image1 End Select SetPanelPixmap MyPanel , image , PANELPIXMAP_CENTER Flip Forever