-
Images Overlapping
Hi guys,
I've written a game that has traffic moving across a road. The game has different levels, each one getting a bit faster, but as the game gets faster the images start to overlap each other.
This is the code I've used to move the traffic:
Code:
'Move Traffic on the Road
For l = 0 To NumOfCars - 1
imgCar(l).Left = imgCar(l).Left + CarSpeed(l)
If imgCar(l).Left > frmMain.ScaleWidth + (50) Then imgCar(l).Left = 0 - imgCar(l).Width: GoTo 200
If imgCar(l).Left < (0 - imgCar(l).Width - (50)) Then imgCar(l).Left = frmMain.ScaleWidth
200:
Next l
How do I stop the overlapping?
-
Could someone help me change my code around to use BitBlt. I haven't quite got the hang of it yet. If someone could show and explain changing the code above I should be able to do the rest.