Thanks. I hadn't ever used tweening before this. If I ever needed something to move, I'd just use linear interpolation. Just a bit of tweening, selecting an appropriate tween, and it's much better. I'm even using tweens to control the frames of animation, as well as movement.
A lot of people say they want to be able to fire the launchers individually, so I'll probably add that. Thanks for playing.
My first Gosu game is finally ready for playing, but not quite finished.
You can download it from my Github (version 0.2 is broken there, just download the zip).http://github.com/mmorin/armageddon
To play it, you'll need the Tween gem. Just gem install tween. If you're on Windows and want an exe, I've posted a build here.http://drop.io/zav919f
That just about sums it up. The next version will have balanced gameplay (more challenging, less boring), as well as a high scores screen (maybe using ippa's online service).
Edit: Oh, and here's a video
I knew about Chingu, and was "inspired" by it. In other words, I looked at the example code and the bits that I needed, I duplicated. It was a toss up between fully investigating Chingu and writing my own, but the parts I needed were so simple, it was just easier to do it myself. I'm still looking at it for the future though. As for the code duplication, these two parts are so simple, it's hardly an issue in this case.
I don't think GitHub has SVN support. At least no more than importing SVN repositories, and then using Git from then on. GitHub is great, but use what works for you.
I realize it's not practical for most uses, but I wrote this code specifically for my tutorials. It's much handier to have a single example file people can download or even copy and paste, rather than a zip file. It's just easier to keep things self-contained.
As for the tutorials, there's more to come. If anyone has any feedback, or suggestions for further articles, I'm open to anything. Or even guest articles, if you feel like writing anything yourself.
Hmm.. I had a LICENSE file, but it seems it didn't make it into the gem. Penner's equations are licensed under BSD, and so is tween.
It's not always convenient to distribute data files with your programs, so I've come up with a little hack to embed them in the program itself. It's not great, but it works.http://ruby.about.com/od/gosugme/ss/Embedding-Images-In-Gosu-Programs.htm
This code is just a hack to work for PNG files, but it could work for any file. When you want to use the file, all it does is decode from base64 and write to a temp file. I wrote this specifically so people could people could post complete programs in text form on pastebins and forums (like this one!). Oh, and there's a Rakefile there that will encode your files and automatically insert them into your script.
Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill