Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » How do I make a high speed scrolling background?
- kwokc6
-
4 posts
How do I make a high speed scrolling background?
Hi!
I'm making a train based game where players can operate trains at high speeds. However, the scrolling would always break or create gaps when it moves too quickly. Does anybody know how to make a scrolling background that is capable of reaching high speeds?
Thanks!
I'm making a train based game where players can operate trains at high speeds. However, the scrolling would always break or create gaps when it moves too quickly. Does anybody know how to make a scrolling background that is capable of reaching high speeds?
Thanks!
- MasterofTheBrick
-
1000+ posts
How do I make a high speed scrolling background?
Please link your project, thanks.
- Toasty_Boy
-
100+ posts
How do I make a high speed scrolling background?
There is a certain fps that Scratch uses (pretty sure it's like 30) but it prevents things from going super fast in a certain amount of time. The way they got around that is by implementing something called turbo mode. When you Shift+click the green flag, it activates it and all of a sudden, your game goes haywire. Make some adjustments and you have yourself a fast game!
- MasterofTheBrick
-
1000+ posts
How do I make a high speed scrolling background?
There is a certain fps that Scratch uses (pretty sure it's like 30) but it prevents things from going super fast in a certain amount of time. The way they got around that is by implementing something called turbo mode. When you Shift+click the green flag, it activates it and all of a sudden, your game goes haywire. Make some adjustments and you have yourself a fast game!
Even if the whole game was fast that wouldn't solve the scrolling problem. If anything, the gaps would become wider OR there could be a huge amnt of potential lag.
- Toasty_Boy
-
100+ posts
How do I make a high speed scrolling background?
When you increase the speed of the game, the time for the user to see the gaps decreases. Also, turbo mode doesn't really create potential lag…There is a certain fps that Scratch uses (pretty sure it's like 30) but it prevents things from going super fast in a certain amount of time. The way they got around that is by implementing something called turbo mode. When you Shift+click the green flag, it activates it and all of a sudden, your game goes haywire. Make some adjustments and you have yourself a fast game!
Even if the whole game was fast that wouldn't solve the scrolling problem. If anything, the gaps would become wider OR there could be a huge amnt of potential lag.
I may be misunderstanding what the problem is for the first suggestion. @kwokc6, consider what @MasterofTheBrick said in the first comment.
- MasterofTheBrick
-
1000+ posts
How do I make a high speed scrolling background?
When you increase the speed of the game, the time for the user to see the gaps decreases. Also, turbo mode doesn't really create potential lag…
Potential lag. There may be lag, it isn't a definite yes. If there are loops or touching colour ()? blocks in the code then the project will most probably lag. And yes, the time to see the gaps decreases, but it also prevents the user from seeing the backdrop clearly because of the speed. Enabling turbo mode will also affect the display, for example the game menu could have floating buttons. When TM is enabled, the whole menu would be jerky, ruining any design effects that were created.
- SomeRandomeDude_1423
-
13 posts
How do I make a high speed scrolling background?
Maybe you can just design the background fuzzy, so it looks like you're scrolling fast even though you're not, like Star Wars. It might not work though.
- MasterofTheBrick
-
1000+ posts
How do I make a high speed scrolling background?
Maybe you can just design the background fuzzy, so it looks like you're scrolling fast even though you're not, like Star Wars. It might not work though.
Don't think it will. Even if it was blurred, users can tell that it is moving slower than expected.
Last edited by MasterofTheBrick (June 22, 2021 08:00:01)
- awesome-llama
-
1000+ posts
How do I make a high speed scrolling background?
I can't see your project because you haven't provided a link.
Everything I say below is only from a guess. I can't say that this is actually a solution unless you give more details.
—
My guess is that the issue is actually due to how the background is being updated. Be very sure that your background updates are in the correct order. If you want to update the location of the background, do it all at once. I think you probably were using a bunch of forever loops. You don't have an easy way to tell those scripts to run in a specific order. Parts of the background might move at the wrong time.
A better method would look like this:
Everything I say below is only from a guess. I can't say that this is actually a solution unless you give more details.
—
My guess is that the issue is actually due to how the background is being updated. Be very sure that your background updates are in the correct order. If you want to update the location of the background, do it all at once. I think you probably were using a bunch of forever loops. You don't have an easy way to tell those scripts to run in a specific order. Parts of the background might move at the wrong time.
A better method would look like this:
- Discussion Forums
- » Help with Scripts
-
» How do I make a high speed scrolling background?