Well, I'm making a Breakout style game, but when you miss the ball, it only takes away a life. And I want it to sense once theres 0 lives left. Anyway I can do this? I normally work with flash, but I'm testing out scratch for my school. So I'm used to those advanced features.
Offline
Just after the "take away a life" script you need another "If" block
If lives<1
- (end game script of your choice)
Offline
Ah flash is great. If you know actionscript this should be a breeze.
(in scratch block code)
when flag clicked
Forever
if lives = 0
broadcast showgameover {make gameoverscreen come}
stop all
Get the trial of flash CS3 here https://www.adobe.com/cfusion/tdrc/index.cfm?product=flash
and for fun the same code in flash actionscript (you can kinda see the similarities)
///on root frame
var
lives=3;
/// in ball movieclip
onClipEvent (enterFrame)
{if (_root.lives == 0) {
///go to gameover frame
_root.gotoAndStop(2);
this.removeMovieClip();}
}
///coding in flash is a lot slower and harder than scratch
Last edited by archmage (2007-07-28 18:56:01)
Offline
It was quite interesting to see a small sample of Scratch and of Actionscript code together - maybe others can also supply this in the future. Another tool to experiment with Flash is 3D Flash Animator, available at http://www.3dfa.com/ . The free version has most of the save options disabled but otherwise seems to work well (not that my programming will stress any software) and the registered version is only about $50.
Offline
If you are looking for a decent free flash maker try liveswift
http://www.liveswif.net/
Offline
Actually, I think this can be done. I just played with Flash Animator. Much much faster. Better graphics and I think an automated translation of scratch to Action Script is possible.
There is another added advantage because the flash player in the Scratch IDE will be the same as the flash player on the web-site. So no more differences in speed and behaviour.
Dump Java guys. Go for flash instead.
I think I buy myself a copy of http://www.3dfa.com/ to learn more.
Offline
Dinther, if you want to get a good feel for flash I recommend that you download and try flash CS3 and the trial is good for 30 days. Macromedia flash is the program most commonly used for flash creation and in my opinion it's probably the best.
https://www.adobe.com/cfusion/tdrc/index.cfm?product=flash
Plus if you want to learn action script the 3D flash animator is not a good choice as it uses a game maker style approach to programming.
Offline