Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » スクロールゲームを作る方法がわかりません!!教えて下さい!
- Parametric
- Scratcher
91 posts
スクロールゲームを作る方法がわかりません!!教えて下さい!
https://scratch.mit.edu/discuss/18/:まず、あなたが日本語を話すつもりなら、日本語フォーラムをご利用ください
私は日本語が話せませんが、私はGoogle翻訳を使用していますので、私の言葉の使用率が非常に良くないかもしれません。
しかし、あなたの質問に答えるために、あなたがしなければならない最初の事はそう代わりにこれを行うのは、メインスプライトの現在のx位置の変数を作ることです。
代わりに、これを行います
メインのスプライトの実際のx位置が0に常にあるように今それを作ります。
あなたがそれを完了したら、あなたのレベルなどの異なるスプライト(最初の画面のための1つのスプライト、第二画面のための別のスプライトの各画面を作成する(そこにそれを行うには、より効率的な方法がありますが、私は維持しようとしています可能な限りシンプルに))。
さて、これらのレベルスクリーンスプライトのそれぞれについて、それらのそれぞれに次のようになりスプライトを与えます:
最初のレベル-スプライトの画面番号0を作り、その後、それぞれの連続レベルスプライトのための1によって上がることを忘れないでください。
それはそれの世話をする必要があります。これは単なる目安であり、&Iは、より詳細なチュートリアルがそこにあると確信しているが、これはそれの基礎をカバーする必要があります。お役に立てれば!
English version:
First of all, if you're going to speak Japanese, please use the Japanese forum: https://scratch.mit.edu/discuss/18/
I don't speak Japanese, but I'm using Google Translate, so my word usage may not be very good.
To answer your question though, the first thing you have to do is make a variable of the main sprite's current x position, so instead of doing this:
Instead, do this
Now make it so that the main's sprite's actual x position is always at 0.
Once you've done that, make each screen of your level a different sprite (one sprite for the first screen, another sprite for the second screen, etc. (there are more efficient ways to do it, but I'm trying to keep it as simple as possible)).
Now, for each of these level-screen sprites, give each of them a sprite that looks something like this:
Remember to make the first level-sprite's screen-number 0, and then go up by 1 for each consecutive level-sprite.
That should take care of it. This is just a rough guide, & I'm sure there are much more detailed tutorials out there, but this should cover the basics of it. Hope this helps!
私は日本語が話せませんが、私はGoogle翻訳を使用していますので、私の言葉の使用率が非常に良くないかもしれません。
しかし、あなたの質問に答えるために、あなたがしなければならない最初の事はそう代わりにこれを行うのは、メインスプライトの現在のx位置の変数を作ることです。
when green flag clicked
set x to (0)
forever
if <key [left arrow v] pressed?> then
change x by (-5)
end
if <key [right arrow v] pressed?> then
change x by (5)
end
end
代わりに、これを行います
when green flag clicked
set [scroll x v] to [0]
forever
if <key [left arrow v] pressed?> then
change [scroll x v] by (-5)
end
if <key [right arrow v] pressed?> then
change [scroll x v] by (5)
end
end
メインのスプライトの実際のx位置が0に常にあるように今それを作ります。
あなたがそれを完了したら、あなたのレベルなどの異なるスプライト(最初の画面のための1つのスプライト、第二画面のための別のスプライトの各画面を作成する(そこにそれを行うには、より効率的な方法がありますが、私は維持しようとしています可能な限りシンプルに))。
さて、これらのレベルスクリーンスプライトのそれぞれについて、それらのそれぞれに次のようになりスプライトを与えます:
when green flag clicked
forever
set x to (((0) - (scroll x)) + ((480) * (screen number)))
end
最初のレベル-スプライトの画面番号0を作り、その後、それぞれの連続レベルスプライトのための1によって上がることを忘れないでください。
それはそれの世話をする必要があります。これは単なる目安であり、&Iは、より詳細なチュートリアルがそこにあると確信しているが、これはそれの基礎をカバーする必要があります。お役に立てれば!
English version:
First of all, if you're going to speak Japanese, please use the Japanese forum: https://scratch.mit.edu/discuss/18/
I don't speak Japanese, but I'm using Google Translate, so my word usage may not be very good.
To answer your question though, the first thing you have to do is make a variable of the main sprite's current x position, so instead of doing this:
when green flag clicked
set x to (0)
forever
<key [left arrow v] pressed?>
change x by (-5)
end
<key [right arrow v] pressed?>
change x by (5)
end
end
Instead, do this
when green flag clicked
set [scroll x v] to [0]
forever
<key [left arrow v] pressed?>
change [scroll x v] by (-5)
end
<key [right arrow v] pressed?>
change [scroll x v] by (-5)
end
end
Now make it so that the main's sprite's actual x position is always at 0.
Once you've done that, make each screen of your level a different sprite (one sprite for the first screen, another sprite for the second screen, etc. (there are more efficient ways to do it, but I'm trying to keep it as simple as possible)).
Now, for each of these level-screen sprites, give each of them a sprite that looks something like this:
when green flag clicked
forever
set x to (((0) - (scroll x)) + ((480) * (screen number)))
end
Remember to make the first level-sprite's screen-number 0, and then go up by 1 for each consecutive level-sprite.
That should take care of it. This is just a rough guide, & I'm sure there are much more detailed tutorials out there, but this should cover the basics of it. Hope this helps!
Last edited by Parametric (Oct. 30, 2016 11:21:21)
- ILYW
- Scratcher
500+ posts
スクロールゲームを作る方法がわかりません!!教えて下さい!
https://scratch.mit.edu/discuss/18/:まず、あなたが日本語を話すつもりなら、日本語フォーラムをご利用くださいThanks!It helped me so much thankyou!!
私は日本語が話せませんが、私はGoogle翻訳を使用していますので、私の言葉の使用率が非常に良くないかもしれません。
しかし、あなたの質問に答えるために、あなたがしなければならない最初の事はそう代わりにこれを行うのは、メインスプライトの現在のx位置の変数を作ることです。when green flag clicked
set x to (0)
forever
if <left arrow> then
change x by (-5)
end
if <right arrow> then
change x by (5)
end
end
代わりに、これを行いますwhen green flag clicked
set [scroll x v] to [0]
forever
if <left arrow> then
change [scroll x v] by (-5)
end
if <right arrow> then
change [scroll x v] by (5)
end
end
メインのスプライトの実際のx位置が0に常にあるように今それを作ります。
あなたがそれを完了したら、あなたのレベルなどの異なるスプライト(最初の画面のための1つのスプライト、第二画面のための別のスプライトの各画面を作成する(そこにそれを行うには、より効率的な方法がありますが、私は維持しようとしています可能な限りシンプルに))。
さて、これらのレベルスクリーンスプライトのそれぞれについて、それらのそれぞれに次のようになりスプライトを与えます:when green flag clicked
forever
set x to ((((0) - (scroll x))) + ((480) * (screen number)))
end
最初のレベル-スプライトの画面番号0を作り、その後、それぞれの連続レベルスプライトのための1によって上がることを忘れないでください。
それはそれの世話をする必要があります。これは単なる目安であり、&Iは、より詳細なチュートリアルがそこにあると確信しているが、これはそれの基礎をカバーする必要があります。お役に立てれば!
English version:
First of all, if you're going to speak Japanese, please use the Japanese forum: https://scratch.mit.edu/discuss/18/
I don't speak Japanese, but I'm using Google Translate, so my word usage may not be very good.
To answer your question though, the first thing you have to do is make a variable of the main sprite's current x position, so instead of doing this:when green flag clicked
set x to (0)
forever
if <left arrow> then
change x by (-5)
end
if <right arrow> then
change x by (5)
end
end
Instead, do thiswhen green flag clicked
set [scroll x v] to [0]
forever
if <left arrow> then
change [scroll x v] by (-5)
end
if <right arrow> then
change [scroll x v] by (-5)
end
end
Now make it so that the main's sprite's actual x position is always at 0.
Once you've done that, make each screen of your level a different sprite (one sprite for the first screen, another sprite for the second screen, etc. (there are more efficient ways to do it, but I'm trying to keep it as simple as possible)).
Now, for each of these level-screen sprites, give each of them a sprite that looks something like this:when green flag clicked
forever
set x to ((((0) - (scroll x))) + ((480) * (screen number)))
end
Remember to make the first level-sprite's screen-number 0, and then go up by 1 for each consecutive level-sprite.
That should take care of it. This is just a rough guide, & I'm sure there are much more detailed tutorials out there, but this should cover the basics of it. Hope this helps!
アカウント引っ越し中止
- Discussion Forums
- » Help with Scripts
- » スクロールゲームを作る方法がわかりません!!教えて下さい!