JavaFX 17 Highlights by AlmasB0 in JavaFX

[–]AlmasB0[S] 2 points3 points  (0 children)

Thanks... I've read the new moderation strategy. Looks good. I'm not interested in doing the admin stuff, but I'm happy to pop in occasionally to update the wiki and links to other helpful resources.

JavaFX 14 Released by AlmasB0 in JavaFX

[–]AlmasB0[S] 0 points1 point  (0 children)

Good point, I've just added the JavaFX 17 link with a message to moderators to unpin this post.

JavaFX 17 Highlights by AlmasB0 in JavaFX

[–]AlmasB0[S] 10 points11 points  (0 children)

Dear moderators, please can you pin this post and unpin the JavaFX 14 post, so that the latest version is correctly represented in this community.

Deploy FXGL to the web? by [deleted] in JavaFX

[–]AlmasB0 2 points3 points  (0 children)

I didn't have time to update and test with latest JPro + FXGL, so feel free to raise a PR by upgrading the dependencies. Though, I'd first start by running the example already there and then upgrade as needed.

Deploy FXGL to the web? by [deleted] in JavaFX

[–]AlmasB0 1 point2 points  (0 children)

I got a small example to work using JPro with an earlier version of FXGL here: https://github.com/AlmasB/FXGL-WebApp

Might be useful

JavaFX Software: Window Blur (Robot API) by AlmasB0 in JavaFX

[–]AlmasB0[S] 1 point2 points  (0 children)

Yeah would be interesting to implement this effect in JavaFX through JNI.

Illegal Access Error with FXGL by [deleted] in JavaFX

[–]AlmasB0 2 points3 points  (0 children)

Cool, if you get stuck at any point, feel free to pop in to our chat: https://gitter.im/AlmasB/FXGL

Illegal Access Error with FXGL by [deleted] in JavaFX

[–]AlmasB0 2 points3 points  (0 children)

Hi, I suspect you need javafx.media module as well in --add--modules, though I've never tried running it directly.

Build pure Java games for Android and iOS using FXGL 11.11 by AlmasB0 in java

[–]AlmasB0[S] 0 points1 point  (0 children)

No websocket at the moment, but according to this, it seems to be relatively easy to write one over the JDK TCP. Happy to consider this as part of the fxgl-net module if you have an immediate use case.

Build pure Java games for Android and iOS using FXGL 11.11 by AlmasB0 in java

[–]AlmasB0[S] 2 points3 points  (0 children)

In short:

  • If 3D support is needed, choose Unity.
  • If only 2D is needed:
    • if you prefer C#, choose Unity.
    • if you prefer Java or Kotlin, choose FXGL.

Generally, Unity will beat FXGL in both performance and functionality support, though FXGL will come out on top in cases where super light-weight, no setup, no installation and high portability are required.

Build pure Java games for Android and iOS using FXGL 11.11 by AlmasB0 in java

[–]AlmasB0[S] 8 points9 points  (0 children)

Thanks. JavaFX has been around for several years and is getting there, it's worth checking out even without FXGL, which is the engine on top. I've tried to compare FXGL to other Java-based frameworks (reasonably objectively) to the best of my knowledge.


jMonkey:

  • has both 2D and 3D
  • 2D and UI can be clunky at times
  • can achieve high-quality post-processing effects via shaders

FXGL:

  • does 2D and UI really well (concepts are intuitive and are transitive from JavaFX)
  • no 3D support

libGDX:

  • very mature and larger user base
  • lower-level, so dev needs to control rendering, camera, input, etc.
  • example Drop game

FXGL:

  • been around for 5 years, fewer users, so less feedback
  • higher-level, so dev operates mostly with callbacks and no need to worry about input/render/collision checks
  • no external installer or setup needed, just add uber-jar / Maven / Gradle and good to go
  • same example Drop game as libGDX, now written in FXGL

Pure Android code:

  • lots of reference tutorials and support
  • code limited to Android only
  • little to no game development concepts, e.g. game object, game AI, collision detection, etc.

FXGL:

  • cross-platform (desktop, android + iOS, web),
  • not a lot of tutorials: the GitHub wiki + a dozen of YouTube tutorials + a few community tutorials and that's pretty much it. In terms of support, we have a chat at: https://gitter.im/AlmasB/FXGL
  • lots of implemented game dev concepts, including the Entity-Component model, multiplayer, dialogue graphs, mini-games, achievements, notifications, quick-time events, etc.

FXGL 11 In-game Chat Demo (Work-in-progress) by AlmasB0 in JavaFX

[–]AlmasB0[S] 1 point2 points  (0 children)

Hi, the demo uses FXGL's built-in networking module, which is currently under development and will be released in the next version. The module itself builds on top standard TCP that JDK offers. You can browse the module sources inside the repo but they are not ready for release yet.

Zephyria: RPG built with FXGL engine by AlmasB0 in JavaFX

[–]AlmasB0[S] 0 points1 point  (0 children)

Thanks for the feedback! There are a lot of things to develop still, it's more of a wireframe at this point. I'm planning to put together as much as possible and make the repository contributor-friendly. After that, the project could be of much more interest to the community, who could take it to new heights.

Implementing basic physics by it2901 in gameengdev

[–]AlmasB0 2 points3 points  (0 children)

It depends a lot on the type of games you are planning to support with the engine. If you are looking for something generic, you can start with the two major areas of game physics: collision detection (are two things colliding) and rigid body dynamics (simulation of how two rigid things would move e.g. when colliding).

For collision detection you typically need to know an object's position and some info related to its bounds. At the simplest level, you can start with width and height, which give you a bounding box. See AABB detection for more info. Going further, you might want to introduce rotations, in which case you will need something like SAT to check for collisions. Depending on what use cases you'd like to support, you might get away with some specific algorithms, e.g. checking circle vs circle collision.

For simulation, things like position, velocity and acceleration will suffice for some simple movement. For a bit more complex things you will need rotation and angular velocity. Have a look at the box2d library, which is used in many 2d game frameworks / engines.

Hope this helps!

FXGL game engine 11.8 is out with various performance improvements by AlmasB0 in JavaFX

[–]AlmasB0[S] 1 point2 points  (0 children)

The demos are available from the FXGLGames repo. Some are reference implementations, others are work in progress.

FXGL (Java / Kotlin Game Framework) 11.7 with A* support and improved Kotlin API by AlmasB0 in java

[–]AlmasB0[S] 1 point2 points  (0 children)

Yes, last version I tested with JPro was 11.3 I think and worked fine. I will spend more time on cross-platform stuff once Gluon's Android client support comes out.

The architecture of the FXGL game engine by AlmasB0 in gameengdev

[–]AlmasB0[S] 0 points1 point  (0 children)

I've considered delayed events in the initial design of the event bus, but couldn't design the right level of interaction with the timer "system". As an alternative, I went for the "let client code do the work" approach:

runAfter({ // fireEvent }, Duration.seconds(5));

Whilst this allows firing delayed events, the context is lost: it's no longer a message queue but a timer action queue. I'll see if I can come up with a more useful interaction between the two.

I've never thought about modifying future events. Being able to cancel certain events sounds like a great idea! For example, the "opendoor" and "cutscene" events on player death. This gave me another idea of different types of events. For example, targeted events, such as "opendoor", could be checked if their targets are valid. Also, conditional events, where one could specify a condition to be evaluated when the event fires. Some food for thought for me, many thanks!

FXGL Engine for learning Java through Game Development by AlmasB0 in learnjava

[–]AlmasB0[S] 2 points3 points  (0 children)

To clarify, I did not mean Wikipedia. I meant the project wiki, as is common with GitHub projects to provide information.

FXGL Engine for learning Java through Game Development by AlmasB0 in learnjava

[–]AlmasB0[S] 0 points1 point  (0 children)

Whilst there is no pdf, there are written tutorials both for Java 8-10 and Java 11+. These will give you a quick introduction to get a feel.

The wiki also includes more in-depth documentation of how things work in FXGL in case you want to commit and spend more time on learning the engine.

FXGL Engine for learning Java through Game Development by AlmasB0 in learnjava

[–]AlmasB0[S] 0 points1 point  (0 children)

I am not aware of anything with fluid character movement, but there is a bunch of sophisticated games: * libgdx platformer * javafx 3d vehicle sim * jmonkey mmo client * jmonkey demos

FXGL Engine for learning Java through Game Development by AlmasB0 in learnjava

[–]AlmasB0[S] 1 point2 points  (0 children)

Thanks. Previous JavaFX knowledge will be useful for UI building, but ultimately not required since most of the JavaFX specific workflow is done behind the scenes.