Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Blupi Bouncers! A Desktop Pet Game.  (Read 2331 times)

0 Members and 1 Guest are viewing this topic.

Me-Myself-And-I

  • Full Member
  • ***
  • Posts: 103
    • View Profile
Blupi Bouncers! A Desktop Pet Game.
« on: December 04, 2024, 03:12:30 am »
Hi all! I've been working on implementing winapi with an SFML window and have been having one success after another. For example: I've learned how to make a SFML window that supports dragging-n-dropping files into it. This specific time I have figured out how to make a transparent window that allows clicking through it where there is no color.

This is the code I used to accomplish a transparent window:

    WindowHandle handle = mainwindow.getSystemHandle();

    SetWindowLongPtrA(handle, GWL_EXSTYLE, WS_EX_LAYERED | WS_EX_TOOLWINDOW);//Most important to set the window as WS_EX_LAYERED to allow the third function "SetLayeredWindowAttributes".
   
    SetWindowPos(handle, HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE);//This is just to set the window on-top of other windows. Not necessary
   
    SetLayeredWindowAttributes(handle, RGB(255, 0, 255), 0,LWA_COLORKEY);//The color purple is chosen to be removed from the window. The last thing to do is clear the window with the color purple.

   


 



Blupi Bouncers is a fangame for the 90's game "Speedy Eggbert". It features the ability to play around with many different modes and types of blupis on your desktop like a desktop pet. The number of blupis you can have on your screen is only limited by your computers performance. Don't worry though. The program doesn't freeze your computer if it can't handle a bunch of blupis.




I have Blupi Bouncers on itch.io and the source code is on github for anyone who's interested.

https://fishleteer.itch.io/blupi-bouncers

https://github.com/Happy-Flappy/Blupi-Bouncers
 

 

anything