My question is: One huge script or lots of little ones (linked by broadcasts)?
My games tend to use a couple huge scripts over lots of little ones, and they always lag awfully online. Should I use little ones instead?
Offline
From personal experience, I find large ones work better. Why?
1. Broadcasts are confusing. They are one of the most overused blocks in Scratch. They can be pretty messy, and hard to tell apart. I usually avoid using them, and when I do I have a plan for orginazation
2. Look at RHY#####'s projects. One of his most famous games called Line is all done in one effecient script. So is his project water physics, which is one of the most complicated physic engines on Scratch.
So if I were you, I would stick with what you're doing. But ultimately it comes down to what works best for you.
Offline
I'd say find the middle.
I do it, and I never get front page!
not comforting, is it? And I know that has nothing to do with me not getting front page.
Offline
itchyone wrote:
so does splitting up the scripts make it faster online?
It could be argued either way. It really doesn't effect the overall speed from what I've seen. It really is what is inside of the scripts.
Offline
I think the biggest issue is this, and pardon me cause I'm making a lot of assumptions here. The Scratch site does the "magic" job of converting our apps into java apps BUT not all functions convert properly. Now, like so many things around here, it would be most excellent if there we were provided something like a list of these specific 'bad' function crossovers. Then people who want their stuff to run smoothly online vs. just be downloaded and run could optimize their coding methods.
So, unless some generous benefactor drops in with our list, you are gonna have to search the forums and make one yourself. Have fun and please post it for us later ?!?! Seriously though, here is an example of what I ran into...
started working on scrolling games
immediately read and discovered that they are notoriously buggy online
also found out that resizing any sprite to over 100% does NOT work online
made the decision that for the complexity of the serious games that I want to do, downloads are the only way. But to be really picky about your question, the more problems like these you can track down, the better chance that you have of making a smooth and yet relatively complex game. You have the right question in general, you just need to apply it to who knows how many variables (1 or more scripts, number of sprites used, if green flag clicked, use/don't use broadcasts / Move vs Glide / etc etc etc) Good luck!
Offline