Author Topic: An Ambitious Project (may need help eventually)  (Read 3760 times)

0 Members and 1 Guest are viewing this topic.

Offline Snail

  • SC 5
  • 214
  • Posts: ☂
Re: An Ambitious Project (may need help eventually)
Hey look, it's a pretty butterfly.  ;)

 

Offline aldo_14

  • Gunnery Control
  • 213
Re: An Ambitious Project (may need help eventually)
Now that I have implemented missiles, worked out a very simple AI which I can apply to missiles and ships, and have figured out an annoying bug, I can take a brief break to... ask for suggestions for what area to develop next.

Be specific, and if you know programming or can sort of understand how I did what I've done so far, tell me how you think it could be implemented.

As for debris, I like the idea, it would help with final explosions of ships, but I don't know exactly how I would do it. Does anybody here have any suggestions? I could model each piece as its own image (breaking the ships into chunks), but that would be slow and inefficient.

For those of you who know Java, I am using the java.awt.* libraries, as well as java.awt.image.* to create rotating images. Specifically, I use AffineTransforms to rotate the camera, and the ships. I am doing a LCS(Local Coordinate System) to WCS (World) to CCS (Camera) approach. It is working quite well at the moment, although it can get quite slow sometimes when there is a lot of action on the screen. I don't know if it could be improved by having a faster computer or whatnot, but I don't really have that as an available option.

The missile I'm using is from a screenshot in fred of interceptor.pof, which i replaced the fighter01.pof model of the ulysses temporarily with. It looks pretty good, IMHO. I will post screenshots soon, possibly after I add shockwaves. However, the shockwaves I use may need to be from the retail version (I can't seem to access the .eff and .dds files in the .vp's with anything I know of). Maybe I will use the FS1 shockwaves instead.

Not using JOGL?  I think there's also another accelerated middleware library for java somewhere too, from what I remember awt can be a littl inefficient.

(I'll have to admit trying and giving up something like this a wee while back, to keep me occupied for a few hours at night when I was on work trips; you've done a far better job than I managed, though)

Quite impressed by your sample jar, though, albeit I think there's a smidgen of jerkiness in it (big bugbear I had, which somes seems to just be down to java itself, perhaps the VM limitations or somesuch); I've always found performance to be an utter bastard, albeit my very brief experiments with JOGL did see a good bit of improvement (we're talking Pong level stuff, natch).

 

Online Aardwolf

  • 211
  • Posts: 16,384
    • Minecraft
Re: An Ambitious Project (may need help eventually)
Additional screenshots! 2 of them, so far!



Gah!!! It shrunk them horribly!!!!!!!!!!!!!!!!!!!!!!

Well, in the second one, you can see a missile trail, sort of. In the first, if you look closely or increase the contrast or something, you can see about four of them. They fade as you zoom out, and get wider as you zoom in.

BTW, where can I get JOGL? I think, if I can figure out how to make the necessary changes, that library / those libraries could be especially useful for this project.

 

Offline Snail

  • SC 5
  • 214
  • Posts: ☂
Re: An Ambitious Project (may need help eventually)
Are the windows on the Hatsheptsut (sp?) glowpoints? That would be amazing.  :yes:

 

Online Aardwolf

  • 211
  • Posts: 16,384
    • Minecraft
Re: An Ambitious Project (may need help eventually)
Well, I don't know what a glowpoint really is, per se, other than that it glows and that it's probably a point (I don't know about implementation or that sort of thing, or how they are different from other glowing things), but yes, they do glow, and they show up as gray if you don't have glowmaps on, which sucks.

Also, I have "given up" on JOGL because I can't seem to find any damn constructors for the GLJPanel or GLCanvas objects, which is really really really really ... really annoying. If, when I am done with this project, or when I have gotten to a release point, someone would like to work on JOGL-izing it, please feel free to do so; as long as you don't make any major changes and you give credit, I don't (currently) have a problem with it. I reserve the right, however, to change my mind on this at any time prior to the first release.

Edit: I have fixed the bug (I don't think it appears in the video) where your bullets collide with you if you are moving too fast. This also removes any possibility of blowing yourself up (until AOE is implemented). Also I have added a shockwave that emanates from a destroyed capship, and have limited the explosion time. The jerkiness (aldo_14 noticed it in the video) is a problem, and it gets worse with more primary-fire, idk why this is, '.' (crude attempt at "because" symbol) there are just as many enemy shots as player shots usually, and tons of missiles in other versions.
« Last Edit: August 08, 2006, 06:37:18 pm by Aardwolf »

 

Online Aardwolf

  • 211
  • Posts: 16,384
    • Minecraft
Re: An Ambitious Project (may need help eventually)
I hate to be the one to push my own thread into "Hot Topic" status, but...

A video showing a dogfight between 3 SF Maras and the player (Herc) is complete. In the actual game (lost in video some reason) the player's shots have a blue tint, and the enemies' are orange-tinted. I'm not even very good at this game. It's perfectly fair-- the ships right now (and weapons) have identical statistics-- it's just that it was 3 : 1, their favor. I'm still having the problem with it running too slowly.

Edit: Oh, right. The video. Here it is:

http://s93.photobucket.com/albums/l77/Aardwolf001/2D%20FreeSpace/?action=view&current=2DFS2v02.flv

 

Offline Mars

  • I have no originality
  • 211
  • Attempting unreasonable levels of reasonable
Re: An Ambitious Project (may need help eventually)
Why flash? Flashing is bad.

  • You can get arrested for flashing
  • Flashing makes people scared of you
  • There are better things to do than flashing, like Real Playing, Windows Mediaing, and Quicktiming

 

Online Aardwolf

  • 211
  • Posts: 16,384
    • Minecraft
Re: An Ambitious Project (may need help eventually)
Because Photobucket supports video. I'll try to get it in another format. Please hold.

Edit: Alright, here's the situation: Photobucket converted my files to .flv for some stupid reason, even though the files I uploaded were .avi. I'm currently uploading the files on Google Video. Unless you live in China, you should be able to access this, and it should be in the format I uploaded it in to for which what hey?. Thank you for noticing that something was wrong, Mars, even though I didn't understand what you were saying at first. My mistake.

Edit: I hate everything! Google Video also changed the file type to a Flash video! Is nothing holy!?!?!?

Edit: You're probably grumpy if you can't load it, but think how pissed off I must be! Anyway, you can access the second movie (mentioned in the previous post) here: http://www.megaupload.com/?d=BKPL4XTZ just go through exiting any popups and that sort of **** until it lets you download it by typing in a set of three letters and clicking "Download" somewhere near the top-right.

Edit: I've done a lot of editing because I'm kind of reluctant to make an additional post. This one's got some content, though: once somebody is able to download the video, please make a post in this thread (only one is needed) with a link to the video on some other server that can be downloaded as a(n) .avi or as a .zip file!
« Last Edit: August 09, 2006, 01:23:12 am by Aardwolf »

 

Offline aldo_14

  • Gunnery Control
  • 213
Re: An Ambitious Project (may need help eventually)
Well, I don't know what a glowpoint really is, per se, other than that it glows and that it's probably a point (I don't know about implementation or that sort of thing, or how they are different from other glowing things), but yes, they do glow, and they show up as gray if you don't have glowmaps on, which sucks.

Also, I have "given up" on JOGL because I can't seem to find any damn constructors for the GLJPanel or GLCanvas objects, which is really really really really ... really annoying. If, when I am done with this project, or when I have gotten to a release point, someone would like to work on JOGL-izing it, please feel free to do so; as long as you don't make any major changes and you give credit, I don't (currently) have a problem with it. I reserve the right, however, to change my mind on this at any time prior to the first release.

Edit: I have fixed the bug (I don't think it appears in the video) where your bullets collide with you if you are moving too fast. This also removes any possibility of blowing yourself up (until AOE is implemented). Also I have added a shockwave that emanates from a destroyed capship, and have limited the explosion time. The jerkiness (aldo_14 noticed it in the video) is a problem, and it gets worse with more primary-fire, idk why this is, '.' (crude attempt at "because" symbol) there are just as many enemy shots as player shots usually, and tons of missiles in other versions.

I'm sure there was a GLCanvas constructor, but buggered if I can remember it.....

I always had a suspicion (in my case) that the jerkiness was down to mis-threading, although I have my suspicions about the JVM itself, particularly because everything is being done in-software unless you use a library to get hardware rendering.  Albeit I don't think it was ever down to memory usage (although I'm wondering how often the gc kicked in, now I think of it).  Perhaps if you have a fair wodge of stuff being loaded, but then it'd only be expected at irregular intervals.  In any case, during my more futile experiments with JOGL I did discover a very significant difference between software and hardware modes.

Annoying, really; I did have a reasonable approximation of an R-Type esque game going, but despite some rather significant work optimising it (or trying to; NB: why not group player and enemy projectiles seperately so you can cut down on collide checks?), never got it to look 'right' with either AWT or (eek) Swing.

 

Offline Mars

  • I have no originality
  • 211
  • Attempting unreasonable levels of reasonable
Re: An Ambitious Project (may need help eventually)
Huh, your hosts convert it to flash? :wtf:

That's messed up... well don't worry about it... that's just weird.

 

Offline Speeder

  • 25
Re: An Ambitious Project (may need help eventually)
okay, umm...
I don't really know much about Java (I've used it a very little bit once, buut nothing much), but I guess I'm starting to know this and that. Right now, you're probably using the GDI's Canvas for drawing the game... Now, the GDI is very far from the hardware, so you need to get through many layers of software to really do the thing you want to do. Which is all computed by the CPU. Furthermore, your images are stored in system memory, instead of video memory, so your CPU will have much idle time while the images are send from the system memory out. Hence why you should change to DirectX or OpenGL, othervise your game will slow in like HELL when you draw many pictures, and especially when you do blending effects (let's even not talk about additive drawing or things like that).
I'd also recommend changing to C++ or maybe Delphi, cuz Java is kindof a script language, so it could run much faster on those :)

About the what to do next part, I'll just write down how I've developed FS2D. I've first done the menu, toplist system and the score file encripting algo. Then the base of the scripting engine. (like preformating, and the layers of the handling and storing objects of events and cycles) Then the loading system that will examine the level and load the needed things from the definition files. Then the ship displaying, then the hit detection and health and shield handling and shield effects, then went to explosions and ship deleting. After that I've done general object handling and display, then made the diff classes for the diff types of objects and added their unique things. After that I've went to the bosses, but as your game's diff, I guess you handle those about the same as any enemy :) After that I went to the special effects like lens flares and whatevers... and last was the scoring system, although it should've came before, but hehh, I was lazy :)
Hope this gave some help...

As for images and videos, I think you should use imageshack for images. It's veeery nice. For videos, some simple file uploader would be best, like rapidshare.de or yousendit.com (fake e-mail, shows the link).

Question about the game: How do you handle hit detection? (Hitboxes, the whole picture or pixel by pixel?)

oh, yea, and lastly if you'd like to make a glowpoint, drawing a simple sprite additively could nicely do (When you add the colour values of the picture to be drawn on the parent. It looks... glowy! :D)