Jump to content
  • entries
    10
  • comments
    53
  • views
    12,572

See Jar Run?


tmont

903 views

So I finally figured out how to work this .jar crap, which makes java applications executable (i.e. running applets without an internet connection). They work on my machine, but I know very little about these .jar files and how they work. Can someone download these and tell me if they work? And if they don't, can you specify what happens, and what java stuff you have installed (jdk, platform, etc.)? Or, alternatively, if you know stuff, you can straight up tell me how these things work.

 

Thanks a bundle.

 

Hmmm, can't even attach them. Here's some so-fine links:

 

Playfield Editor (22.3 KB)

Map Editor (12 KB)

 

All you have to do is download it, and then double click on it. Hopefully, a window will pop up that looks like one of these:

 

mapeditor.jpegpfe.jpeg

10 Comments


Recommended Comments

Not sure if this is what you are asking, but a jar file is nothing more than a zip file containing a bunch of Java classes. Literally, you can make your own using Winzip or whatnot if you just rename it to have a .jar extension.

Link to comment

Well, that's not really what I'm asking. I just want to know if other people can get these to work, as it took some serious hot-linking to find information on how to create these (changing the environment variables and such), and I'm curious if they will work, for instance, on someone's machine that has something older than jdk 1.4.2 installed. And while a zip will compress the .class files, I don't think it will actually run the application (I thought that was the whole novelty of the jar). Or will it? Information on anything concerning java is ridiculously terse.

Link to comment

They work just fine on my mac, using java -jar pfe.jar for instance. However, I have jdk/jre 1.4.2 so that's probably not much help.

Link to comment

Thanks guys. I tried it out on a couple different computers, and it worked every time. I think as long as you have the Java 2 platform (which is included in the browser installation... maybe?), it'll work. The jdk has nothing to do with it, I don't think.

 

They both work for me, too (OS X). Spiffy. Any chance of importing/exporting bitmap files from/to graphics apps?

 

Uh... I don't know what that means. Which one are you talking about, and what is a bitmap file?

Link to comment

Like a gif or bmp graphics file. So that someone could create something in Photoshop (for example) and bring it into your program to tweak it, or export it as code. I create most of my graphics in Photoshop, but it doesn't do mirroring or duplicating for playfield graphics.

Link to comment

Oh. It was the literal explanation. As far as importing from Photoshop (or wherever), that's pretty much impossible. You'll have to redraw it or import it from code if you want to edit it with my program. As far as exporting to a graphics program, I suppose you could just screenshot it, and then copy and paste. I wrote this about 6 months ago, so I'm not really in the mood to tweak it anymore. Well, I'm not in the mood to work hard at tweaking it anymore. :)

Link to comment
Like a gif or bmp graphics file. So that someone could create something in Photoshop (for example) and bring it into your program to tweak it, or export it as code. I create most of my graphics in Photoshop, but it doesn't do mirroring or duplicating for playfield graphics.

So, I've been doing a little experimentation with hex-editing, and I decided to put my newfound knowledge to some kind of use. So I implemented this feature, in a very rudimentary way. You can now import a bitmap file (.bmp), but there are a few restrictions: the bit-depth must be 24, it must be 40 pixels wide, and it must be between 20 and 180 pixels tall. This is rather annoying, I know, because pixels are square and playfield pixels are rectangular, so the bitmap file in the graphics program will look slightly different than what it will look like as an Atari 2600 playfield. Also, it doesn't import color. What it does do, however, is treat everything that isn't white (red=255, green=255, blue=255) as "active," and will only draw those non-white pixels to the screen. I demand a 24-bit bitmap because the pixel data is far simpler (no pallettes). And I'm also lazy, although both reasons are essentially the same.

 

Yeah, probably isn't real useful, and this program needs some tweaking anyway, but I wanted to try some stuff out.

 

I packaged it into a jar file, along with a readme that explains this stuff (it's not really that complicated). To run it, either double click on it, or, if you hate yourself, run it from the command line with

 

java -jar PlayfieldEditor.jar

 

pfe.zip (24.1 KB)

Link to comment
Now allow exporting to bitmaps.

I was actually going to do that. But then, amazingly, I erased all (current versions) of my source code. And I don't feel like rewriting it. Yes, yes, I am a flaming idiot.

Link to comment
Guest
Add a comment...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...