QB64 Phoenix Edition
2d Physics Engine - Pool Demo - Printable Version

+- QB64 Phoenix Edition (https://qb64phoenix.com/forum)
+-- Forum: QB64 Rising (https://qb64phoenix.com/forum/forumdisplay.php?fid=1)
+--- Forum: Code and Stuff (https://qb64phoenix.com/forum/forumdisplay.php?fid=3)
+---- Forum: Works in Progress (https://qb64phoenix.com/forum/forumdisplay.php?fid=9)
+---- Thread: 2d Physics Engine - Pool Demo (/showthread.php?tid=5)



2d Physics Engine - Pool Demo - justsomeguy - 04-16-2022

This is yet another physics demo I wrote a while back that is a minimal implementation of a Pool game.

It currently has a poorly implemented multiplayer. Its currently setup only for local host, but that can be changed in "poolSceneBuild.bas"



All assets were CC0.


RE: 2d Physics Engine - Pool Demo - justsomeguy - 04-17-2022

I've added a screenshot of the the game.


RE: 2d Physics Engine - Pool Demo - bplus - 10-23-2022

This is a huge effort! A whole folder system of files. Fun to compare to my 600+ LOC and one lonely bas source file ;-)) Looks like yours can do English, very fine!

You definitely have a better looking cue stick! But I am using a different way to aim cue, down the path with cue ball size circle to see exact place of contact.

That's a power bar below the table.


RE: 2d Physics Engine - Pool Demo - justsomeguy - 10-23-2022

I suppose it was, but I'm shooting for a more general purpose engine that I will use for multiple projects.

It started out as a huge monolithic program, but code organization became an issue, and IDE got laggy.


RE: 2d Physics Engine - Pool Demo - justsomeguy - 10-27-2022

@bplus I like you work on the pool game, Is it playable?


RE: 2d Physics Engine - Pool Demo - bplus - 10-27-2022

You can hit balls into pockets and it will rerack when last ball down but there is no game because no opponent to play against.

Did you manage to figure out how to aim and shoot?

I thought it much easier to code drawing the cue line directly towards the way you want the cue ball to go, I did same with a bowling game.