Java-Gaming.org Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (796)
Games in Android Showcase (234)
games submitted by our members
Games in WIP (864)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1] 2
1  Java Game APIs & Engines / JavaFX / Re: JavaFX blend effect using only one node (canvas) on: 2019-07-19 16:05:03
@philfrei That does work for normal Nodes, but things are a bit different for the Canvas.

@pavul Any reason why you use a Canvas? That's slower and not really better to handle IMO.
Anyway, you can set BlendModes: https://openjfx.io/javadoc/11/javafx.graphics/javafx/scene/effect/BlendMode.html in your GraphicsContext: https://openjfx.io/javadoc/11/javafx.graphics/javafx/scene/canvas/GraphicsContext.html

Perhaps that would help you? E.g. drawing a mask image with a certain blend mode to create a fade effect, or light effect, or whatever.

Cheers
2  Games Center / Showcase / Re: FruityFrank - A game about a fruity adventure. on: 2019-07-07 09:38:55
Did you make the art yourself? I really love the background art. Similar to what I eventually want to have for tritonforge

Thanks, I did 90% of the art myself using GIMP, Krita and Blender (with a "pixel art compositor setup" Smiley ). But I got most of the backgrounds from OpenGameArt.org, only adapted some parts of them. They work really well for parallax backgrounds
3  Discussions / Miscellaneous Topics / Re: What I did today on: 2019-07-06 13:24:48
Finally released my game FruityFrank!

Cheers
4  Games Center / Showcase / Re: FruityFrank - A game about a fruity adventure. on: 2019-07-06 08:23:58
Thanks for the feedback!

Took me a while to get it to run. I have JDK 12 installed but I also had JRE 8 installed, which apparently is the latest JRE version?
I thought this is what you should install if you want to run java programs, after all it's the first result you get when you google "java download" so why is the version so old? Odd.
That's probably because OpenJDK is the new Java distribution of choice, as Oracle changed to a fuzzy licensing model.

Quote
Anyways, now I know that the JDK includes its very own runtime environment and you don't need JRE at all, you learn something new everyday.
I don't think most people will go through the hassle of getting their java installation in order, so you should really consider bundling a runtime environment with the game if you want people to play it.
Well, it runs on my machine!  Grin
Noted, additional packaged builds are underway now. Of course, most people are not going to install an up to date Java first, thanks for the broad hint.

Quote
I understand this was a project you used to experiment with things, and actual game design was not your priority, so I'll just say it was a cute game Smiley Got as far as level 16 before my patience ran too thin
Wow, level 16 is quite far for playing the first time. For me it isn't that much of a problem, I guess it's the "master of my own universe" phenomenon… played those levels hundreds of times, basically. The trick is to hold the jump key for a medium amount of time when below the spikes…  Wink

Thanks for saying nicely that the game lacks good design, I'm a bit aware of that as it really wasn't that much of a priority and I scrapped quite a few mechanics that weren't really fun, basically cut it down to a bare minimum. But the levels themselves have design (or are supposed to, anyway).

Cheers

EDIT: Packaged builds are now up for ease of running.
5  Games Center / Showcase / FruityFrank - A game about a fruity adventure. on: 2019-07-05 05:59:58
Hello guys!

I'm happy to announce that I've finally finished my platformer game that I've been working on for nearly 3 years now. Without occiasional development pauses and some better technology choices it probably would've taken around 1-2 years. For example, I wrote the level editor with a Swing GUI first, but then switched over to JavaFX. Also, a few months into the project, I wrote a custom ECS engine which also wasn't necessary, as there are a few pretty good open source ECS libraries out there. Later, I decided to implement my own markup language (inspired by TreeML and JSON), a thing that also wasn't necessary. These things probably cost me lots of motivation for the project. But now it's finished, so that doesn't matter anymore.  Smiley

The only library used is JavaFX/OpenJFX.

Description
Embark on the adventure of an apple called Frank, in a world full of living fruits.

The game is inspired by classic games like Mario, it even shares a main feature: The story is quite gentle, but the game gets really hard.

An indie game made using exclusively open source tools.

Feel free to leave feedback or report bugs in the comment section, it's highly appreciated.


v0.4.8

Screenshots






Download on itch.io. Instructions are also there.

Have fun playing, feedback is welcome!

Cheers

@ mods: You can move this game to featured if you want to, as it fulfills the rules and it's finished.
6  Games Center / Showcase / Re: Dust : The Abandoned Land -- Released after ~ four years of development! on: 2019-04-13 08:57:15
Congratulations to the release, a lot of work seems to have gone into this project.

There's a lot of detail and depth in there (didn't play too long though), very nice. The mood is also very fitting, you really get this feeling of isolation, need for survival etc. Smiley

The standard controls are absolutely horrible to be honest, just as @VaTTeRGeR It would be much better if they were similar to other games and user interfaces. This makes you insecure in stress situations where you quickly want to hide in a building and have to remember which sequence of keys you have to press to e.g. unlock, open, close and lock a door.

But overall - good job.

Cheers
7  Discussions / Miscellaneous Topics / Re: What I did today on: 2019-03-30 19:12:00

And there you have it folks. ClearDialogue.

Here's a short list of improvements this version has just by merely existing:

  • Uses the Clear backend: making the general architecture of the program much more mechanically sound than it was by using JavaFX
  • The text editing tools were made 100% by me, so it's not only stable, but future-proof. Bugs can be fixed, new features can be added, and it's not a pain in the ass to use. I also tried to keep performance in mind as I made it to prevent any resource leaks that are common with these things
  • The code for the pannable canvas and pannable nodes are much more clean and all use one coordinate system (versus JavaFX shoehorning in like 3)
  • The layout system has both systems for making quick grid-based layouts, but also lets you placed them 100% manually if you wish. Both can be used simultaneously with no bullshit
  • All of this is open source and heavily documented for anyone to use

I'll be making a project page for the following:
  • ClearDialogue - a lightweight API that allows for easy to manage branching game dialogue
  • ClearDialogueIDE - a user interface that lets you make branching dialogues for ClearDialogue
  • ClearVG - a graphics wrapper for NanoVG that makes it easy to make UIs for your programs. Includes a functioning TextArea with syntax highlighting, line numbers, special character support, and much more
  • ClearWindows - a LWJGL3 windowing wrapper using tech from NNGINE (though with some features stripped down to keep it simple). This can be used independently for quickly setting up an LWJGL3 context for any project.
This ballooned way out of control considering I just wanted to add some basic features to JDialogue originally, but here we are. This should keep me from ever having the issues that lead me here to begin with again. And maybe these tools will help some of you guys too.

Very nice, thank you for your great contribution to the ever growing pool of well-made free open source software. Smiley

Finally found some time to work on my game again over the last few days. Fixed some bugs, created a tutorial level, mainly animated and polished some enemies with Blender. After that I rendered them out as pixel art. This workflow works quite well for me, after a bit of initial setup (a blend file with the necessary camera and compositor setup to have 1bit alpha). … except for some difficulties with Blender that I've yet to sort out  Tongue. Hope I'll be able to finish it soon.

Also had a closer look at the Godot engine. It's basically on the way to become the Blender of game engines. Very feature packed, rapid development, good community, a quite flexible concept of building games… really neat. Though it has nothing to do with Java at all Cheesy

Cheers
8  Game Development / Shared Code / Re: JavaFX Invaders game on: 2019-03-30 18:59:54
Yes, creating a .jar with Java 11 and JavaFX is kind of involved. And even after installing both, it also requires a rather more complicated console line than the classic "java -jar programName.jar". Also, the locations of the java and javafx modules and runnables are not necessarily going to be the same for everyone's install, so writing a .bat or .sh is problematic.

Why am I supposed to know all the modules my application needs and type them into the command line? In other words: What's the best way to automate this (e.g. with IDE or without).

Quote
I tried to copy and run the code (I have the 11-split handled) but when I did the paste, the line numbers came over making the code unrunnable.

Select the text starting at the first letter of the code, i.e. the "i" of import Pointing

Cheers
9  Games Center / WIP games, tools & toy projects / Re: The Vehicular Epic on: 2019-03-29 09:57:48
UPDATE:

The game's source code is being completely rewritten in plain English

That's amazing! Cheesy It was provoking brain cancer if I tried to browse your code otherwise.

Quote
I've already updated some of it for the current build. Hopefully, everything will be renamed by the next build.

I can only agree with @Archive .

Cheers
10  Discussions / General Discussions / Re: Why do old games break? on: 2019-03-25 10:01:31
Back to the future is quite cool, used to play it when I was younger Cheesy

You don't have to use the original hardware though, there are plenty of emulators out there for all the retro guys, for example MAME which emulates most of the old machines pretty well.

Cheers
11  Discussions / Miscellaneous Topics / Re: What I did today on: 2019-02-26 15:55:17
Re-created the JavaFX modena example:

[…]

This is amazing, keep up the good work. Always used the Modena example to test out things Smiley

I can only guess how much work had to go into this project to get it to the point where you have it now…

Cheers
12  Discussions / Miscellaneous Topics / Re: What I did today on: 2019-02-06 16:35:10
I got a job at Volition.  Pretty happy about it.

You mean this Volition?
If so, congrats.

Cheers
13  Discussions / Miscellaneous Topics / Re: What I did today on: 2019-01-20 15:12:15
Guess which one I made in blender Tongue :

Click to Play


Click to Play


Cheers
14  Discussions / Miscellaneous Topics / Re: What I did today on: 2019-01-13 16:32:04
Had some time today and fixed lighting with transparent objects:

You're making amazing progress with your engine (or should I say "little Unity competitor" Wink).

Over the last few days I implemented various optimizations into my platformer game, e.g. an easy quadtree-like structure to simplify collision detection. You're supposed to optimize your code when it's pretty much done, right?

Now coming to easier/ more fun phase of development: creating more levels, finishing story, art (well, not that fun), fixing the occasional bug, etc.

Cheers
15  Game Development / Newbie & Debugging Questions / Re: lwjgl 2.9.3, mini2dx on raspberry pi unsatisfied link error on: 2019-01-13 09:49:58
@KaiHH Raspbian is only 32bit ATM, so using the Arm64 packages from the Debian repos will most probably not work.

@torbuntu Probably compiling it yourself is the best option. Smiley

Cheers
16  Discussions / Miscellaneous Topics / Re: How to prevent device's communication on: 2019-01-08 09:13:59
@berzas You should *probably* ask this on a tech support forum where people can actually help you. This is a java game dev forum with ~20 active members persecutioncomplex

Also please look up some words in a dictionary, we have serious problems trying to understand what you're saying.

Generally using hardware (e.g. cork or tinfoil) to solve software problems is not a good way to go Wink This sound to me like you have some kind of hotspot turned on to which the IPhone automatically connects.

Cheers
17  Discussions / General Discussions / Re: 5 year project history on: 2018-12-01 16:01:10
These are some quite nice overviews, thanks for sharing.

But @LiquidNitrogen: finishing stuff is also very important. It gives you a feeling of accomplishment. Otherwise some people tend to "burn out", losing motivation.

Cheers
18  Discussions / Miscellaneous Topics / Re: What I did today on: 2018-07-23 19:17:28
I'm working on my evil god simulator, Infiltration here

Hm, the city/god names sound like the "Elvish" language in Lord of The Rings, however the Elves usually were not evil.

Today I ironed out some hard to find bugs in my game, though there are still some left.
And now the only "big" feature left to implement are bosses. My AI system is pretty solid, but bosses pose new challenges for it. Smiley Does anyone have a few tips about what would be a good approach or pitfalls to avoid?

Cheers
19  Java Game APIs & Engines / Engines, Libraries and Tools / Re: 3d framework for a retro flight sim on: 2018-07-22 14:16:18
You're right, JavaFX's rendering capabilities are indeed very limited. They don't go beyond a simple phong shader, actually. It's more a UI library, not a game engine.
So if you want a high level, but still customisable 3D engine, use JMonkey. But it might be less active and have a smaller community than Libgdx. The latter however is not as good as JMonkey when it comes to high level 3D, some features are missing or badly documented etc.

I personally like the non-3D related features of Libgdx more than the ones of JMonkey. Like the 2D, filesystem, sound, resources/assets API and so on.
So in the end it depends on whether your graphical demands are high. Does "retro" mean retro graphics as well? Smiley

Cheers
20  Discussions / Miscellaneous Topics / Re: What I did today on: 2018-07-19 12:59:20
Anyone know a nice source of 32x32 application icons? The ones I’m using are only 16x16 so they don’t look great on higher resolutions.

If you have a *buntu Linux installed, you can find loads of icons in "/usr/share/icons/…", all application icon related stuff you could possibly want. I usually search for keywords in filenames in all of the folders recursively to find what I need. Otherwise have a look at e.g. the Xfce icons https://github.com/shimmerproject/elementary-xfce. I didn't find a better resource for now, but all the icons of the free desktop environments are under some kind of open license, so you could try to do some research in this direction.

Cheers
21  Discussions / Miscellaneous Topics / Re: What I did today on: 2018-07-17 19:31:45
Could be the way cpus often have 2 logical cores per one physical core. Your ‘number of cores’ probably gives physical cores, not logical cores.

As I said, on my CPU the physical cores are equal to logical ones. I retrieve them with
1  
Runtime.getRuntime().availableProcessors()


What are those maps exactly? How did you load them before?

They are text files with my own, custom markup language (similiar to JSON), and they essentially contain a list of objects of the same type. These objects represent Java classes, and I can define the values for the variables of a certain class etc. Now I read that file and parse it, and then I create instances of the classes and set the variables with the Java Reflection API. That is slow already, and my parser is not the fastest either.
Example for one entry in my entity template file:

[Entity] {
   name="Jumper"
   components={
      [PhysicsComponent] {
         mass=1.15
      }
      [MovementComponent] {
         maxVelo=2.2
         maxAcc=0.1
         jumpPower=1.4
      }
      [CollisionComponent] {
         box=[Hitbox] {
            width=32
            height=40
         }
         mask=All
      }
      [RenderComponent] {
         ...
      }
      ...
   }
}

Now when I had a few thousand entities in one map, the parser could only use one CPU core, which was inefficient. So I split the list of entries and and create threads of which each one parses a part of the list.
That is how I load my maps Smiley

Cheers
22  Discussions / Miscellaneous Topics / Re: What I did today on: 2018-07-17 14:49:28
Today I worked on parallelized map loading for my game. It always took very long to load maps (my reflection-based approach is actually slow, but anyway) and made debugging and testing uncomfortable. Now my idea was to split a map file into as many parts as CPU cores available on the system when loading it. This worked and it was already ~200%  faster, however it turned out to be even faster when using a number of threads two times the number of CPU cores (now 300-400% faster than the serial approach).

Here is the output of a testing run with a few runs for each method. You can also see the JVM HotSpot in action for both methods (it's getting faster):

Serial: 1.227s
Parallel: 0.847s
Serial: 1.626s
Parallel: 0.198s
Serial: 0.675s
Parallel: 0.174s
Serial: 0.636s
Parallel: 0.145s
Serial: 0.614s
Parallel: 0.130s


Does anyone have an explanation why it's faster to use "number of cores x 2" threads? There's no hyperthreading involved on my CPU. Also had a look at it in the profiler, but couldn't see anything suspicious.

Cheers
23  Discussions / Miscellaneous Topics / Re: What I did today on: 2018-07-16 09:17:52
The pathfinding is in a working state now Cheesy

[…]

It takes like ~2 milliseconds each to calculate these paths (and post process them), which is not that bad considering i threw ArrayLists, bloated objects and comparators at it. Also there's no quad-tree or gridmap to rule out objects before doing collision checks, so i'm pretty confident that i can get it down to <10% of the current calculation time.

That's a good start I guess. And I like those little Tiger tanks you have there. You always seem to be doing WWII stuff, huh? Wink

Yesterday I realized that it would've been a good idea to decouple the game logic and the rendering in my game. The problem with this is that I do all the work on the JavaFX thread, and that slows everything down, e.g. the profiler shows that some "waitForRenderingToComplete" method takes half of CPU time Shocked (with GPU load being very low, so it definitely is the game logic that blocks the rendering). Then I tried to make it two threads, but that didn't work as it should because of my messed up code. I'll leave it like it is and hope that people who play it have fast enough CPUs…

But I've learned and am still learning from my mistakes. Before doing my next poject I'll read Game Programming Patterns closely. It helps a ton for unexperienced programmers like me. And I'll make at least one prototype before starting to code the real game next time.

Cheers

P.S.: I definitely won't use JavaFX for a game again.
24  Discussions / Miscellaneous Topics / Re: What I did today on: 2018-06-13 13:37:37
While it might not seem like much, I implemented an OpenGLPane.
[…]
It combines the previous thing I did where I implemented a easy-to-access rendering path, but it extends a StackPane element. This will allow me to use direct OpenGL calls to this pane, but it will respect all of the sizing/layouts of the UI system automatically.

This is already much more than JavaFX will ever be able to do, despite many people having suggested to open up the OpenGL API inside of JavaFX to the programmers. This is due to Oracle having lost interest in the project a few years ago, when they saw they couldn't get the wide adoption they'd hoped for. So they decided to kick it out of the JDK in the future.

Cheers
25  Game Development / Game Play & Game Design / Re: Data structures for loading huge tilemaps on: 2018-06-09 15:56:29
For really large maps (much more than 2000x3000, because that's not very much, actually), you might run into problems when traversing between two of your big "world chunks", because you would have to load both of them. What about having a variable number of smaller chunks with a fixed size that are lightweight to load, update and render at the same time?
IIRC Minecraft also has very small chunks compared to the world size.

Cheers
26  Discussions / Miscellaneous Topics / Re: Microsoft confirms it’s acquiring GitHub for $7.5 billion on: 2018-06-09 15:49:39
I don't like this move of Microsoft at all…
As always, they're probably following the same strategy "embrace, extend, extinguish" with Github as they did with so many other projects/organizations.
Very interesting read here: https://jacquesmattheij.com/what-is-wrong-with-microsoft-buying-github

Cheers
27  Games Center / WIP games, tools & toy projects / Re: The Vehicular Epic on: 2018-06-01 12:52:44
Nearly all of the track pieces should be textured. Many of the vehicles have textures as well. Also there should be image textures in the game's 'images' folder.

Alright, I've investigated a bit more.

There are actually images in the folder, and I also had a look at the source code. I think that the paths to your images are not working, at least on Linux.

I always wondered why there was no exception, it seems they're turned off by default. So I enabled the switch "-Dprism.verbose=true" and I got exceptions, namely the following (first one):
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
java.io.FileNotFoundException: images/Water.jpg (File not found)
   at java.base/java.io.FileInputStream.open0(Native Method)
   at java.base/java.io.FileInputStream.open(FileInputStream.java:220)
   at java.base/java.io.FileInputStream.<init>(FileInputStream.java:158)
   at java.base/java.io.FileInputStream.<init>(FileInputStream.java:113)
   at java.base/sun.net.www.protocol.file.FileURLConnection.connect(FileURLConnection.java:86)
   at java.base/sun.net.www.protocol.file.FileURLConnection.getInputStream(FileURLConnection.java:184)
   at java.base/java.net.URL.openStream(URL.java:1117)
   at javafx.graphics/com.sun.javafx.iio.common.ImageTools.createInputStream(ImageTools.java:486)
   at javafx.graphics/com.sun.javafx.iio.ImageStorage.loadAll(ImageStorage.java:311)
   at javafx.graphics/com.sun.javafx.tk.quantum.PrismImageLoader2.loadAll(PrismImageLoader2.java:127)
   at javafx.graphics/com.sun.javafx.tk.quantum.PrismImageLoader2.<init>(PrismImageLoader2.java:71)
   at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.loadImage(QuantumToolkit.java:735)
   at javafx.graphics/javafx.scene.image.Image.loadImage(Image.java:1052)
   at javafx.graphics/javafx.scene.image.Image.initialize(Image.java:802)
   at javafx.graphics/javafx.scene.image.Image.<init>(Image.java:618)
   at VehicularEpic.<init>(VehicularEpic.java:269)
   […]

Having a look at line 269 of your source code, it says
1  
Image wtr = new Image("file:images/Water.jpg") […]

And that seems to be the culprit.
Loading images the following way works on all platforms (from outside the Jar):
1  
Image img = new Image(new FileInputStream("images/Water.jpg"));


Performance is still good, even on larger maps.
I don't know how you manage to maintain your code with this weird assembly-style naming and everything crammed into one file – with networking and all the other stuff… Huh
And one last thing: In this "Underwater" map there's weird flickering of the graphics everywhere, no matter if inside the water or not.

Cheers
28  Game Development / Articles & tutorials / Re: Getting Started with JavaFX Game Programming (for Java Programmers) on: 2018-05-30 13:47:01
Sorry that didn't work, can't edit my posts either:
AnimationTimer:

Timeline:
29  Game Development / Articles & tutorials / Re: Getting Started with JavaFX Game Programming (for Java Programmers) on: 2018-05-30 13:44:15
Here's a comparison from a performance graph of a game that I'm developing currently:
AnimationTimer

Timeline


Timeline is much more spikey than AnimationTimer, so I used the latter, as it's very smooth.

Cheers
30  Games Center / WIP games, tools & toy projects / Re: The Vehicular Epic on: 2018-05-29 14:29:10
There should be textures, actually  Huh
What are your computer specifications?

Where are some textures, to check for sure? I tested the game on a HD 6450, on which other JavaFX apps run fine with all graphical features. I mean, there are no image textures at all, but all of the shapes are properly colored and lighted. No errors in command line, except those with the music files, but thats my fault as I saw in the readme.

Also, the LOD makes those triangles on the ground appear and disappear all the time… maybe let them fade in and/or set the LOD distance higher?

Cheers
Pages: [1] 2
 
hadezbladez (3627 views)
2018-11-16 13:46:03

hadezbladez (1292 views)
2018-11-16 13:41:33

hadezbladez (3633 views)
2018-11-16 13:35:35

hadezbladez (695 views)
2018-11-16 13:32:03

EgonOlsen (3998 views)
2018-06-10 19:43:48

EgonOlsen (4525 views)
2018-06-10 19:43:44

EgonOlsen (2686 views)
2018-06-10 19:43:20

DesertCoockie (3546 views)
2018-05-13 18:23:11

nelsongames (3699 views)
2018-04-24 18:15:36

nelsongames (4722 views)
2018-04-24 18:14:32
Java Gaming Resources
by philfrei
2019-05-14 16:15:13

Deployment and Packaging
by philfrei
2019-05-08 15:15:36

Deployment and Packaging
by philfrei
2019-05-08 15:13:34

Deployment and Packaging
by philfrei
2019-02-17 20:25:53

Deployment and Packaging
by mudlee
2018-08-22 18:09:50

Java Gaming Resources
by gouessej
2018-08-22 08:19:41

Deployment and Packaging
by gouessej
2018-08-22 08:04:08

Deployment and Packaging
by gouessej
2018-08-22 08:03:45
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!