From Test-Scratch-Wiki

Revision as of 09:14, 1 August 2020 by Yar 2010g (talk | contribs) (WIP)

Хоча Скретч придумано для людей, не обізнаних у програмуванні, добре навчитися писати на ньому складно. Цей матеріал призначено для осіб, які тільки-но почали програмувати на Скретчі.

Проєкти

Проекти є анімаціями, історіями, мистецтвом, малюванням та іграми —— усім, що можна створити на Скретчі. Аби створювати проєкти, потрібен редактор Скретч. Створеними проєктами можна поділитися зі світом за допомогою Спільноти Скретч. Крім написаного кода, проєкт містить малюнки та звуки.

Інтерфейс

Головна стаття: Інтерфейс

Інтерфейс Скретчу поділений на дві частини: середовище, яке виконує проєкт і середовище, у якому проєкт розроблюється. У правій верхній частині вікна редактора є Сцена. На неї користувач може бачити результати виконання проєкту. Після створення проєкту на сцені є тільки один спрайт: Кіт Скретч. У скретчі є безліч спрайтів, Кіт Скретч —— тільки один із них. Спрайти можна програмувати, додавати їм костюми та звуки, експортувати, імпортувати, дублювати та видаляти. Гнучкість Скретча дозволяє фантазувати й створювати власні проєкти. На цьому етапі стає важливим програмування.

Програмування

Замість ніж заглиблюватися далі в інтерфейс, може, слід спробувати найкоротший шлях зрозуміти програмування спрайтів. Це шлях експерименту: швидке з'ясування того, як працюють блоки. Інструкцію щодо такого подано нижче:

1. Зверніть увагу на цю область редактора Скретч:

3.0 Block Selection Pane.png

2. Оберіть синій "блок" з назвою перемістити на (10) кроків, й витягніть його на порожню панель справа.

Grab Block.png

3. Release the mouse to place the block; make sure the block is placed in the darker grey, technically called the scripts area.

Place Block.png

4. When done, click anywhere on the block except the white middle, and watch what happens to the Scratch Cat... it moves 10 steps.

Scratch Cat Move.png

5. Check out the other block categories and test out what each one does!

Category Select.png

Blocks

As shown above, blocks are the building "blocks" of a Scratch project. They have specific commands which function uniquely from one another. Some blocks can even fit inside other blocks, as shown below:
1. Assemble the following "script", or connection of blocks, by accessing the various blocks by color and category.

Scattered Blocks.png

2. Assemble the blocks into this formation:

Assemble Blocks.png

3. Grab the blue key sensing block that is still in the void and place it into the hexagonal input area of the orange "if" block:

Block Input.png

4. Click the Green Flag to run the project, and see what it does!

Click Flag.png

5. Unless you were holding down the space key, nothing should have happened. Why is that? Take a look at the script again; remember, a script is a fully connected chain/stack of blocks.

when gf clicked
if <key [space v] pressed?> then
move (10) steps
end

The script begins with "when green flag clicked", which was done. When the green flag is clicked, it triggers the script beginning with the "when green flag clicked" block to run. When the script ran, it first detects if the space key is down, and if it is, then the sprite will move 10 steps. Run the project again while holding the space key down, and the sprite will move 10 steps.

Paint/Sound Editors

Main article: Paint Editor
Main article: Sound Editor

Scratch even includes its very own paint editor and sound editor. A paint editor is a program used for designing and editing images. The Scratch paint editor can be used to draw the images for sprites (the characters, buttons, etc.). The sound editor is used for importing, recording, and modifying sounds used in a project. To access these two editors, click on the tabs above the blocks palette:

Tabs.png

Sprites

Sprites are like the characters of a project. Each sprite has its own blocks, and they can communicate with each other using Broadcasts. Each sprite can do its own job. For example, in a game where a dinosaur chases the Scratch Cat, the dinosaur is programmed to chase the cat, while the cat is controlled by the player. These two sprites do different things. A project can have hundreds of sprites, each doing its own job.

Sprites Pane

The sprites pane of a user's project. The currently selected sprite is highlighted blue.

Accessing different sprites can be done in the sprites pane, located below the stage. The currently selected sprite always has a blue box around it; by simply clicking on a different sprite, its data can be accessed. The sprites pane is shown in the image to the right.

Creating New Sprites

Most projects on Scratch have more than one sprite. At the bottom-right of the sprites pane is a button for creating a new sprite. Hovering over it opens up four options:

3.0 New Sprite Buttons.png

With these buttons, a new sprite can be imported as either a plain image or one that already has scripts. The buttons, going from bottom to top, do the following:

  • Selecting a sprite from the sprite library,
  • Opening the Paint Editor to draw a sprite,
  • Getting a surprise sprite,
  • and uploading an image from the computer using Scratch.

Backdrops

The background of a project can also do a job as well. Backdrops cannot move, but they can play music, send broadcasts, and much more. Like sprites, they also have a picture that can be edited using the Paint Editor. Below the backdrop, there is a button to create a new backdrop.

Project Sharing

To learn more about sharing projects, click here!

Online Editor

Note Note: You must confirm your email address in order to share.

One can share a project from either the unshared project's page or directly in the editor.

From an unshared project page, a user can click the "share" button in an orange bar above the project, as shown: Orange share bar on project page.png

In the project editor, in the top-middle next to the project name, there is a "Share" button which appears for an unshared project. Clicking this will share the project, opening the project page as well. Green shared bar.PNG

Offline Editor

In the offline editor, to share a project, open an empty project online and select File > Load from your computer. Your project should appear in the editor. Then, share it using the steps above.

Remixing

Main article: Remix

The Scratch Website is filled with many projects. Scratchers that find projects they consider well-made or interesting may remix them, using the following steps:

  1. Click the "See Inside" button in the corner of the project.
  2. Change the project to personalize it.
  3. Click the orange remix button in the top-middle
  4. The edited project is now owned by the new user.


Note Caution: Make noticeable changes to your project. If there are no changes, you are stealing/plagiarizing the original user's project and your project can be reported by another Scratcher.

What Now?

One possible way to advance a beginner's knowledge with Scratch is by playing around with it. Trying out different blocks, testing tools in the paint editor, and seeing all the nifty sound editor features can help one learn more about the program. Resources such as the Scratch Forums and other articles on Scratch Wiki can be utilized as help when necessary. Creating many quality, hard-worked projects is arguably the best way to learn about Scratch.

Tutorials

Main article: Project Tutorials

Tutorials can be checked out in Scratch. In the project editor, click the Tutorials button on the top blue bar. Choose a tutorial, and start creating using it.