Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (476)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (530)
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  
  to JET or not to JET...  (Read 5136 times)
0 Members and 1 Guest are viewing this topic.
whereisthemoney
Guest
« Posted 2003-09-05 19:23:48 »

Hi Smiley

I just finished work on a game Cool and I'm trying to find the best way to distribute it to the world.  I thought about JET of course but unfortunately, after the distributable was finished the final product required not only JET's files but JRE as well (I wasn't using Swing and I thought I'd get away with it, but JET doesn't cover AWT either. So the final distributable is 50MB (!), which is crazy.

Is there any way to make the distributable smaller? Is there any other compiler that might do the trick? (native code please, no JRE installation should be required).

Thanks
whereisthemoney
Guest
« Reply #1 - Posted 2003-09-05 19:29:19 »

Sorry I forgot to add that compression limits the size to 20MB which is still quite a lot ...
Offline erikd

JGO Ninja


Medals: 16
Projects: 4
Exp: 14 years


Maximumisness


« Reply #2 - Posted 2003-09-05 19:33:17 »

You probably didn't use the 'professional ' edition of JET which is able to produce stand alone executables, although I think that requires a dll from AWT as well. Which in turns requires distribution of the complete JRE due to license restrictions.
(You might want to check this, I don't know if the java license still has this restriction).
If you want to produce just an exe without violating licenses, you should not use AWT but for example LWJGL.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
whereisthemoney
Guest
« Reply #3 - Posted 2003-09-05 21:06:24 »

Thanks. I am using the "professional edition" evaluation package, which produces stand-alone executables provided that you don't use Swing or AWT.
Anyway, I wish things were simpler as far as Java deployment is concerned...

Quote
You probably didn't use the 'professional ' edition of JET which is able to produce stand alone executables, although I think that requires a dll from AWT as well. Which in turns requires distribution of the complete JRE due to license restrictions.
(You might want to check this, I don't know if the java license still has this restriction).
If you want to produce just an exe without violating licenses, you should not use AWT but for example LWJGL.

Offline GergisKhan

Junior Member




"C8 H10 N4 O2"


« Reply #4 - Posted 2003-09-05 21:09:31 »

Is there a chance you could use jar files and use Java WebStart to distribute your game?  It's not compiling to native code, but at least you get around the liability of not using Swing/AWT.

gK

"Go.  Teach them not to mess with us."
          -- Cao Cao, Dynasty Warriors 3
whereisthemoney
Guest
« Reply #5 - Posted 2003-09-05 21:28:12 »

Not a bad idea. Thanks.

Although you know, it kinda pisses me off that we have to use these "weird" execution techniques (weird to non-programmers) when it comes to Java. I think the language has grown to the point where a compiler (that doesn't cost *Dr.Evil's voice* "1 billion dollars") is essential...
Offline SpongeBob

Junior Member




Who lives in a pinnapple under the sea


« Reply #6 - Posted 2003-09-05 21:49:41 »

You could also not use JET and just use GCJ to compile your code.  GCJ is fast and free.  GCJ does not include AWT or SWING.  Use SWT instead.
whereisthemoney
Guest
« Reply #7 - Posted 2003-09-05 22:01:41 »

Bob, have you managed to create a Windows executable (a game preferably) with GCJ/SWT? Because I've heard that it doesn't really do the trick (but I've never tried it myself)...

Quote
You could also not use JET and just use GCJ to compile your code.  GCJ is fast and free.  GCJ does not include AWT or SWING.  Use SWT instead.

Offline princec

JGO Kernel


Medals: 339
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #8 - Posted 2003-09-05 22:45:30 »

As a longtime Jet user I have this to say:

You have no choice but to eliminate AWT and Swing from your application entirely and pay the £500 for Jet Pro. It's worth every penny and produces excellent, super-fast code with a great footprint.

If you insist on using AWT, you are actually far better off shipping with either a bundled JRE (8MB or so) or using Webstart and asking your customers to get the JRE themselves.

A JAR file by the way is approximately 80% of the size of a typical compressed Jet EXE. The bigger your game is the less the JRE counts against it.

Cas Smiley

Offline SpongeBob

Junior Member




Who lives in a pinnapple under the sea


« Reply #9 - Posted 2003-09-06 00:37:22 »

Quote

Bob, have you managed to create a Windows executable (a game preferably) with GCJ/SWT? Because I've heard that it doesn't really do the trick (but I've never tried it myself)...


Ive created windows apps with GCJ and SWT.  Here's an article covering doing this:

http://www-106.ibm.com/developerworks/java/library/j-nativegui/?Open&t=grl,l=805,p=cgui

I have to agree with PrinceC that AWT and SWING are not ideal for game development.  SWT is not much better.  But it often depends on exactly what type of game your designing I guess.  Most commercial games do not use native gui controls.  Game designers often create thier own controls from scratch to blend more with the games look and feel.

If you are gonna use SWT and GCJ on MS Windows I suggest using the GCC/GCJ toolchain at www.thisiscool.com.  It includes some SWT examples in the distro.  Use 3.3.  I found a few issues still remain in the development 3.4.

Also, executable sizes with GCJ for small programs can seem rather large.  This is because GCJ created executables include the java runtime.  You can cut this down by using UPX (upx.sf.net).  Kills like 60% of the bloat or more.

Webstart is not a bad option also.  I have mixed thoughts on using it for games though.  Theres a few games people have put out in this forum that use webstart like Wurms.  Check them out and see what you think.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline GergisKhan

Junior Member




"C8 H10 N4 O2"


« Reply #10 - Posted 2003-09-06 02:09:27 »

<threadjack>

I would like to hear from anyone who has designed their own game components outside of Swing, and isn't using DirectX/OpenGL solutions for their game.  Specifically, what are your experiences?  How are you drawing to the screen?  How happy are you with your new components?

</threadjack>

gK

"Go.  Teach them not to mess with us."
          -- Cao Cao, Dynasty Warriors 3
whereisthemoney
Guest
« Reply #11 - Posted 2003-09-06 07:49:02 »

I'm sorry, I might say something stupid here but I have created my own gui controls (no Swing/AWT buttons etc) and still have to use AWT. GraphicsDevice, Frame, Toolkit, Color, Image, MemoryImageSource, etc, these are all in java.awt.*.
I have created a 2D space shooter with no need for any OpenGL or anything, so I guess I didn't do anything fundamentaly wrong by not using an external library... (unless of course I did  Roll Eyes )

Quote

I have to agree with PrinceC that AWT and SWING are not ideal for game development.  SWT is not much better.  But it often depends on exactly what type of game your designing I guess.  Most commercial games do not use native gui controls.  Game designers often create thier own controls from scratch to blend more with the games look and feel.

Offline cfmdobbie

Senior Member


Medals: 1


Who, me?


« Reply #12 - Posted 2003-09-06 23:08:43 »

It's not that AWT/Swing are bad for game development, it's just that if you want to get the best possible result from Jet it's worth ditching them.

I believe it was Cas who said a while back "you need powerfully good reasons not to use Swing".  A requirement to deploy as small-as-possible Jet-compiled binaries might be such a reason, although using Jet shouldn't be an actual goal, more a solution to a different goal, if you get what I mean!

Hellomynameis Charlie Dobbie.
Offline GergisKhan

Junior Member




&quot;C8 H10 N4 O2&quot;


« Reply #13 - Posted 2003-09-07 00:51:01 »

Aha.  Ehe.  Hm.

I would love to treat that statement as a sort of gospel (even though I advise against sticking to any one rule a bad thing): "you need powerfully good reasons not to use Swing."

Because, in truth, I *LIKE* Swing.  It does the job.  Perhaps not well, but it does the job.

I'm waiting for the day Sun tells us Swing's being rewritten on top of OpenGL.  Now THAT would be cool.


Trying to return to topic: I have found one really good reason not to use Jet: AFAIK, Jet can only produce Windows binaries.  If you're trying to be multiplatform, this defeats your purpose.  My Jet knowledge is minimal, so please correct me if I'm wrong.

gK

"Go.  Teach them not to mess with us."
          -- Cao Cao, Dynasty Warriors 3
whereisthemoney
Guest
« Reply #14 - Posted 2003-09-07 06:12:39 »

Quote
I have found one really good reason not to use Jet: AFAIK, Jet can only produce Windows binaries.  If you're trying to be multiplatform, this defeats your purpose.  My Jet knowledge is minimal, so please correct me if I'm wrong.


Yes, you're right. But you know if thinking (just thinking) about selling this game as shareware when I'm done, and when it comes to selling software, Windows is your only choice. I'm a Linux guy and I know: Linux people don't buy software. Especially shareware. Mac users are too few compared to Windows users. So if I was able to make a foolproof, classic installation method for Windows, that would be great.

To me it, Sun made a mistake when they sued M$ for changing the JRE in Visual J++ (when was it, '97?). I mean, so what? Today we'd be building Win32 Java executables with visual studio and Java would be many times stronger than it is today. By suing M$ at the point, Sun gave a clear message to everyone: you cannot touch Java, only Sun can (and look what they did: they (Sun) had the slowest, bugiest JVM around for 4 years. Even today in 1.4.x the one (1) person who takes care of java's sound, messed it up big with AudioClip). Just what Apple did with their computers and look where they're now (saleswise). I mean I never really heard anyone complaining about Visual C++...
whereisthemoney
Guest
« Reply #15 - Posted 2003-09-07 06:28:14 »

I just wanted to add that we here are game developers. And unfortunately, Linux is a piece of shit when it comes to gaming. (We pray that a game studio releases their source code of a 6 year old game, so that someone can build a Linux port). Are there any Linux game port companies left? I don't think so. So why should we, Java game programmers build Linux games if nobody cares?

Offline kevglass

JGO Kernel


Medals: 120
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #16 - Posted 2003-09-07 07:49:30 »

As a hobbiest, the only answer is:

Because we can!!

I guess as a commercial developer you could argue that many analyst reports are saying that the home desktop is growing in the linux market and hence there is a nice new market openning up that most of the existing game developers don't really know much about. (I'm not sure I'd argue this, but its just another side to the coin)

You could argue the same thing about MacOS, who really wants games there, mostly Macs are work horses.

Kev

Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #17 - Posted 2003-09-07 09:49:27 »

Quote
I just wanted to add that we here are game developers. And unfortunately, Linux is a piece of shit when it comes to gaming. (We pray that a game studio releases their source code of a 6 year old game, so that someone can build a Linux port). Are there any Linux game port companies left? I don't think so. So why should we, Java game programmers build Linux games if nobody cares?



Don't make the mistake of thinking people don't care. Windows comes free with nearly all PC's (and you don't usually get a refund if you ask for a PC without one, thanks to some rather dodgy MS practices). If you have a PC, you probably have windows...even if you run Linux, if you're a games player you keep windows around simply to play games.

There was a time when you kept windows around mainly because there were lots of basic apps you occasionally needed that only existed on windows - but now there's a top-notch web-browser, email, graphical IDE's, desktop, DVD/mpeg/mp3 players, Office clone that's 99% compatible with MSOffice, etc etc. IME, few people actually need Windows for anything other than games these days...leaving aside all those who depend on custom applications.

Hence people like lokigames go out of business at least partly because the vast majority of PC players who'd play a linux conversion already can play it on windows. And for many of the games, you had to buy the original first anyway - so why the heck would you bother paying extra to be able to play something you already owned on linux as well as windows? (cough cough American business practices - sell you something you already own  Tongue).

Healthy demand for linux games exists, but it's masked by the widespread existence of Windows. This is a chicken-and-egg situation of course - until the good games start appearing on linux and windows simultaneously, people will still need to reboot into windows to play their favourite games, and so won't bother showing demand for any particular game to move to linux - e.g. they have to reboot to play Doom3 anyway, so they don't mind doing it for Warcraft 4 as well. But when (if) a significant number of people's favourite games don't need the reboot, they will be less inclined to play the games that require extra effort (no-one enjoys rebooting Wink).

IMHO even if such a sea-change occurs, it's at least 5 years away, and will only happen because - like RenderWare - the cost economics of writing in java can very rapidly make java games the norm (look at how fast and large RW grew...admittedly this is largely due to their infamous sales force, but it also had something to do with the palpable sense of relief to developers who no longer had to support three or four target platforms, but just one).

IMHO.

malloc will be first against the wall when the revolution comes...
Offline princec

JGO Kernel


Medals: 339
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #18 - Posted 2003-09-07 10:55:53 »

Quick chime in on the multiplatform issue:

1. We've to date had 1 confirmed Linux sale, which makes the Linux:Windows ratio 1:45 or so, which is somewhat less than our Linux:Windows site visitors ratio of about 1:10

2. MacOS, though under 3% of the total distribution of PCs, has plenty of anecdotal evidence to say that they are about 10 times more likely to buy your software; when we release the Mac version we are expecting at least 30% of our sales to come from the Mac

3. When it's trivial to get your game running on the Other Two OSs, porting is just a non-issue. The reason why Linux users keep a Windows system round to play games is because it's a big pain porting games to Linux so very few make it. But the more compelling games they have the more they can stay in their Linux boot. And as for the Mac, they're so anti-windows they tend to stick with MacOS and the few games they have. This, combined with their general affluence, leads them to be very good prospects for a sale.

It cost me *nothing* to get my game running on Linux. It Just Works. I expect the Mac one to do the same. So don't be thinking about Win32-only games any more; there's no need, it's been proven you no longer need to concern yourself with it.

Cas Smiley

whereisthemoney
Guest
« Reply #19 - Posted 2003-09-07 20:04:39 »

I'd like to return to the topic and ask,
what is your favorite AWT replacement for 2D games?

Thanks.
Offline tortoise

Junior Member




<3 Shmups


« Reply #20 - Posted 2003-09-08 05:42:35 »

Favorite AWT replacement? As far as I know there's only one, LWJGL. Is there any other way to make a Java game without AWT (without doing it completely from the ground up)? What can you do with SWT and gaming?

Sure, you've gotta use OpenGL with LWJGL, but it's actually pretty simple, especially for 2D stuff. Check it out, it's good stuff.
Offline cfmdobbie

Senior Member


Medals: 1


Who, me?


« Reply #21 - Posted 2003-09-08 08:48:34 »

Depends what you're talking about when you say "AWT replacement".  As a way of getting graphical stuff to appear without touching AWT, LWJGL is an alternative - but as a way of handling and displaying widgets, it is not.

Don't underestimate the work required to write a GUI!

Cas' SPGL is a utility layer on top of LWJGL, and he's now released the Spaghetti GUI subproject as well.  Still very much in development and nowhere near as complete as something like the AWT, but may be worth a look if a GUI is what you need to replace.

Hellomynameis Charlie Dobbie.
Offline kevglass

JGO Kernel


Medals: 120
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #22 - Posted 2003-09-08 09:04:07 »

It also depends if by AWT you mean Java2D, e.g. java.awt.Graphics. At which point you bring Jogl in aswell. You could also consider normal accelerated Java2D as alternaive to Graphics.

Kev

Offline oNyx

JGO Coder


Medals: 1


pixels! :x


« Reply #23 - Posted 2003-09-08 12:11:59 »

Quote

[...]e.g. they have to reboot to play Doom3 anyway[...]


That's a bad example. There will be a linux version too. I dont know if they will be released the same day... however I bet 5$ that it will be the way it was with Q3. Take the pack files from you windows version, install the latest (linux) update et voila you have a linux version Smiley

Imo it's really awesome id did it that way.

弾幕 ☆ @mahonnaiseblog
Offline cfmdobbie

Senior Member


Medals: 1


Who, me?


« Reply #24 - Posted 2003-09-08 12:37:13 »

Quote
Imo it's really awesome id did it that way.

Agreed!  Linux only has AAA games because Id got the ball rolling - if Id hadn't shown the way, other companies wouldn't be making games for Linux.  I would even go so far as to say that if Id hadn't shown the way, other companies wouldn't even have contemplated making them!

It took a determined man, with a passion for technology, in a position of influence but with enough cash to be able to risk failure, to make that first leap.  I think Id still lost money on the deal (as Loki died owing them a lot of cash), but they still seem to feel it was and is the right thing to do.

Hellomynameis Charlie Dobbie.
Offline SpongeBob

Junior Member




Who lives in a pinnapple under the sea


« Reply #25 - Posted 2003-09-09 04:03:49 »

Quote

I'd like to return to the topic and ask,
what is your favorite AWT replacement for 2D games?  


SDL.

Quote

As far as I know there's only one, LWJGL.


Theres also Gage.  LWJGL is a 3d api from what I have seen.  Not saying you couldnt throw some quads around with textures to make some 2d.

Quote

What can you do with SWT and gaming?


Pretty much of what you can do with the basic AWT graphics.  Theres also a plugin for OpenGL.  Haven't tried it though so I have no idea on quality or completeness.

Final note: dont leave Linux in the dark.  Sure, having a Windows port is pretty much required if your looking at selling and making money.  But Linux will continue to grow.  Check out happypenguin.

www.happypenguin.org
whereisthemoney
Guest
« Reply #26 - Posted 2003-09-09 15:25:12 »

Let me get this straight (because I'm new here). Everyone in the forum who's doing games seriously they're using LWJGL?

I mean the reason I picked Java for my last game was because AWT is such a clean API, that lets you do graphics quickly and easily (esp. since v1.4.x). Why go through all the trouble and use all these JNI calls and other shortcuts if you think the AWT isn't good enough. Just to use garbage collection and avoid pointers?

Maybe it's a case of me not seeing Java from the depth that some of you might do, but I like like Java because with all its embedded tools/libraries, you don't have to reinvent the wheel.

I mean if DirectX wasn't the ugliest API ever, I'm not sure if I would be using Java right now.

Maybe Cas has the answer, as he's done all this great stuff by now...
Offline Mojomonkey

Senior Member




ooh ooh eee eeee


« Reply #27 - Posted 2003-09-09 15:31:17 »

Personally I use Java because:

1. I write Java software professionally, so work with it every day and understand it more than others. (Probably a reason I should use another language in my free time...)

2. JVM allows for "write once, run anywhere" usually.

3. Syntactically it's a lot cleaner (for me at least) than C/C++.

4. Great choice in Java tools vs. VS for C/C++.

5. Great community.

6. Right now there is a lack of gaming software (games, middleware, etc) written in Java, so there's a lot of potential.

Those are the major ones for me.

Don't send a man to do a monkey's work.
whereisthemoney
Guest
« Reply #28 - Posted 2003-09-09 15:55:15 »

Exactly the reasons I use Java for. But I wasn't looking for such answer. If you remember when Java 1.4 was announced it was promoted as a gaming language (remember the videos?) I am personally using these Java libraries, but from what I understand most of the guys here don't. The question is if you don't like the libraries provided by Sun, why sticking with Java anyway?
update I'm only talking about game programming here.

Quote
Personally I use Java because:

Offline Orangy Tang

JGO Kernel


Medals: 56
Projects: 11


Monkey for a head


« Reply #29 - Posted 2003-09-09 16:29:53 »

Quote
Let me get this straight (because I'm new here). Everyone in the forum who's doing games seriously they're using LWJGL?


I'd guess that the two main APIs being used are Java2d and LWJGL. Jogl seems to be picking up support (i've switched from LWJGL since i need lots of Swing widgets) as is Joal and JInput.

Java3D seems to have a few people hanging on to it, but i think most will be switching over to Xith3D (which is Jogl based).

[ TriangularPixels.com - Play Growth Spurt, Rescue Squad and Snowman Village ] [ Rebirth - game resource library ]
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.

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

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

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

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

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

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

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

MustardPeter (34 views)
2014-07-16 23:30:00

Cero (50 views)
2014-07-16 00:42:17

Riven (50 views)
2014-07-14 18:02:53
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!