Questions tagged [mit-scratch]

Scratch is a graphical drag-and-drop language developed by MIT.

Scratch is a graphical drag-and-drop language developed by the Lifelong Kindergarten Group at the MIT Media Lab. It is used in a number of grade schools and other educational institutions to teach principles of programming.

It primarily focuses on developing games or other graphics-intensive applications, but it can be used for other tasks as well.

The code interface consists of 'blocks' that are dropped into the editor window and then hooked together to perform tasks. Manipulation of 'sprite' objects is the main focus of the language.

Scratch has inspired several similar programming interfaces, which use its block-manipulation approach to programming.

Other block-programming tools include Snap (also known as Build Your Own Blocks), which extends Scratch with first-class data and better routine-creation tools, Enchanting, which allows programming the Lego NXT controller, and Google's Blockly, which provides generic tools to allow any programming language to be programmed with a block interface. Also Scratch Jr, which focuses on coding for young children (aged 5-7 years), the blocks are placed horizontally instead of vertically like Scratch, as younger children found this easier to understand.

Scratch's official wiki contains documentation and tutorials about all features of Scratch.

Scratch's official discussion forums also contains information concerning Scratch.

Books:

284 questions
0
votes
1 answer

BBC micro:bit extension adding failed for Scratch

I bought a new micro:bit v2 board, and want to add it to Scratch as an extension. I followed the 2 steps from https://scratch.mit.edu/microbit. The step 1 is ok, the led lights of my micro:bit board is flashing 5 characters "zepiv", but the step 2…
choes
  • 141
  • 1
  • 1
  • 11
0
votes
1 answer

Make one sprite follow another off centre, including rotation

I'm working on a car drift game, which I want to make skid marks with using the pen. I created a circle, radius 25 around the car that I am using as a reference for where the tires would be, and I need to get the tire sprite to follow the back end…
0
votes
2 answers

How do you make an object in Scratch have horizontal momentum when you release dragging it?

I'm trying to implement this in Physica, my Scratch-based physics engine. I tried adding it and the ball glitched out (couldn't move on the x axis at all). Does anyone know how to do this?
Pycoder
  • 1
  • 1
  • 2
0
votes
2 answers

scratch sprite mosaic effect not working consistently

I have a simple shooter game where a gliding sprite is supposed to shatter (using mosaic effect) when hit, then disappear. Problem is, the sprite only shatters and disappears maybe 1 time out of 5. Here's the relevant code snippet: For more…
andreithegiant
  • 215
  • 1
  • 10
0
votes
2 answers

Controlling different types of sprite animation in Scratch

I'm building a platformer in Scratch 3.0 where a player can run, jump, crouch, and has a few basic attacks. Right now I have animation set up under a custom block like this example for the idle: switch to costume (1+((floor of (timer*10)) mod…
0
votes
2 answers

Calculate note upscroll speed through two variables

I am trying hopelessly to recreate a DDR-style rhythm game clone in Scratch. (however, the language is irrelevant because this question is about math.) I am wondering; How do I get a perfect sync between music and notes that won't delay- and won't…
0
votes
3 answers

Prompt User to input Integers between 30 and 100, press 0 to exit from loop, When user presses 0, display message 'press spacebar'

Create a list called Numbers Prompt the user to enter Integer number between (30-100)numbers to the list Keep asking the user to enter the numbers until he enter 0 to exit from the loop Once the user press 0 “Display a message for the user to…
0
votes
2 answers

How to loop through a list and print numbers greater than 50 in Scratch?

I have written a script to prompt the user to enter values between 30 and 100. Now I want to print all the number greater than 50 in the list when the user presses the space bar. I am confused on how to go through the list and print numbers greater…
0
votes
0 answers

GET http://localhost:8601/[object%20Object] 404 (Not Found)

I'm trying to import tensorflow models in to my program in JS, and I'm getting a GET http://localhost:8601/[object%20Object] 404 (Not Found) error. My code is as follows importModel() { console.log("import model start"); //from…
Falcon72
  • 1
  • 2
0
votes
1 answer

Pygame make sprite walk in given rotation

I did a little Scratch script a long time ago, which I would like to convert to Python with Pygame. There are plenty of examples showing the rotation of the image but I would like to know how to change the sprite's rotation to make it move in a…
SiniKraft
  • 9
  • 3
0
votes
1 answer

Scratch project: To check if any word in a list is contained in an answer

I have the following Scratch project which has a "kind list" of words like: "good", "kind", "love", "come" etc. A user should be able to enter any sentence containing any of these words, and the happy face would show. Currently if the user types…
Compoot
  • 2,227
  • 6
  • 31
  • 63
0
votes
1 answer

How can I change the shape of blocks in Scratch/Blockly?

I am trying to change the shape and color of the blocks in Scratch. To do so, I am trying to modify the GitHub repo of scratch-blocks (https://github.com/LLK/scratch-blocks). There is a slight possibility that the repo I would have to change is the…
Daniel Cortild
  • 203
  • 1
  • 9
0
votes
2 answers

How to change the color of the extension device blocks in Scratch 3.0?

I'm modding Scratch 3.0. I have cloned scratch-gui, scratch-blocks, and scratch-vm and I have added my new extension device. Now I want to change the color of my extension device bocks but I didn't find any way to change the color of my extension…
0
votes
1 answer

"Switch costume" not triggering on the same conditions as other things successfully trigger

I'm taking a refresher course on C, SQL, etc and an introductory assignment has us using Scratch, which I'm unfamiliar with. In short, I'm making a "game" where a bat semi-randomly bounces around the screen, bouncing off balls which can be moved by…
Nick
  • 3
  • 1
0
votes
3 answers

is there a way to convert a scratch 3.0 file into a .swf file?

I tried scratch 2.0 but I use Sinhala language because l am Sri Lankan. So I can't use Sinhala in scratch 2.0 So I can't convert using scratch 2.0 Is there any other way we can convert an Sb3 file to a Swf file?
Kasun98
  • 23
  • 1
  • 4