Java-Gaming.org Hi !
Featured games (87)
games approved by the League of Dukes
Games in Showcase (672)
Games in Android Showcase (194)
games submitted by our members
Games in WIP (727)
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 3 ... 10
 1 
 on: 2016-05-03 15:35:45 
Started by BurntPizza - Last post by mag
Nearly finished with my project for school!

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

 2 
 on: 2016-05-03 15:25:42 
Started by vusman - Last post by orange451
These are fantastic for lod skybox models ^^

 3 
 on: 2016-05-03 15:20:25 
Started by Cannonball7171 - Last post by Cannonball7171
I personally don't use box2d but the libgdx doc says that PolygonShape.setAsBox() takes in half-size arguments. Could it be that you're setting the box to be 1x1, but the parameters assume that's half size and make it 2x2? Your body definition code isn't included so we can't tell.

Well I'll be, it seems you're right

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
bodyDef = new BodyDef();
bodyDef.angle = this.rotation;
bodyDef.position.set(this.x, this.y);
bodyDef.type = BodyDef.BodyType.StaticBody;
body = w.createBody(bodyDef);
poly = new PolygonShape();
poly.setAsBox(this.width, this.height); //should have been halved
fix = new FixtureDef();
fix.friction = this.friction;
fix.restitution = this.resituition;
fix.shape = poly;
body.createFixture(fix);


I guess I should have read the docs more Clueless I have this bad habit of just quickly scanning over wikis and just picking what I think I need

It's fixed now, thanks!

 4 
 on: 2016-05-03 15:12:51 
Started by BurntPizza - Last post by orange451
are you adding some particles after the flash later on?
I will Smiley

 5 
 on: 2016-05-03 15:10:55 
Started by Cannonball7171 - Last post by chrislo27
I personally don't use box2d but the libgdx doc says that PolygonShape.setAsBox() takes in half-size arguments. Could it be that you're setting the box to be 1x1, but the parameters assume that's half size and make it 2x2? Your body definition code isn't included so we can't tell.

 6 
 on: 2016-05-03 14:51:56 
Started by Riven - Last post by SHC
The "There are x new posts!" thing is broken again.



I've just seen it, it's working perfect here.

 7 
 on: 2016-05-03 14:49:59 
Started by Cannonball7171 - Last post by Cannonball7171
In my game, I use Box2D. Now Box2D doesn't use pixels as units, so instead, it uses meters.

I render two things in my game to keep the physics and the graphics separate. Graphics is in normal libgdx coordinates (lower-left origin) because I'm used to having it as that. Physics is in Box2D coordinates (center origin) because that's what Box2D needs.

Everything seems fine, except that Box2D renders everything twice as big:

White line is the graphics renderer while the green lines are from the Box2D debug renderer


(Yeah I know it's not centered but it's on purpose)

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  
27  
28  
29  
30  
31  
32  
//I set 60 pixels per meter
private static final int PIXELS_PER_METER = 60;

private Box2DDebugRenderer debug;
private OrthographicCamera camera;

//...

public ...() {
   debug = new Box2DDebugRenderer();
   //Convert window width and height to meters because that's what Box2D needs
   camera = new OrthographicCamera(Maths.pixelsToMeters(Gdx.graphics.getWidth()), Maths.pixelsToMeters(Gdx.graphics.getHeight()));

   //Just offset the camera, because in-game center isn't the window center; not sure if this is relevant
   camera.position.sub(0f, Maths.pixelsToMeters(Gdx.graphics.getHeight() - Maths.IN_GAME_HEIGHT / 2f - Gdx.graphics.getHeight() / 2f), 0f);
   
   camera.update();
}

//...

public static float pixelsToMeters(float p) {
   return p / (float)(PIXELS_PER_METER);
}

//...

public void render(float delta, SpriteBatch batch) {
   camera.update();
   //...
   debug.render(world, camera.combined);
}


Given that the cube above is 60 by 60 pixels, that would be 1 meter in Box2D units (println's also say this). But every time it is rendered it shows up twice as big (120 by 120 pixels). It also said in the javadocs that OrthographicCamera takes in half a viewport, but that still doesn't work.

 8 
 on: 2016-05-03 14:27:35 
Started by arkisvir - Last post by arkisvir
Falling Stars: War of Empires is now on Steam!
http://store.steampowered.com/app/439960

Built completely in Java with JMonkey Engine, I've been developing this game for almost 4 years.  It's a fast-paced but deep turn-based strategy game that includes online play.  Check out some of the features below!




Falling Stars: War of Empires is a fast-paced 4x turn based strategy game where each decision you make forces the game to evolve differently every time you play. Command hundreds of ships in battle, resolve intricate political agendas, and discover the deep interplanetary relations of the galaxy.  With customization options for galaxy size, galaxy resources, technology advancement rate, victory conditions, game length, and more, you can choose how you want to play the game.  Game lengths can range from 1 hour, to 40 (or more) hours.

With a fully interactive tutorial, you will be commanding your empire in as little as 30 minutes.





Utilizing similar mechanics to popular 4x board games, Falling Stars mixes the deep strategy and dynamic rule set of a board game with the vast scope and complexity of a video game.



The original soundtrack, composed by Nolan Markey, who interned and later worked for Emmy-winning composer Bear McCreary, (Agents of Shield, The Walking Dead, Outlander), and currently serves as orchestrator for Disney's Star Wars Rebels, brings you right into the space opera universe of Falling Stars.

Try the free demo here! Nothing is required except an account so you can receive an installer that will automatically update the game

http://store.lnlpublishing.com/falling-stars-war-of-empires-trial


 9 
 on: 2016-05-03 13:25:53 
Started by Riven - Last post by elect
What about using an other software forum, such as Discourse for example?

 10 
 on: 2016-05-03 13:09:18 
Started by Gornova - Last post by Gornova
Hello everyone! I have closed survey and emailed to every participant raw data. I will do a post on my blog with in depth analysis and release all data free for everyone, keep an eye on my blog here: http://randomtower.blogspot.it/

Pages: [1] 2 3 ... 10
 
IanParcs (45 views)
2016-04-18 14:18:53

KaiHH (45 views)
2016-04-18 08:35:41

KaiHH (75 views)
2016-04-15 12:43:58

theagentd (76 views)
2016-04-14 02:16:17

theagentd (90 views)
2016-04-14 02:15:43

IanParcs (104 views)
2016-04-12 03:51:16

IanParcs (47 views)
2016-04-12 03:50:03

IanParcs (43 views)
2016-04-12 03:49:54

IanParcs (38 views)
2016-04-12 03:49:52

IanParcs (48 views)
2016-04-12 03:49:52
Website offering 3D Models specifically for games for free
by vusman
2016-04-29 12:56:17

List of Learning Resources
by SilverTiger
2016-02-05 09:39:47

List of Learning Resources
by SilverTiger
2016-02-05 09:38:38

List of Learning Resources
by SilverTiger
2016-02-05 09:35:50

Rendering resources
by Roquen
2015-11-13 14:37:59

Rendering resources
by Roquen
2015-11-13 14:36:58

Math: Resources
by Roquen
2015-10-22 07:46:10

Networking Resources
by Roquen
2015-10-16 07:12:30
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!