积木——“重复执行直到”
-
先修科目
介绍
积木“重复执行直到”是控制类别的匚形积木,并带有布尔型输入。
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/c9b7e419-ae43-4cdf-b45d-e7ce47043ac7.png" width="550" style="">
这个积木怎么用?
这个积木会一直重复运行它里面的积木,直到条件变为“真”。换而言之,这个积木首先检查条件,如果条件为“假”,它就会运行一次它嘴里的全部积木,接着再检查条件。如果条件仍然为“假”,那么就再次运行它里面的积木……
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/143026d5-ec1b-44d2-b54a-393d09387fe4.gif" width="900" style="border-radius: 5px; border: 1px solid #29622d;">
如果条件已经为“真”
如果积木“重复执行直到”的条件已经为“真”,里面的积木就不运行。
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/3f433255-e7d3-4f41-8649-056099a3b1d6.gif" width="900" style="border-radius: 5px; border: 1px solid #29622d;">
用积木“重复执行直到”制作动画
如下是如何用积木“重复执行直到”制作动画。刚开始蝴蝶还没碰到草莓,积木“重复执行直到”的条件就为“假”。因此,里面的积木重复不断地让蝴蝶下移。当蝴蝶碰到草莓后,条件变为“真”。此时,积木“重复执行直到”下面的积木就会运行。
https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/155239aa-a71f-4972-89ea-9ed08cff28b1.gif" width="900" style="border-radius: 5px; border: 1px solid #29622d;">
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login