LWJGL Forum

Programming => Lightweight Java Gaming Library => Topic started by: CodeBunny on September 04, 2011, 01:25:49

Title: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 04, 2011, 01:25:49
(http://jrabbit.minds-eye-games.com/wp-content/uploads/2011/08/jRabbit.png)

So, after 21 months of development and countless revisions, I have finally finished version 1.0 of my first real programming project: The Java Rabbit Engine.

http://jrabbit.minds-eye-games.com/ (http://jrabbit.minds-eye-games.com/)

The Java Rabbit Engine (jRabbit for short) is a lightweight, hardware accelerated 2D game engine. It is fast and flexible, and allows for very east yet non-constricting development.

Atm, due to time, effort, and energy constraints I do not have a tutorial suite available. However, I DO have a completely open source game written with the engine that is:

A) my first complete game,
B) a proof-of-concept that the engine works well,
C) a showcase of all major features of the engine, and
D) a fully documented, working example of how to make an entire game.

So, meet Micron: http://play.minds-eye-games.com/micron (http://play.minds-eye-games.com/micron)

(http://play.minds-eye-games.com/wp-content/uploads/2011/09/Micron-Screenshot.png)

It's a 2D randomly generated abstract shooter. Everything except the music (code, art, etc.) has been created by me.

I'd recommend downloading either the EXE or the executable Jar over playing it as an applet. It's a bit more fun as a fullscreen desktop game, and it allows the user to use the persistent high scores and soundtrack features.

Anyway, I hope you enjoy it!
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: kappa on September 04, 2011, 13:30:12
the .jar extensions are missing on the native files for mac, linux and solaris in the html for the applet, causing the applet not to work on those operating system.

However really nice game.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 04, 2011, 14:28:00
Thank you for telling me. Is it fixed now?

Thank you!
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: kappa on September 04, 2011, 14:30:51
Quote from: CodeBunny on September 04, 2011, 14:28:00
Thank you for telling me. Is it fixed now?

Thank you!

Yes, it works now. You might want to also consider adding a fullscreen mode to the applet version.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 04, 2011, 15:45:07
That is probably a good idea. I'll see what I can do.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: jediTofu on September 05, 2011, 04:10:11
The applet crashes for me with "can't load logo/progressbar."  I think this is a bug with LWJGL on Linux.  You need to actually extract the logo/progressbar images and specify them in the applet code.  For some reason, it won't read the defaults in the LWJGL jars.  I have to do this for my applets.

I then downloaded the Jar and tried running it.  The rabbit logo appeared, then the sound, and then the loading part.  Then it crashed with an error in the native code:
"# C  [i965_dri.so+0x3f859]  _init+0x15719"

What's odd is that it seems to be a different ".so" file everytime I run it.  After I ran it 3 times though, it crashed my computer haha.  It's probably something with OpenCL or something advanced that my hardware doesn't have support for.

I like the Mind's Eye name :0  (also the Wolfmother song)
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: Matzon on September 05, 2011, 05:33:10
i965_dri.so <-- intel drivers -.-
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: kappa on September 05, 2011, 09:18:34
Quote from: jediTofu on September 05, 2011, 04:10:11
The applet crashes for me with "can't load logo/progressbar."  I think this is a bug with LWJGL on Linux.  You need to actually extract the logo/progressbar images and specify them in the applet code.  For some reason, it won't read the defaults in the LWJGL jars.  I have to do this for my applets.
Works fine for me on linux as is (without extracting any images). Which linux variant are you on anyway (including arch and java version)?
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 05, 2011, 13:53:50
I haven't done any focus testing, so there are some bugs cropping up. I'm sorry to anyone who wants to play the game but can't. Mac seems to be the main problem.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: johnnyh on September 05, 2011, 15:01:01
Impressive work but already done a thousand times before. Dont hopte to sell a lot of game like that. Try to find a good idea before coding. Cheers.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: jediTofu on September 05, 2011, 15:25:37
Quote from: kappa on September 05, 2011, 09:18:34
Quote from: jediTofu on September 05, 2011, 04:10:11
The applet crashes for me with "can't load logo/progressbar."  I think this is a bug with LWJGL on Linux.  You need to actually extract the logo/progressbar images and specify them in the applet code.  For some reason, it won't read the defaults in the LWJGL jars.  I have to do this for my applets.
Works fine for me on linux as is (without extracting any images). Which linux variant are you on anyway (including arch and java version)?

Linux Mint 10 (Ubuntu 10.10).  AMD 64-bit.  (Linux 2.6.35-22).
java version "1.6.0_26"
Java(TM) SE Runtime Environment (build 1.6.0_26-b03)
Java HotSpot(TM) 64-Bit Server VM (build 20.1-b02, mixed mode)

I'm using Oracle/Sun's Java instead of OpenJDK currently.  I also use Opera as my main browser (EDIT:  just tried in FireFox, and it can't load logo/progressbar either, so most likely a Sun thing?).  One of these is probably the problem.

Also, the LWJGL applet demo doesn't even run on Fedora 15 (OpenJDK/IcedTea plugin on firefox, no modifications to Java on it).  I need to investigate this one more though...
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: jediTofu on September 05, 2011, 15:31:32
Quote from: johnnyh on September 05, 2011, 15:01:01
Impressive work but already done a thousand times before. Dont hopte to sell a lot of game like that. Try to find a good idea before coding. Cheers.

That's pretty rude.  I don't think he was planning on making money with it seeing as how Micron is open source; it is just to give a working example of JRabbit.  To me, the screenshots and code look great; keep up the good work.  8)
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: johnnyh on September 05, 2011, 16:09:10
Yes, but he is selling it, isn't he ?
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 05, 2011, 16:32:04
...what? Of course not. I never said I was selling it, and the fact that it's Open Source and Open Resource (feel free to use all created textures/images/ideas in your own games, btw) kind of implies the contrary.

Micron is intentionally stripped down, it's a feature display. It's also a working example of how to use the Java Rabbit Engine, because I don't have a completed tutorial suite as of yet.

Dude, this engine and this game are the first two programming projects I have completed, ever. I'm not selling them, I've made them open source to A) get outside opinion and to B) make myself adhere to a standard of quality.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 05, 2011, 16:32:51
Out of curiosity, did you read a single word of my post? I'm pretty sure I was clear in what I intended for the game.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: johnnyh on September 05, 2011, 17:06:49
Oh sorry, man I was pretty sure to have seen a page with a paypal link. I am confused because it is obiously not the case. Anyway I would not had blame you for trying to sell a game. I never said that. Cheers.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 05, 2011, 17:39:56
Haha np. There actually is a donate button on my site, Wordpress has a plugin for it and I thought, "what the hell." It's not related to Micron, though, and I honestly don't expect anything out of it.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: johnnyh on September 05, 2011, 17:46:28
Ah yes it must be that, btw I dont see any pay link anymore now. Did u hide it ?
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 05, 2011, 17:53:06
It's not on Micron's page, it's on the "Contact" page of my parent site, Mind's Eye Games: http://www.minds-eye-games.com/contact/ (http://www.minds-eye-games.com/contact/)
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: johnnyh on September 05, 2011, 17:59:03
It might be that, yeah. :)
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: broumbroum on September 05, 2011, 19:38:44
Codebunny, what's the license for your open source project ?
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 05, 2011, 20:07:07
New BSD. I also have the License on my website, and available in fancy PDF form in the complete distribution. Why?
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: broumbroum on September 05, 2011, 21:01:12
Where ? I can't find it.
No reason at all, but it's worth to know it.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: Chuck on September 05, 2011, 22:01:36
You're not successful until you have people who've never created anything throwing rocks at you from the sidelines.  Keep it up, have fun, and don't let the bastards grind you down :)
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 05, 2011, 22:06:06
http://jrabbit.minds-eye-games.com/about/license/ (http://jrabbit.minds-eye-games.com/about/license/)

There's a link on the About page. It also has the license in the complete distribution, and it is in "org/jrabbit/license" in the source code.

QuoteYou're not successful until you have people who've never created anything throwing rocks at you from the sidelines.  Keep it up, have fun, and don't let the bastards grind you down

Nah, s'okay, I don't think he meant anything by it. But thanks for the encouragement. :)
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: johnnyh on September 06, 2011, 19:19:31
Dont forget that I said "great job" to CodeBunny in my first post before any comment. I was not jugging his job at all.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: rollins on September 08, 2011, 11:52:01
i just downloaded it, on google code. will see ... :)
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: Evil-Devil on September 09, 2011, 14:37:13
Runs pretty fine on my laptop. ~60fps :)
The only weird was the stucked sound when loading the game.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 10, 2011, 23:24:08
Stucked sound? What?  :-\
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: Evil-Devil on September 11, 2011, 00:59:43
Yes. When I start the game the "code bunny theme" is played and then the loading when the loading screen appears the "micron background music" begins to play. Then a few moments later it will stop playing, guess some other data is loading and causing the background music to stop. When the loading is complete the music continue playing and the main menu is shown.

gn8, it has been a very long day.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 12, 2011, 13:58:38
...That shouldn't happen. I'm pretty sure I wait for the loading to completely finish before playing the background music.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: Evil-Devil on September 13, 2011, 13:00:58
;)

I gave it another try on my desktop machine. This time everything worked fine. The loading screen have been shown ~1 second and then the main menu were presented.

As the other run was done on my laptop machine, i could try to film the happening or are there any hidden switched to enable debug/logging?
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 13, 2011, 17:48:31
I didn't program any hidden switches.
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: rollins on September 14, 2011, 15:41:55
works fine on my laptop and even in desktop which is a little bit older. just have a little problem with sound, but nothing important. it fixes in a few minutes. dunno how sound problem apperas , dunno how its gone. but it is important that it gone :)
Title: Re: The Java Rabbit Engine - a 2D Game Engine written with LWJGL
Post by: CodeBunny on September 15, 2011, 11:21:15
My sound API is literally a minimal wrapper around Slick-Util's Sound classes (Music and Audio). If there are loading/playback bugs, it's probably in there...

All that I really do is make instantiation and organization of available sounds simpler. I delegate all playback and loading to Slick-Util methods.