Post

vbPixelGameEngine

Announcing vbPixelGameEngine!

What is vbPixelGameEngine?

vbPixelGameEngine is a simple, cross-platform, prototyping and game engine framework. The project itself if very much inspired by olc::PixelGameEngine and the videos from @javidx9. However, these videos (as is the original project) are all utilizing C++; and I, of course, want to follow along using VB. This this project was born.

And, yes, it is also cross-platform! Working with Visual Studio on Windows 11 and being able to press F5 to launch and debug a Linux graphical application (via WSL2) is amazing! And having something like this project now makes it possible to actually build cross-platform graphical applications with very little overhead.

As the project continues to progress, it will strive to maintain some level of compatibility with olc::PixelGameEngine as do really think that his videos are amazing and do recommend watching all of them; and now you can follow along with what he is sharing using VB… a luxury that I didn’t initially have.

With that said, I am also making some improvements to the API to make it, well, “more VB” and certainly welcome any suggestions that one may have along these lines.

Examples

There are a handful of examples already available and many more will be coming in the near future…

Image 02

The first example has a few different “modes” that demonstrate the following:

  • Repeatedly filling the screen with random colored pixels.
  • A screen that shows a color swatch.
  • Moving a block around on the screen using the keyboard.
  • Having a glyph follow the mouse cursor as well as displaying a box based on current mouse button state.

Image 03

The second example demonstrates the process of creating a random maze and animates the process so you can see it visually.

Image 04

Samples seem incomplete if there isn’t one demonstrating John Conway’s Game of Life.

Image 05

So the current examples that I’m working through were originally done based utilizing vbConsoleGameEngine / olc::ConsoleGameEngine. So although many of these examples are “low-res”, they serve to demonstrate different game mechanics, algorithms and approaches - so I really didn’t want to leave these in the dustbin. Instead, I’m working through converting these to vbPixelGameEngine - leaving things as much as possible “as-is”. However, in the case of this particular example I had to make several changes in order to port it. The screen resolution is much higher mostly due to the drawing of the text on the screen; so some of the “retro” has been lost. With that said, it’s not too hard to reduce the resolution - but the diagnostics on the screen would need to be removed and the “car” would need to be replaced with something else.

In any case, these are just a handful of the examples available… however, I’ve started compiling a list of the future ones on the list and this list is already at 33 entries (and the list is currently incomplete).

If you’d like to see one of these examples sooner rather than later, feel free to reach out to me to request it being bumped up on the priority list; otherwise I will be working on them in their original order.


And with all of that said, I’d also like to share that it is now possible to Sponsor me; please consider doing what you can to help me reduce the associated wife-agro with me working on projects like this. To see a list of some of the active projects, please check out my GitHub profile.

This post is licensed under CC BY 4.0 by the author.