Code:
Procedure PlayDraw;
Begin
FrmMain.Repaint;
//Now blit them into screen combined for transparency effect.
BitBlt(FrmMain.Canvas.Handle, ShipX, ShipY, ShipMask.Width, ShipMask.Height, ShipMask.Canvas.Handle, 0, 0, SRCAND);
BitBlt(FrmMain.Canvas.Handle, ShipX, ShipY, Ship.Width, Ship.Height, Ship.Canvas.Handle, 0, 0, SRCPAINT);
End;
This is what i have atm ive tryed many various combinations of using InvaliDate, ReFresh and the Repaint method. This is the only one that seems to flicker less but still flickery. I also set the forms doublebuffered to true in the OnCreate event.
This procedure is being called in the OnKeyDown event of the form just checking for left keypress/hold for testing and it flickers pretty bad but not as worse as before lol.
Bookmarks