News:

Building a 3D Ray Tracer  By stevmjon

Main Menu

First attempt in progress

Started by Tracy, March 18, 2006, 03:41:35 PM

Previous topic - Next topic

kevin

Agreed, this is shaping up to be one of the best games written in PB.   Great visuals and more importantly it just feels good.  I'm very impressed !

Code wise, there's still few tidbits here and there that could be fine tuned.  Anyway, here's some screen shots for those lazy people

Draco9898

you might want to compress your Gfx
DualCore Intel Core 2 processor @ 2.3 ghz, Geforce 8600 GT (latest forceware drivers), 2 gigs of ram, WIN XP home edition sp2, FireFox 2.

"You'll no doubt be horrified to discover that PlayBasic is a Programming Language." -Kevin

thaaks

Yes and you might want to write some tutorial how to create those graphics  :D

That looks really great and I am absolutely impressed! Nice weapon effects!

The only thing I need is jumping on Alt-Key - I am so used to fire with Ctrl and jump with Alt. Was that Commander Keen or one of the other Apogee games?

Anyway, this is awesome for a game called "TheGame2" and a zip file named "Prototype"!

Thanks for sharing and please tell me how you did those weapon graphics (the poison thing or darkeye or the fireball or....)

To Kevin: That would be a graphics package I'd buy  :D

Cheers,
Tommy

Tracy

#18
Draco: I'd love to compress my graphics. It's a pain in the butt to have them in such huge files. I didn't do so before because... well, 1) I had no idea that it could be done and therefore 2) No idea how to do it. Let me know the best way to go about it and I'm happy to implement it.

Kevin: I take suggestions with coding. In fact, I pine for them. Some of the coding is due to general quick-fix sloppiness and disorganization, and I'll be cleaning the format of it up as I go. If you see anything, though, by way of execution or efficiency that's not up to standard please point it out. I have no ego- I just want to be better at this.

Tommy: The weapon effects were generated using the trial version of a program called ExGen. ("http://exgen.thegamecreators.com/?f=trial" is the address of the free trial.)

The 'Lite' version of the program allows you to export your work in a limited fashion. (By limited, I mean that the individual frames can't be any larger than 64x64 pixels.)

The Lite version is a little tricky to use, because they've disabled some of the features to make it annoying. Specifically, you can only save/load the first particle system in an effect, which is pretty limiting. Also, the time the effect lasts gets truncated, which really bugged me until I learned to adapt. Whatever you decide to do with it, you have to do quick. One other limitation is that my particular system gives me a memory error when I try to run ExGen and compile/run my PB code at the same time. (Kevin, I'm pretty sure it's on ExGen's end since it's the program that does the crashing.)

Still, poor people like me are used to that so I just dealt with it. The biggest tip is that in order to generate effects with more than one particle system at a time, you should do things in this order:

1) Create the attractor/deflector for the system (not always useful, but sometimes very much so.
2) Create a particle effect.
3) (sneaky trick) The lite version won't let you add new components after that, BUT you CAN duplicate components you've already got and then modify those to do pretty much whatever you want. (i.e. you can duplicate attractors/particle generators and then modify the duplicates.)

For example: the fireball has one particle system generating the 'core,' and another generating the trail. There's an attractor off to the left of the screen that's pulling the fireball's trail into a cone. The poisonbolt is done in much the same way, but with only one particle system. If you get creative with the program, you can do a great deal with it.

The Seeker/wisp animation had... oh, roughly five or six particle effects going on at once, and is my personal favorite. It's all about getting creative.

If you're serious about messing with it and want the poisonbolt file, let me know and I'll post it for you. I'll post some of the other simple effects as well, but most of the ones you saw in the game had more than one system and thus I didn't bother to save them. (Poor decision on my part in hindsight, because they can still be accessed with the trial full-version (as opposed to Lite) and examined, though not exported.)

Another reason I didn't bother to save them is that they took me probably less than ten minutes each after I decided what I wanted. Seriously, ExGen's a breeze to use after you're familiar with it.

As for other things, my weapons engine does things to the bullets like rotate, random rotation (the Dark's eyes are a great example of that), make them shrink/grow (fire breath), accelerate, bounce off of walls, etc.

The thing that makes the effects really shine (no pun intended) is the alpha-addition draw mode of the sprites. Kevin's covered that extensively in other places, so I'll leave it alone.

I used GraphicsGale (again, the free version) to modify them after they were created. I highly reccomend using alpha addition for any sort of spell/energy weapon you code, but if that's not possible GraphicsGale has a great color selection function, where you can select pixels of near-black and replace them with total black to crisp the edges a bit.

On yet another note, and as stated above, you're more than welcome to use anything in there that I made for yourself if you want to. Have fun.  :D

thaaks

QuoteDraco: I'd love to compress my graphics. It's a pain in the butt to have them in such huge files. I didn't do so before because... well, 1) I had no idea that it could be done and therefore 2) No idea how to do it. Let me know the best way to go about it and I'm happy to implement it.
Simplest way would be to use something like Irfanview and change the format from bitmap ".bmp" to png. That would reduce the size dramatically.
QuoteTommy: The weapon effects were generated using the trial version of a program called ExGen. ("http://exgen.thegamecreators.com/?f=trial" is the address of the free trial.)
I won the full version in the retro compo. I fiddled a bit with it but had problems with getting the right size of the images.
But now that I know that you used that I'm going to spend some time with it - those graphics are pretty cool!
QuoteIf you're serious about messing with it and want the poisonbolt file, let me know and I'll post it for you. I'll post some of the other simple effects as well, but most of the ones you saw in the game had more than one system and thus I didn't bother to save them. (Poor decision on my part in hindsight, because they can still be accessed with the trial full-version (as opposed to Lite) and examined, though not exported.)

Another reason I didn't bother to save them is that they took me probably less than ten minutes each after I decided what I wanted. Seriously, ExGen's a breeze to use after you're familiar with it.
It would be great if you could post the scripts for the effects (if possible) or PM them.
Or how about a mini tutorial  :rolleyes:
And one thing that I learned from AstroBreak: save everything  ;)
I had to redo the menu buttons completely and also the title screen just because I simply forgot something and had only the images saved but not the configuration files of the tools I used to create them...
QuoteAs for other things, my weapons engine does things to the bullets like rotate, random rotation (the Dark's eyes are a great example of that), make them shrink/grow (fire breath), accelerate, bounce off of walls, etc.

The thing that makes the effects really shine (no pun intended) is the alpha-addition draw mode of the sprites. Kevin's covered that extensively in other places, so I'll leave it alone.
I will look at the source code in detail  :D
QuoteI used GraphicsGale (again, the free version) to modify them after they were created. I highly reccomend using alpha addition for any sort of spell/energy weapon you code, but if that's not possible GraphicsGale has a great color selection function, where you can select pixels of near-black and replace them with total black to crisp the edges a bit.
Oh thanks, that's another good tip cause that's exactly what I have with my AstroBreak explosions - there are some "nearly black" areas that just look ugly cause they are not transparent...
QuoteOn yet another note, and as stated above, you're more than welcome to use anything in there that I made for yourself if you want to. Have fun.  :D
Very generous, thank you!

I am curious how this game will evolve - it's very promising!

Cheers,
Tommy

Tracy

QuoteI will look at the source code in detail  :D


Some of it's not greatly transparent. I'll try ot point you in the right directions (then again, you may already be able to see what I'm doing):


Load_Anim(wisp(),"wisp_Ice.bmp",17,64,64,RGB(0,0,0),5,3)



The Load_Anim function is critical to the animations. The inputs are(arrayforimages(),"imagename",frames,sizeX,sizeY,backgroundcolor,delay,cycleframe)

Where delay is the amount of time between frames, and cycleframe is the frame it loops back to. Cycling back to a frame other than the first allows the fireball to 'spawn' only once, and then continue to fly (without respawning) all based off of one animation.

The individual weapon data is found at the bottom of the "main" page of code. It's pretty cryptic. To be able to read it, use the 'DefineBulletTypes()' Psub as a key to see what data is what. In conjunction with the "Fire_Bullet" and the "Update_Bullets()" functions, you should be able to pick it apart no problem.

And here are a few ExGen samples of some game stuff I've recreated. Hope they're helpful. (Note, though, that they were made with the Lite version and behave slightly differently on the full. Mostly they just last longer, which can be a pain, so sorry for that.  :( )

thaaks

Tracy, thanks for the scripts. They are indeed very helpful. I already had a look at Dark Eye, the poison bolt and your fire bolt. Now I know what to use attractors for - looks really cool in ExGen!
This certainly convinced me to spend more time with this tool. Also thanks for the code wrap up. I think I'll find everything now!

Now let's find some time to create a game with all this new knowledge  :rolleyes:

Cheers,
Tommy

Tracy

I'd just like to announce that this project has officially died in the name of my medical education.

School's picked up to the point where I don't see myself ever having the time to return to this, at least not for the next half decade or so. (Literally. Three years of med school + residency=6 years.)

Anyone who wants to ruthlessly pirate the code, sounds, or graphics is encouraged to do so. I'd hate for it to go completely to waste, though even if it did I enjoyed programming it and learned a lot.

Good luck everyone!

-Tracy


kevin


    For a purely selfish reasons that's that's sad to hear,  as  where am I going to get free medial advice now ? :)

     This was a certainly a project of great promise and it'd be a real shame for all that hard work to be wasted.    I'd be happy make a Demo package of it for the PB home page, if you'd like.   At least then a lot more users will see it, and hopefully somebody will carry on with it.   

    Are the files in the this thread the latest editions ?

    BTW,  in case i've not said so before,  I wish you all the best with your studies. 

Tracy

Actually, now that you mention it, I believe I did update this a bit after I posted these files. I'll dig the newest ones up when I get home this afternoon and post the changes. (I believe the updated version is still functional, and not in a transitionary phase- you know how it goes.) The only part that makes me sad about it is that it was SO CLOSE to being so much more. (Respawning aliens, for example, were just implemented. Good times.) Like I said, I'll post what I've got when I get home tonight.

If you'd like to pilliage it for a demo, that'd make me extremely happy -- I'd love to contribute to the PB community in some small way, as I had so much fun being a part of it.

And thanks for the well-wishing. I'll try to stop by every so often and check up on things, as I still believe Playbasic to be a fantastic product. I wish you (and the playbasic community at large) all the best in carrying on with this.

Ian Price

Good luck man - that's an awfully long time when you're looking at it from this side, but it'll go by really quickly and a real worthy cause.

Please pop back every so often and let us know how you're doing. :)
I came. I saw. I played some Nintendo.

Tracy

Ack! It seems as though the updated versions were lost when I wiped my laptop (it died over the summer) which means that this is what there is.

Give me a little bit yet, though. I'd like to at least redo what I did before (as in, after posting it, but before I wiped), and get it cleaner before I turn it over for a demo.

I underestimated the draw it'd have on me when I reinstalled PB. :) It's still fair game for anyone that wants to use it, but I think I'll update it a bit before I abandon it completely myself.

kevin


Look out the beast has awakened..  :)


kevin

#28
   Refresh

     I'm in the process of putting together a 'bundled' version of this. (which i mentioned above ages ago)   The provided versions above works happily in 1.63, there's a few missing files from the package, but once you weed those out, it's business as normal.    Not bad for the code that was written some 3 years ago.  

     The interesting thing about this demo is that contains a bunch of effects and bunch of really rather interesting weapons for the player.  You've no doubt seen the backdrop art before (the demo was originally built off plat former demo that comes with PlayBasic) , and most of the sprites are ripped unfortunately.  It's kind of bizarre as the player has different characters for different animations.   Walking is guy is overcoat, flying is dragon..  

     Here's  a few shots to refreshing you're memory..   I'll post the project later today/tonight




Download

  Tracy Blaster Proto Type (Source code + media) (login required)


Download

Tracy Blaster Proto Type (Source code + media) (login required)

kevin

Some more pictures - it's rather hard to control the player & grab a screen shot. Since everything moves so fast..