setscreen ("offscreenonly")
var mx, my, btn : int
for i : 1 .. 100
drawfilloval (Rand.Int (0, maxx), Rand.Int (0, maxy), 8, 8, cyan)
end for
var picture := Pic.New (0, 0, maxx, maxy)
var picX, picY := 0
loop
Mouse.Where (mx, my, btn)
if mx < 50 and btn ~= 0 then
picX += 1
end if
if mx > maxx - 50 and btn ~= 0 then
picX -= 1
end if
if my < 50 and btn ~= 0 then
picY += 1
end if
if my > maxy - 50 and btn ~= 0 then
picY -= 1
end if
cls
Pic.Draw (picture, picX, picY, picCopy)
View.Update
delay (10)
end loop
|