Jump to content
Sign in to follow this  

ProSpeed problem with .png flickering

Recommended Posts


Hello :) Im making some "little" project, It will be a port of old "Tank" game (hmmm, better to say CLONE not port B) ). Im using a ProSpeed library to graphic engine, i have maked a map editor/reader system of tilesets and mooooore. But im still having problem (I had it from the beggining, yesterday B)) with moving sprites over my map, because i created them using .png tiles( it was much simplier and look alot better) my sprites are flickering when they are moving, it is connected with the fact that im making it thais way:

(x: -line number in source)

70:CreateBuffer(800, 600)
95:PaintPng(6, $hdc, 29 + $loop, $y1, $clouds1,0)

And in moment when I had already used a PaintNew and before function PaintPng() it is few ms interval, and the engine is rendering only the image from buffer (which was created with map creation anddont contain my sprite). Only solution I can see in this moment is having two Buffers but I'm not sure how to make this work. Im Attaching a youtube vide of my problem ;)

(The low framerate is result of my HyperCam problems, not game itself)


Posted Image

Share this post

Link to post
Share on other sites

As far i can see it's not a wm_Paint issue.

I think the sprite function wants to render a frame that not exist in your png.

Sprite($S_Spriteplane, $S_Destination, $S_offsetX, $S_offsetY, $S_WIDTH, $S_HEIGHT, $S_FRAMES, $S_START_FRAME, $S_FRAME_SPEED, $S_posX, $S_posY)

make sure if you are using a static png as sprite, that the $S_FRAMES para is 1 and $S_START_FRAME is allso 1



Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this