Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (107)
games submitted by our members
Games in WIP (535)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Noob thinking about trying to use a library  (Read 544 times)
0 Members and 1 Guest are viewing this topic.
Offline 3android14

Junior Newbie





« Posted 2014-01-13 20:00:01 »

Lets be honest, Im a noob in java (that's why I am here) trying to make a game similar to Minecraft (Im aware that this is an ambitious project for a starter, but it's helping me to learn stuff) but in 2D (not platformer 2D, but Zelda like 2D). However, I feel like things are going too slow...  Undecided So far, I hava managed to make:


The graphics:
-An ortographic view (if it is called so the view that moves with your character) using paint() method to draw things (I know it's a terrible idea, right?), which supports floating point movement and rescaling, and renders blocks as colored points.
-A crappy lightning system (yet I managed to make it cast shadows).

Gameplay:
-I can move my character around, and it collides with walls (this is sad).

Engine:
-The world is infinitely generated using Perlin noise (so far just walls and empty spaces).
-The world is generated and divided in chuncks, whose side can be modified.
-Each chunck is composed of blocks, each one with its own id and lightning.

An ugly starting menu


The last thing I did was the lightning system, which was hard (for me), and Im a little frustrated. So I thought I should stop messing around in my paint() method, and instead move to a suitable engine ("engines" I have used so far: console, JLabels with an image, and curent one). But I'd like to ask some questions before making that move:

-What is the best (I hope I dont start a flame war with this) java engine/library for 2D games?
-Is that engine/library capable of loading/unloading regions of an infinite grid? (this might be a stupid question)
-Has that engine/library anything to make lights?
-Is the engine/library easy to learn for a noob? (I know how to handle basic java stuff, and a little of Object oriented programming, but nothing more).
-Does that engine/library provides an easily accessible particle/sprite system?

Keep in mind that I dont want something that makes everything for me, but Id like to concentrate in the random generation and enemy AI of my game, rather than in the graphics...

Btw, this is my first post in this forum Grin .

PS: Who designed the little "test" to validate an account?. Im just curious, I didnt expect that kind of thing...
PS2: If I made an spelling or grammar error, dont be so hard on me, Im not a native speaker (but point it out, so I learn from it)  Smiley
Offline Mac70
« Reply #1 - Posted 2014-01-13 20:14:23 »

About loading/unloading regions - you have to make the code yourself, but KryoNet is a good choice when it comes to saving/loading objects and networking.

About lighting - I think there is no library for that, you have to use the whole framework like LibGDX or make it yourself.

Easy to learn engine? Try LibGDX, or JOGL if you want to reinvent the wheel.

Check out my Devblog! Smiley
Offline dermetfan

Senior Member


Medals: 11



« Reply #2 - Posted 2014-01-13 20:27:04 »

- What is the best (I hope I dont start a flame war with this) java engine/library for 2D games?
IMHO definitely LibGDX

- Is that engine/library capable of loading/unloading regions of an infinite grid?
Hard to answer, but something like this is definitely possible (e.g. using tile maps (tut))

- Has that engine/library anything to make lights?
Box2DLights works nicely with LibGDX (I recommend to use Box2D anyway)

- Is the engine/library easy to learn for a noob?
I was a noob when I learned it and I still love it, so I guess yes.

- Does that engine/library provides an easily accessible particle/sprite system?
Yes, it even provides a Particle Editor

In addtion, I made libgdx-utils and some tutorials.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline gouessej
« Reply #3 - Posted 2014-01-13 21:08:41 »

Easy to learn engine? Try LibGDX, or JOGL if you want to reinvent the wheel.
or both. I updated LibGDX JogAmp backend yesterday, enjoy  Grin
https://github.com/gouessej/libgdx

LibGDX is definitively the best choice for 2D. I'm not sure its 3D API is ready for prime time but Nate should answer you better than me.

Offline 3android14

Junior Newbie





« Reply #4 - Posted 2014-01-14 17:42:09 »

Thank you for all the responses  Cheesy , now I know that libgdx is the way to go.

Also, about loading and unloading parts of the map, I meant to ask if libgdx would load the images just in the screen and unload them when they go out, or if Id have to handle the loading and unloading part myself.

On the lightning part, I think Ill try to finish the engine I started making.

Finally, where can I find easy resources to get started in libgdx?
Offline dermetfan

Senior Member


Medals: 11



« Reply #5 - Posted 2014-01-14 17:46:27 »

from this topic:

Offline Troubleshoots

JGO Knight


Medals: 36
Exp: 7-9 months


Damn maths.


« Reply #6 - Posted 2014-01-14 17:47:30 »

Also, about loading and unloading parts of the map, I meant to ask if libgdx would load the images just in the screen and unload them when they go out, or if Id have to handle the loading and unloading part myself.

Since it's built on top of OpenGL, it clips the vertices that are not visible to the camera and doesn't render them.

Why are all OpenGL tutorials written in Brainf**k?
Offline Bassex96

Senior Member


Medals: 4



« Reply #7 - Posted 2014-01-14 21:46:57 »

For what you're trying to do, you need to start learning LibGDX. It handles most of the redundant things for you so all you have to do is basically code your content but is still flexible enough to do anything you want. I'm working on a similar type game (By similar I mean a 2d tiled game.)

Get LibGDX up and running and watch dermetfans tiled tutorial. It's GREAT! You will learn enough to get you started.

P.S. Thanks dermetfan for the hardwork put into your tiled tutorial. I haven't had a chance to go through your other tutorials yet but thanks for those too! I spoke with you the other day on youtube. I'm the one making the farming type game. (Jman)
Offline Gibbo3771
« Reply #8 - Posted 2014-01-16 18:35:41 »

P.S. Thanks dermetfan for the hardwork put into your tiled tutorial. I haven't had a chance to go through your other tutorials yet but thanks for those too! I spoke with you the other day on youtube. I'm the one making the farming type game. (Jman)

I agree 100%, you are not going to learn everything in one sit but watching through any of dermets videos you will learn enough to get started and lower the frustration greatly.

"This code works flawlessly first time and exactly how I wanted it"
Said no programmer ever
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

E.R. Fleming (20 views)
2014-07-29 03:07:13

E.R. Fleming (8 views)
2014-07-29 03:06:25

pw (39 views)
2014-07-24 01:59:36

Riven (39 views)
2014-07-23 21:16:32

Riven (26 views)
2014-07-23 21:07:15

Riven (28 views)
2014-07-23 20:56:16

ctomni231 (59 views)
2014-07-18 06:55:21

Zero Volt (50 views)
2014-07-17 23:47:54

danieldean (42 views)
2014-07-17 23:41:23

MustardPeter (45 views)
2014-07-16 23:30:00
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
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!