Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Graphics 800, 600, 0, 60
- AutoMidHandle True
- Local img:TImage = LoadImage("test.png")
- Local angle:Int = 0
- Local textX:Int = -img.width / 2 + 10
- Local textY:Int = -img.height / 2 + 10
- Local imgX:Int = img.width * 2
- Local imgY:Int = img.height * 2
- While Not AppTerminate() And Not KeyHit(KEY_ESCAPE)
- Cls
- SetColor 255, 255, 255
- ' rotate
- SetRotation angle
- ' draw image at 0, 0
- DrawImage img, imgX, imgY
- ' draw text, calculating offset
- DrawText "Foo", imgX + Cos(angle) * textX - Sin(angle) * textY, imgY + Cos(angle) * textX + Sin(angle) * textY
- Flip 1
- angle:+1
- PollEvent
- Wend
Add Comment
Please, Sign In to add comment