Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (494)
Games in Android Showcase (114)
games submitted by our members
Games in WIP (563)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1] 2
  ignore  |  Print  
  Lightless (Updated)[9.24.2013]  (Read 4433 times)
0 Members and 1 Guest are viewing this topic.
Offline BenningtonHD

Junior Member


Projects: 1



« Posted 2013-08-31 01:45:59 »

Lightless (working title) is my first full-length game attempt.

I intend for it to be a top-down 2D RPG, with 8 bit music and graphics. I am creating all the resources (Music, art, code, story) by myself. I am completely comfortable with the music and story, I'm decently comfortable on programming, and im honestly kind of crap at art, one of the reasons that i decided to make it more retro.

List of Features so Far:

Map Editor
Player Movement and Animation
Collision
Tileset (Some)
Rendering Text (Finished but not pretty)
Interacting with Map tiles
Map Scrolling
Original Music (Current Progress: 1 Track finished)
Very basic NPCs

List of Planned/Unfinished Features:

Final Fantasy style battles
Menus
Class system similar to Fire Emblem, will reveal more when i start on it.
No overworld (Final fantasy) walk everywhere (zelda / pokemon) with ports opening up for faster travel as you reach them.
Story ( Branching?) (Have a basic idea, will reveal more when i start on it)
Shops
Magic / Skill system
Equipment
Map
Dungeons (Most handmade, at least 1 infinite randomly generated)
Colosseum Mode (Use your single player team to fight waves of monsters, would like to make it so you can face friends here via internet but have no idea how so we'll see)


Screenshots:











Current build Video:
<a href="http://www.youtube.com/v/RznNy4nnte8?version=3&amp;hl=en_US&amp;start=" target="_blank">http://www.youtube.com/v/RznNy4nnte8?version=3&amp;hl=en_US&amp;start=</a>


When recording, the game slows down to 30 fps, and since framerate independent movement doesn't work well with my system, I move slower, in the future when i record i will just change to movement speed to match what it should look like. It is not a problem outside of recording.
The recording is also lower quality, im seeing if i can fix that.


As you can see i dont have many tiles yet, just some dirt and grass variants, flowers, and a crappy sign and stump. If anyone has any tips for these i would appreciate them, ive looked at a lot of pixel art tuts, but they don't seem to help too much on such a small scale. Oh, forgot im using Dawnbringers 16 color palette, and im using Famitracker for my music

Ok, next up for me is making my second track which will be the title screen music, then add NPC behavior, more than one box of text per interaction, from there probably i'll move on to menus and shops.

Until then Id love to hear pretty much anything from you guys!

Development Steps (X means finished, O means in progress):
Map Editor X
Basic Engine 0
Menus
Battle Engine
Content
Make Website and figure out how to put it up for sale
Attempt Marketing
If any success try to put on Steam
If rich: Pay someone to port to XNA for release on Xbox indie games
Offline opiop65

JGO Kernel


Medals: 154
Projects: 7
Exp: 3 years


JumpButton Studios


« Reply #1 - Posted 2013-08-31 16:27:48 »

Just wondering, are you using any libraries like LibGDX for this?

Offline BenningtonHD

Junior Member


Projects: 1



« Reply #2 - Posted 2013-08-31 18:34:53 »

I am using LWJGL and slick_util Smiley
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline opiop65

JGO Kernel


Medals: 154
Projects: 7
Exp: 3 years


JumpButton Studios


« Reply #3 - Posted 2013-08-31 18:36:43 »

Very cool, I actually like your art! I mean no offense, I've seen better, but it definitely is not as bad as you think Smiley You're better than me!

Offline BenningtonHD

Junior Member


Projects: 1



« Reply #4 - Posted 2013-08-31 20:19:50 »

Thanks haha, the main reason it's as decent as it is, is the few hours i spent going through tutorials, im just not sure how good ill be able to make the more detailed stuff such as houses, or monster and character battle sprites
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #5 - Posted 2013-08-31 22:19:01 »

Alright finished with basic map tile interactions, will put a video up soon, unfortunately i only have the free version of fraps so it'll probably be very short.

P.S. Ill probably make the text boxes prettier, but right now, i don't really care
Offline HeroesGraveDev

JGO Kernel


Medals: 249
Projects: 11
Exp: 2 years


┬─┬ノ(ಠ_ಠノ)(╯°□°)╯︵ ┻━┻


« Reply #6 - Posted 2013-08-31 23:06:08 »

If you're on Windows <8 you can use the screen capture tool included with Microsoft's Expression Encoder.

You get the full resolution, perfect quality, and little or no lag.

As much as I hate Microsoft, I love that one piece of software.

Offline BenningtonHD

Junior Member


Projects: 1



« Reply #7 - Posted 2013-08-31 23:49:27 »

Unfortunately I am on Windows 8, thanks for the tip though  Smiley
Offline opiop65

JGO Kernel


Medals: 154
Projects: 7
Exp: 3 years


JumpButton Studios


« Reply #8 - Posted 2013-09-01 02:10:39 »

It's not for windows 8 a an optional download or anything? That sucks, I actually like windows 8.

Offline BenningtonHD

Junior Member


Projects: 1



« Reply #9 - Posted 2013-09-01 02:25:00 »

Last time i checked it wasn't, but just now i looked and you can!  Grin so ill maybe retake the video tomorrow after i write another one of my essays

EDIT: It's basically the same as Fraps except i dont think theres a 30 second time limit, it still slows my game down to 30 fps, even when i switched the capture rate to 60, but ill definitely be using it.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #10 - Posted 2013-09-01 18:14:08 »

Alright new video up, got openAL, it's easy stuff, took 2 minutes to implement, however it does pause for about 1/4 second before looping but it looks more like a problem with openAL than something on my end.

Also the new video encoder thing doesn't output at full quality, but i'm thinking its because i didn't pay 200$ for the full version.
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #11 - Posted 2013-09-01 20:19:24 »

Just spent about an hour on this

Offline wessles

JGO Wizard


Medals: 66
Projects: 4
Exp: 3 years


Profile picture isn't relevant.


« Reply #12 - Posted 2013-09-03 20:33:53 »

framerate independent movement cant work with my system

Trust me you can do it. You have to find a way around it! without it, a person with a really fast computer could move really fast! Unfair advantage. If it is an issue with not wanting to pass delta to methods, you could just make a static variable (and no, it will not static-imize your system at all besides 1 method and one variable). Unless you are working with a non update/render loop, I don't see a reason that you can't implement this!

Offline BurntPizza
« Reply #13 - Posted 2013-09-03 20:47:06 »

a person with a really fast computer could move really fast!

Probably not, as the frame rate is capped at 60, no?

Still might want to consider a different game loop, or have logic running at a fixed baseline, and render at whatever, using interpolation. There is a nice wiki article about the different methods.
Offline wessles

JGO Wizard


Medals: 66
Projects: 4
Exp: 3 years


Profile picture isn't relevant.


« Reply #14 - Posted 2013-09-03 21:23:24 »

That was never mentioned.
EDIT:
Ok, but what about if someone has a slow computer? Then they will have to having to play longer. A cap can't even stop that...

Offline BurntPizza
« Reply #15 - Posted 2013-09-03 23:20:08 »

I await his response, but the probability that someone would be experienced enough to turn out what he has already without looking at a single tutorial (lwjgl or otherwise), virtually all of which will demonstrate fps limiting (either implicitly or explicitly) is practically zero.

On the off chance of that, I could just be wrong.   Wink
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #16 - Posted 2013-09-04 10:36:09 »

Sorry for not replying school is starting and im a lot busier, yes i do have the framerate capped at 60

The problem is that i made my own animation system that depends on how many pixels youve moved so far in the walk cycle.
If i pass delta into their and it doesnt divide evenly into the amount of pixels (16) then you end up a pixel or three off of the grid, and that screws up basically everything.

I'm more than happy to take suggestions on how to fix that, its just something i made up myself so its probably not super-efficient.
Offline elamre

JGO Coder


Medals: 17
Projects: 1


hitar!


« Reply #17 - Posted 2013-09-04 10:37:48 »

Make a movement timer for example. Something like this:

float movementTimer = 0;

public void update(float deltaT){
movementTimer+=deltaT;
if(movementTimer>=1)}
move();
movementTimer-=1;
}
}

My projects:
Tower Defence!]http://www.java-gaming.org/topics/iconified/25690/view.html]Tower Defence! [lll.......] 30%!
Lightsnakerider! [llllll....] 60%!
Offline Several Kilo-Bytes

Senior Member


Medals: 11



« Reply #18 - Posted 2013-09-04 17:39:16 »

Graphics should depend on what the state of the game is, not vice versa. Then the frame rate can be capped to any value or uncapped. If it's slow, then it is trivial to drop frames because a frame update is not necessary to make characters "go".
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #19 - Posted 2013-09-04 19:11:11 »

I have a movement timer, the thing is that if i need to move exactly 16 pixels, and have it change animation at every 4 pixels, and im multiplying my movement speed by a delta, it ends up either cutting off animations short, or i dont end up right in the center of the next grid point.
Mabye i could round the output from multiplying my speed by delta to the nearest whole number so it would hopefully go into 16, but then its possible that it could get 17, then when i set it back to 16 it would be a little jump, ill post my movement code, and you guys can criticise it for me
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #20 - Posted 2013-09-04 19:15:22 »

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
if(movingDown && !movementDone ){
         successiveRight = false;
         successiveUp = false;
         successiveLeft = false;
         translate_y += movementSpeed;
         player.setY((float) (player.getY() + (movementSpeed)));
         movementCounter += movementSpeed;
         if(movementCounter < 4){
            frame = 2;
          } else if( movementCounter > 4 && movementCounter < 16 && !successiveDown){
            frame = 3;
         } else if (movementCounter > 4 && movementCounter < 16 && successiveDown){
            frame = 1;
         } else if(movementCounter >= 16){
            movementDone= true;
            movingDown = false;
            movementCounter = 0;
            frame = 2;
            player.setGrid_Y(grid_y + 1);
            if (successiveDown){
               successiveDown = false;
            } else if (!successiveDown){
               successiveDown = true;
            }
         }
      }



Its the exact same for the other directions, when you press wasd, the movingDown/ whatever direction it is goes to true, movementDone is set to false when you press wasd, or if you are interacting with something else, it checks which direction is blocked before input is taken, then sets rightIsBlocked/ whatever direction, and makes it so it changes the frame so theyre facing the right way, but doesnt set the movingDown or movementDone from the corresponding key
Offline BurntPizza
« Reply #21 - Posted 2013-09-04 19:58:52 »

If you need the character to always reside in the very center of a grid cell, then I would do something like this: (pseudocode)

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
void moveUp(float delta) { //separate method just for readability here
  if(player.getY() is on above cell center, or just past) { //if he has reached his destination
     player.setY(aboveCell.y); //just in case he was just a little bit too far, we fudge a bit, again aboveCell is pseudocode
     movingUp = false; //we are done, stop moving
  } else { //still not there
     player.setY((int)(player.getY() + movementSpeed * delta)); //movmentSpeed in cells per second
  }
}


void doGameLogic(float delta) { //delta is seconds per frame, such as 1/60f, but is computed from the previous frame in case we are not making 60fps
  if(currentlyPressedKey == 'w') movingUp = true;
   else if() ... //you get the idea
 
   ...
   
   if(movingUp) moveUp(delta); //if he's not done moving yet...
  else if() ...
}


Hey presto! Framerate independent to boot!

Note that now, when a key is pressed, the player will move to the next cell (tile, whatever), even if the key is released as he is still traveling, but if it is still pressed when he gets there, he'll just keep on going. Also, the player 'snaps' to the center of the cells. The fudging of the player's location near the center shouldn't be noticeable at decent framerates.

At least in theory, I programmed that in the post ofc, but hopefully you get the idea.
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #22 - Posted 2013-09-04 20:14:21 »

Yeah i see what you mean, i just hope the snapping back isn't noticeable.

P.S. my code keeps movement going even when the key isn't held down as well haha
Offline BurntPizza
« Reply #23 - Posted 2013-09-04 20:32:02 »

my code keeps movement going even when the key isn't held down as well haha

I figured as much, but my real point was to think about movement as a task that runs, and only checks back after the movement completes. (No, do not try to thread it) That way you can update it any way you want, including using a delta.
Offline Several Kilo-Bytes

Senior Member


Medals: 11



« Reply #24 - Posted 2013-09-04 20:52:10 »

my code keeps movement going even when the key isn't held down as well haha

I figured as much, but my real point was to think about movement as a task that runs, and only checks back after the movement completes. (No, do not try to thread it) That way you can update it any way you want, including using a delta.

Do not use delta times in update functions. Use them in rendering if you want. It is more complicated, leads to bugs, and does not make game play consistent. You will either have bugs you never notice or level designs that are impossible for some computers. I played a physics based puzzle game (something really simple) where pressing go without moving anything made the ball bounce to different places. A game that simple (with a walkthrough) became impossible to win because the developer used delta time steps.

You probably don't want to put yourself through the pain as a developer. Even if you do, the player won't want that.
Offline BurntPizza
« Reply #25 - Posted 2013-09-04 21:22:24 »

Not sure I agree on delta being more complicated (compared to variable render and fixed logic), but predictability is indeed better with fixed timestep methods.
To use that with the "movement as task" idea:

Instead of
 player.y += speed * delta
, use
player.y += amountToMovePerStep

and stop the task after so many updates, or player.y is in the right position. (e.g. Bennington's 16 steps)

But remember, now the doGameLogic() needs to be called in a separate, fixed time loop, and I would definitely check out the articles and tutorials page for that. Also google around for fixed timestep loops that can catch-up if they fall behind.
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #26 - Posted 2013-09-05 01:05:33 »

Honestly, there's no immediate concern with my current system, the only time framerate drops is when i record, which i believe is cause by the camera taking up the same resources or some such thing,

If it becomes a problem i can try capping at 30 fps, which for a simple 2d game should be slow enough for any non extinct computer. If somehow that doesn't cover it, i will find a better way to implement delta, or i will just seperate my animation and walking and rendering code into different portions.

One thing id like to know is how you guys export, because i haven't ever successfully moved anything out of eclipse before, i use jarsplice and try to get everything right but it just doesn't work for me
Offline BurntPizza
« Reply #27 - Posted 2013-09-05 01:09:57 »

One thing id like to know is how you guys export, because i haven't ever successfully moved anything out of eclipse before, i use jarsplice and try to get everything right but it just doesn't work for me

Haven't watched it, but seems as good as any
Offline BenningtonHD

Junior Member


Projects: 1



« Reply #28 - Posted 2013-09-05 01:16:46 »

I don't think that works because i use multiple jars, but i'll try it tomorrow after classes, if i can ill try to keep an up to date demo of it on the OP
Offline BurntPizza
« Reply #29 - Posted 2013-09-05 01:27:22 »

If by multiple jars you mean libraries, then it works fine, as long as the jars are added to the build path as libraries. (Which they have to be for it to compile anyway)
The options for including libraries:
  • Extract required libraries into jar: extracts each jar into your exported jar, can be messy.
  • Package required libraries into jar: puts each library jar into your exported jar whole, and uses a jar-in-jar loader at runtime provided by eclipse. I like this option, nice and tidy.
  • Copy into subfolder: does what it says, creates a folder alongside your exported jar with the library jars in it. You probably don't want this.
Pages: [1] 2
  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.

Dwinin (21 views)
2014-09-12 09:08:26

Norakomi (55 views)
2014-09-10 13:57:51

TehJavaDev (65 views)
2014-09-10 06:39:09

Tekkerue (33 views)
2014-09-09 02:24:56

mitcheeb (54 views)
2014-09-08 06:06:29

BurntPizza (38 views)
2014-09-07 01:13:42

Longarmx (24 views)
2014-09-07 01:12:14

Longarmx (30 views)
2014-09-07 01:11:22

Longarmx (28 views)
2014-09-07 01:10:19

mitcheeb (36 views)
2014-09-04 23:08:59
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
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!