Monday, 3 February 2014

Meeting point: all graphicswindow event

GraphicsWindow.MouseMove = mousegerak
GraphicsWindow.MouseDown = mouseklik
'GraphicsWindow.KeyDown = tekankey
GraphicsWindow.TextInput = ejatext

Sub mousegerak
  TextWindow.Writeline("sumbu x: " + GraphicsWindow.mousex + " sumbu y: " + GraphicsWindow.mousey)
EndSub

Sub mouseklik
  If Mouse.IsLeftButtonDown Then
    TextWindow.WriteLine("Klik kiri ditekan boss...")
  Else
    TextWindow.WriteLine("Klik kanan bos...")
EndIf
EndSub

Sub tekankey
  TextWindow.WriteLine(GraphicsWindow.LastKey)
EndSub

Sub ejatext
  TextWindow.Write(GraphicsWindow.LastText)
EndSub

No comments:

Post a Comment