Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (538)
Games in Android Showcase (132)
games submitted by our members
Games in WIP (600)
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 3 ... 72
1  Discussions / General Discussions / Re: General Java Questions on: 2014-11-21 09:54:02
A map in JSON:
1  
2  
3  
4  
5  
{
   water: 'h2o',
   oxygen: 'o2',
   glucose: 'c6h12o6'
}


The JSON input is NOT valid according to RFC 4627 (JSON specification). Unexpected token water at position 11.
Tongue

There is a right way to structure your XML graph, but everybody uses their own style, and worse... is inconsistent across documents or in the very same document.

You forgot the "maven-way":
1  
2  
3  
4  
5  
<map>
   <water>h2o</water>
   <oxygen>o2</oxygen>
   <glucose>c6h12o6</glucose>
</map>


But as I said - xml is a markup language and using it as a configuration language only makes sense when paired with a schema to get code-completion and inline-documentation support.
2  Discussions / General Discussions / Re: General Java Questions on: 2014-11-21 07:24:03
then, for the sake of cute fluffy bunnies, focus on a sane, straightforward format like json.
For pure human readable data storage and transfer json is great.  As a markup language xml might be better since it allows for mixed content. As a configuration language,  xml also has it's merrits,  because of the widespread completion and documentation support in IDEs based on schemas. Hopefully json-schema catches up there soon...
3  Discussions / Miscellaneous Topics / Re: Is drinking half a bottle of vodka safe? on: 2014-11-20 12:10:17
On a serious note, isn't life all about memories?
Actually it's quite the opposite - life is about concentrating on the current moment and not thinking about the past and pondering about the future, because it only happens in the present...
4  Discussions / Miscellaneous Topics / Re: Is drinking half a bottle of vodka safe? on: 2014-11-19 21:13:33
Well, I strongly believe that nobody stops being an idiot ever - you just change the occasions where you proof it...
5  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-11-18 07:03:46
Made a non-scientific redstonesk wire simulator with (from left to right): wire, source blocks, clocks, AND gates, and XOR gates.


Also what are some more essential systems used in creating computers other than a transistor? The goal is to be able to have all the tools to simulate hardware (like redstone), but my electrical/computer engineering knowledge is limited.
I intend to add:
- toggle blocks
- signal repeaters
- wireless receivers
- LEDs
Use NAND gates instead: http://en.m.wikipedia.org/wiki/NAND_logic
6  Java Game APIs & Engines / OpenGL Development / Re: LWJGL 3; how's it getting along? on: 2014-11-14 12:28:29
Stays the same for me after upgrading. Looks like the font "Fira Sans" is broken on my system. Weird.
7  Discussions / Miscellaneous Topics / Re: How memory works? on: 2014-11-14 09:52:35
I have to nit-pick here, that the program is not asking the memory, but the operating system to allocate a chunk of memory and gets back the address of that location.
8  Java Game APIs & Engines / OpenGL Development / Re: LWJGL 3; how's it getting along? on: 2014-11-14 08:51:30
The new LWJGL site is now live.
Nice Bug with Firefox 33.0.3:
9  Discussions / General Discussions / Re: Worried, Scared. Life wasted? [YOU SAY!] on: 2014-11-11 11:00:11
I say give up, and get a job in insurance.













... if you gave up just then, you have failed the first of many tests in life Smiley

Cas Smiley
Damn. I gave up and now have a job at an insurance company... Cry
(I am not kidding...)
10  Game Development / Game Play & Game Design / Re: How to save/load game data with Entity/Component based Engine via JSON on: 2014-11-09 10:33:13
http://www.java-gaming.org/topics/properties-alternative/34594/msg/326562/view.html#msg326562
11  Discussions / Miscellaneous Topics / Re: simplifying getter/setter classes on: 2014-11-07 08:56:44
If you work in any kind of Enterprise Java job, there is simply no way to avoid them...
But they're not rocket science.  Shouldn't be something you need to practice.
Yeah, actually you can just let them generate and refactor by any decent IDE.
12  Discussions / Miscellaneous Topics / Re: simplifying getter/setter classes on: 2014-11-06 23:30:32
I would love to work as a Swing (or JavaFX) developer the rest of my life, but I don't see that happening.
Well, it won't happen with any technology nowerdays...  Shocked
13  Discussions / Miscellaneous Topics / Re: simplifying getter/setter classes on: 2014-11-06 15:58:03
Well, using Beans and their idioms depend on the context. If you work in any kind of Enterprise Java job, there is simply no way to avoid them...
14  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-11-05 20:07:36
W-what do I do?! Who do I talk to?!
*shhhh*
     persecutioncomplex
patent it!
     persecutioncomplex
15  Game Development / Newbie & Debugging Questions / Re: How to code this? on: 2014-11-02 23:07:03
Well, you can't?

If you have two layers that are exactly the same dimension and want both to start at 0.0 and have the same dimension as the world, they simply can't move at a different speed.

So there is no way around moving the layers with different increments. This also means they have to have different dimensions...
16  Games Center / WIP games, tools & toy projects / Re: SJGL (Simple Java Game Library) on: 2014-11-02 11:27:09
I'm not sure what to relplace gl[Blahblahblah] with. Seemed natural to put gl in front of it, as I've been using OpenGL lately. Now I think it may not have been the best choice (Thanks, HeroesGraveDev). Do you guys have any better suggestions, as I can think of one right off the top of my head.
Just nothing!  Prefixes like gl... are relicts from a language without namespaces and objects. You don't need them in modern languages and are just a hassle to type with no benefit...
17  Games Center / WIP games, tools & toy projects / Re: Really a Markup Language (RML) on: 2014-10-20 06:22:14
Don't use @ in tag names since it would be impossible to use with XSLT.
18  Game Development / Newbie & Debugging Questions / Re: Best way to iterate through ArrayList? on: 2014-10-18 07:24:04
Ask yourself if using arrays is really simpler and more secure and why.

I wouldn't convert back and forth between arrays and lists all the time, but just go with List<Type> everywhere in the API (except for primitive types) .

If you insist on converting lists to arrays,  use
list.toArray(new Type[list.size()])
to avoid unnecessary allocations (see toArray javadoc)
19  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-10-17 08:52:17
You could try to include the arm-swing in the shadow, so it looks more related to the character.

normal shadow:
1  
2  
3  
 #####
#######
 #####


shadow on frame with left arm in front:
1  
2  
3  
 ######
#######
######



shadow on frame with right arm in front:
1  
2  
3  
######
#######
 ######
20  Game Development / Newbie & Debugging Questions / Re: .properties alternative? on: 2014-10-16 18:05:59
If you are using xstream, you can use the BinaryStreamDriver:
http://xstream.codehaus.org/javadoc/com/thoughtworks/xstream/io/binary/BinaryStreamDriver.html
for generating non human-readable output. IMO xstream is very easy to use and quite forgiving when classes change compared to pure java serialization.
21  Game Development / Newbie & Debugging Questions / Re: .properties alternative? on: 2014-10-16 15:24:10
You can just create a Java class representing your stored values and serialize it by making it Serializable and use standard java serialization:
http://www.tutorialspoint.com/java/java_serialization.htm
http://docs.oracle.com/javase/tutorial/javabeans/advanced/persistence.html
http://docs.oracle.com/javase/tutorial/essential/io/objectstreams.html

If you want to have the output readable, you can use XMLEncoder:
http://docs.oracle.com/javase/7/docs/api/java/beans/XMLEncoder.html

If you don't mind using 3rd party libs, take a look at XSTREAM
http://xstream.codehaus.org/tutorial.html

If you don't like having xml output, take the JSON route
http://xstream.codehaus.org/json-tutorial.html

Or look for other similar libs like:
- GSON: https://code.google.com/p/google-gson
- YamlBeans: https://github.com/EsotericSoftware/yamlbeans
22  Game Development / Newbie & Debugging Questions / Re: MD2 loader on: 2014-10-10 19:04:32
It puts the String "IDP2" into a 32bit integer. (Lookup http://en.wikipedia.org/wiki/Endianness)
23  Game Development / Newbie & Debugging Questions / Re: MD2 loader on: 2014-10-09 22:36:56
Also see http://sourceforge.net/p/jagatoo/code/HEAD/tree/trunk/src/org/jagatoo/loaders/models/
24  Discussions / General Discussions / Re: Mobile Java game development, without using a full-size laptop on: 2014-10-09 22:31:45
Apple's target audience are people with a lot of money and no idea about technology.
Err... no Stare

I also don't like apple products, but above statement is just BS - period.
25  Discussions / Miscellaneous Topics / Re: Is drinking half a bottle of vodka safe? on: 2014-10-09 14:11:30

The bottle and his "friend" Wink
26  Discussions / Miscellaneous Topics / Re: Is drinking half a bottle of vodka safe? on: 2014-10-09 14:01:03
Also keep in mind that vodka (at least for me) has delayed impact. This means you may feel that you can have some shot more, but in reality you already drank one too much  Shocked
27  Discussions / General Discussions / Re: Mobile Java game development, without using a full-size laptop on: 2014-10-06 09:04:10
@Cero
Resolution

Also finding a the right notebook is a cumbersome and frustrating thing. I am searching for example for a notebook with max 13.3", a non-glossy HD+ or FHD display, good WiFi reception, that comes in a color (e.g.  red) and doesn't burn your lap or sounds like a starting plane.

Doesn't seem to exist...
28  Game Development / Newbie & Debugging Questions / Re: (LWJGL) A new aproach on: 2014-10-05 00:29:17
http://www.sjbaker.org/steve/omniv/matrices_can_be_your_friends.html
29  Game Development / Newbie & Debugging Questions / Re: LWJGL Slick-Util Strange problems with drawing a texture several times on: 2014-10-02 18:20:12
Your unbinding is the problem.  Look up the bind() implementation in the source: it stores the last bound texture in a static variable and does skip binding, if the texture is the same to optimize performance (texture binds are expensive).  You can call TextureImpl.unbind() to clear that static variable.
30  Java Game APIs & Engines / Engines, Libraries and Tools / Re: How to install Eclipse on: 2014-09-29 17:12:32
Well,  I dont use eclipse and hate it with a passion, so I can't say if the support is that bad. Seing maven support as superfluous for game dev might be true. But a good SCM support should not qualify as bloat or junk...
Pages: [1] 2 3 ... 72
 

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

The first screenshot will be displayed as a thumbnail.

rwatson462 (29 views)
2014-12-15 09:26:44

Mr.CodeIt (20 views)
2014-12-14 19:50:38

BurntPizza (40 views)
2014-12-09 22:41:13

BurntPizza (76 views)
2014-12-08 04:46:31

JscottyBieshaar (37 views)
2014-12-05 12:39:02

SHC (50 views)
2014-12-03 16:27:13

CopyableCougar4 (47 views)
2014-11-29 21:32:03

toopeicgaming1999 (114 views)
2014-11-26 15:22:04

toopeicgaming1999 (102 views)
2014-11-26 15:20:36

toopeicgaming1999 (30 views)
2014-11-26 15:20:08
Resources for WIP games
by kpars
2014-12-18 10:26:14

Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

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
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!