Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (517)
Games in Android Showcase (123)
games submitted by our members
Games in WIP (578)
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
1  Discussions / General Discussions / Re: Would you donate your time and talent to create a commercial grade game? on: 2005-09-08 00:19:28
Quote
When Doom3 source becomes open, this woukd be a good oportunity to adapt it to java and see the benchmark difference. If a java version of Doom3 could compare to the c++ version this would sure raise a lot of noise. This would be a bit hard however. I noticed when looking at the Doom3 source there was a lot of optimized assembler code mixed with c++ in some places.  The jvm may have an hard time competing at this optimization level.

Why doesn't sun add a bytecode assembler language feature to java, doesn't C++ have something like this with

asm {
mov 0, 1 // I don't know assembly btw
}

?
2  Discussions / General Discussions / Re: Question about object arrays and tilemaps on: 2005-08-24 17:24:34
And one (minor) optimisation if you're worried about array-object overhead: be careful about the dimension ordering. As all arrays are ragged (or rather, potentially ragged) with 1d arrays hanging off of 1d arrays then a 2x200 array (3 objects) ends up with many less objects than a 200x2 array (201 objects).

It occurs to me that you could use a ragged 3d array instead of a 2d array + linked lists, but that just makes me cringe even thinking about managing that nicely without going insane(er).

Would it really be that hard? Couldn't you just increase the z dimension by 1 when you want another layer?
3  Discussions / General Discussions / Re: Question about object arrays and tilemaps on: 2005-08-24 08:31:35
Thanks for posting again!

Quote
1  
2  
3  
4  
5  
6  
7  
8  
int xDim = 128;
int yDim = 128;
int zDim = 10;

Tile[] tiles = new Tile[xDim * yDim * zDim];

// get tile at: x y z
tiles[((z * yDim) + y) * xDim) + x];


I tried your program again with different variables and it seems this approach saves the most memory of them all. I also see I could use some bit shifting for faster array accesses. Thank you so much for the help. Should I be careful about changing the maximum memory? For example if the max memory on a computer is 256 and I set the jvms heap size to 256 will the jvm overwrite memory used by the operating system?
4  Discussions / General Discussions / Re: Question about object arrays and tilemaps on: 2005-08-24 03:20:11
Thank you very much for the reply! I really apprechiate the code snippet! I typed your program and I found out after playing around with the variables and setting the third one to 1000 the jvm only allows (in eclipse) around 65 megs of ram to be used on 1 gig of memory, however the maximum number of layers I'll have is probably around 32 (around 2 megs for 128x128). This is slightly unexpected for me since you said that each array takes about 34 bytes, so I thought 128*128*32*34 = 17825792 bytes -> (17 megs) but it is actually around 2.3 megs in the program?. Thank you very much for the help!
5  Discussions / General Discussions / Question about object arrays and tilemaps on: 2005-08-23 11:18:39
Hello. How can I make a large tilemap (ie. 128x128x10) without using too much memory? I was wondering if I could just have something like this

1  
Tile[][][] tiles = new Tile[128][128][10];


Would this take up a lot of memory even though they're only null references?

I really need help since I want this to work with computers with more than or equal to 500 megs of ram.. Please help!
6  Discussions / General Discussions / Re: beanshell security issues on: 2005-08-20 01:55:38
It would be really nice if java supported a feature where you could turn on a safemode switch and then execute a beanshell script or use reflection, that way you could have all the flexibility (and speed if your using reflection) and the safety of a homemade scripting language.. I think applets do something like this where they run in the 'sandbox' or something.. I wonder if there's any libraries that give you that feature? Or could I enable the 'sandbox' in my application, is that possible?
7  Discussions / General Discussions / Re: Idea to decrease download sizes for users on: 2005-08-17 23:39:26
Cas that sounds like a great idea and I might use it myself if it's legal, is it? What about molebox? is it like a self executing winzip with encryption?
8  Discussions / General Discussions / Re: Idea to decrease download sizes for users on: 2005-08-17 05:41:41
Well after hearing all this it seems like it wouldn't work that well. But that doesn't mean theres not other ways to cut down on the size of the JRE, couldn't sun make a mini JRE for video games? Maybe it could be like j2me but bigger?
9  Discussions / General Discussions / Re: Idea to decrease download sizes for users on: 2005-08-16 22:50:12
I really hope sun looks into it more because imho it's a big problem in java, especially for general purpose applications.. Most programs made in java are small anyway so it seems like a waste to have to download 1000+ classes that have nothing to do with your program.. It also contributes to the idea that java is slow because there might be a more efficient jre available but the user doesnt' want to download it because it's more then 10 megs..
10  Discussions / General Discussions / Re: Idea to decrease download sizes for users on: 2005-08-16 10:35:47
Thanks for the reply.

You mentioned problems with versioning, why not just have a different cache for each version of a jre? or better yet replace only the classes that have gone up in a version number. If we could decrease the size of the jre that would be a huge selling point for games. BTW does sun have a problem with people who want to compile java into different exe files? is that legal?
11  Discussions / General Discussions / Idea to decrease download sizes for users on: 2005-08-16 09:07:51
Hi everyone.

I don't want my game to be larger then it has to be. A big factor in the size of Java programs is the JRE, which I've checked for java 1.5 is 15 megs for a windows installation which is probably too big for someone on a 56k.

So my idea is this, instead of downloading all the classes for the JRE from sun, instead download a file from sun that acts as a cache for classes so you only download the classes you need to run your program. So if my program uses the math class that class is downloaded from a repository on suns server and stored in a global cache on your computer, when another java program requests that class (import java.util.Math) java can find that class through the cache and this saves having to download a bunch of classes your program doesn't need... Of course if your program downloads a class that requires another class then both are downloaded in the cache.. Well this is just a idea, so take it with a grain of salt and please tell me your opinion..
12  Discussions / General Discussions / Re: beanshell security issues on: 2005-08-11 00:23:41
Thanks for the reply. As for using beanshell I think I might hold off on it for now, I might use it as a place holder before I make my own scripting language. It might be a good excercise to make a scripting language and possibly a little easier for a less experienced person to use.
13  Discussions / General Discussions / beanshell security issues on: 2005-08-10 20:40:10
Hello everyone.

I'm working on an extendable online game. I want to ship a map editor and a scripting language along with the game but I'm not sure if I should make my own scripting language or use something like beanshell. Normally I would just use beanshell and forget making something like a scripting language myself, but if people will be downloading other peoples scripts then someone could create a script that deletes for example the c drive on windows, is this possible? Is there a switch in beanshell I can turn on to disable possibly dangerous programming?

Any help would be greatly apprechiated.
14  Java Game APIs & Engines / OpenGL Development / Re: 60 fps normal? on: 2005-08-08 00:06:58
Thank you for the reply, this is very helpful!
15  Java Game APIs & Engines / OpenGL Development / 60 fps normal? on: 2005-08-07 23:04:25
Hello everyone.

I was wondering if I could get more then 60 fps with vsync enabled? One more question please, what is vsync and why without it do I get a lot of fps with everything very jerky?
16  Java Game APIs & Engines / OpenGL Development / Re: Can't get transparency working in lwjgl on: 2005-08-02 15:38:43
Thanks so much for the reply! I'll see if it gives me the result I want.
17  Java Game APIs & Engines / OpenGL Development / Can't get transparency working in lwjgl on: 2005-08-02 15:30:33
Hello everyone.

I've tried almost everything to get transparency working in lwjgl but I still can't do it, could someone tell me the steps I need to follow to accomplish this with out having to use masks?

some of the things I would like to know in specific is:

how should I load my textures? with GL_RGBA? And should I save my files as gif or png? are there any problems with the png format?

what variables should I enable to get transparency displaying correctly?

If this can't be solved and it's too much trouble to make masks then maybe I should go back to Java 2D which wouldn't be too good since I would like fast alpha blending and a good fps..

any help would be greatly apprechiated.
18  Discussions / Miscellaneous Topics / Re: post your favorite tools! on: 2005-06-12 15:40:23
Could I write and send you a draft of a website with reviews and links?
19  Discussions / Miscellaneous Topics / Re: post your favorite tools! on: 2005-06-12 15:21:22
Hi Nonnus.

I've used the Netbeans form designer, which is pretty easy to use. But I've started to code my GUIs by hand again for tools. One of the things that annoys me about the form designer is that you can't change certain code without having to copy and paste the code to a .java file which means you can't go back to the form mode...

Here's another tool I use occasionally: http://goldenstudios.or.id/products/utilities/combine/index.php
it combines sprite images into a single file ready for use by your game.. It also can export to a few formats.. I'm not sure if having the sprite images side by side in one file is as great as it sounds as it doesn't let you have alot of freedom with bigger sprites, like bosses.. Is there a way around this? Maybe more empty space around each individual sprite image?

Any other tools posted here would be greatly apprechiated by me and everyone who is interested in tools for development Smiley
20  Discussions / Miscellaneous Topics / Re: post your favorite scripting language on: 2005-06-11 21:36:19

The only thing I want is a higher turn over rate. "Zero" delay and no need to restart your app or to reload any resources. That's the biggest advantage. A 100% java-ish language can be also turned into usual classes at the end, which is imo a much bigger advantage than a less restricted syntax. (I personally don't mind a bit more typing work... it only accounts for like 0.05% of a project's time.)

In that case maybe pnuts would also be a good choice. Like sma said it's benchmarked as the fastest scripting language for the JVM..
21  Discussions / Miscellaneous Topics / Re: post your favorite scripting language on: 2005-06-11 14:09:29
sma thanks for the very detailed discription of some popular scripting languages! very useful!  Smiley
22  Discussions / Miscellaneous Topics / Re: Any good reasons to learn c/c++? on: 2005-06-11 14:00:33
Thanks everyone!

It looks like C might actually be helpful. I could even use eclipse for development with some plugins, which is a big plus. Theres also plenty of code written in C which is a good reason to learn it.  Is there a place I can learn all about the language syntax and standard library? what about  "The C Programming Language" don't they call this K&R? Thanks again for the help! I hope that's not too many questions..
23  Discussions / Miscellaneous Topics / Any good reasons to learn c/c++? on: 2005-06-11 11:06:22
Hello everyone.

I was wondering if there is any good reason to learn c or c++ once you know java pretty well. Are there any benefits at all or is it a waste of time?
24  Discussions / Miscellaneous Topics / Re: post your favorite tools! on: 2005-06-11 08:00:17
I guess if the tool discussion is limited to perticular tools or game development then maybe this should be posted in offtopic. How do I put this in offtopic?
25  Discussions / Miscellaneous Topics / Re: post your favorite scripting language on: 2005-06-10 14:32:51
So java can be used as a scripting language because it loads classes dynamically? Could I use the reflection apis to call methods and such at the speed of java instead of the speed of a embedded scripting language? If that's the case I would have compile the code, but that shouldn't be too hard unless you edit things a lot in a game. A game like a rpg or something where your changing the npcs behavior alot..

btw kevglass, didn't you mention that scripting with a gui is easy to use for developers inexperienced in programming, and makes sure that they don't mess up the game rules. Isn't there a middle ground here? Why not code some library that encapsulates the game rules and maybe use the facade pattern to wrap the game entities and other data that they might try to access? Just a thought..
26  Discussions / Miscellaneous Topics / Re: post your favorite scripting language on: 2005-06-10 09:26:37
SpiritWolf,

Personally, I like groovy for scripting. However, I a bigger fan of determining your operating context and writing an object hiearchy to support interacting with it. Through trial and error I've discovered that integrating scripting languages just doesn't work for *me*. At the end of the day, I don't want my desigers scripting things, I want them using tidy GUIs to define how they'd like things to work. If they're going to use GUIs, then the format underneath doesn't matter as much.

Kev

Do you mean defining a scripted event with a GUI?
Is using a GUI to define the scripted events as flexible as a full-fledged scripting language?
27  Discussions / Miscellaneous Topics / post your favorite tools! on: 2005-06-10 08:21:50
Hello everyone! Please post your favorite tools or the ones you use the most.

I don't use that much:

Netbeans,
Eclipse,
Gimp...

Any other tools that you find useful please post them here! Any tool would be greatly apprechiated!

Thanks!
28  Discussions / Miscellaneous Topics / Re: post your favorite scripting language on: 2005-06-10 07:56:47
That doesn't seem to make sense that the java runtime can also run uncompiled java files. Is this really possible? If it is, what is the purpose of beanshell?
29  Discussions / Miscellaneous Topics / post your favorite scripting language on: 2005-06-09 15:56:14
Hello!

Please post your choice of scripting language! I've been learning my first agile programming language groovy.
30  Discussions / General Discussions / Re: golden t game engine vs gage engine on: 2005-06-03 22:35:17
Thanks for the advice!

I think for now at least I'm going to use gtge and see if I can make a game. At that point I will have a better idea how to make my own 2D game engine using LWJGL.

Thanks again!
Pages: [1] 2
 

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

The first screenshot will be displayed as a thumbnail.

DarkCart (10 views)
2014-10-31 21:44:48

DarkCart (13 views)
2014-10-31 21:43:57

TehJavaDev (40 views)
2014-10-27 03:28:38

TehJavaDev (30 views)
2014-10-27 03:27:51

DarkCart (44 views)
2014-10-26 19:37:11

Luminem (25 views)
2014-10-26 10:17:50

Luminem (30 views)
2014-10-26 10:14:04

theagentd (36 views)
2014-10-25 15:46:29

Longarmx (64 views)
2014-10-17 03:59:02

Norakomi (62 views)
2014-10-16 15:22:06
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

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
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!