Skip to content

Commit

Permalink
Merge pull request #35 from raspberrypilearning/draft
Browse files Browse the repository at this point in the history
Draft
  • Loading branch information
pjbRPF authored Jan 7, 2025
2 parents 550f05b + d6957a0 commit 8a9c73f
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 105 deletions.
Binary file removed en/images/archery-glide-test.png
Binary file not shown.
11 changes: 6 additions & 5 deletions en/meta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@ copyedit: false
title: Archery
description: Shoot arrows as close to the bullseye as you can.
version: 4
last_tested: 2019-04-18
last_tested: 2025-01-02
steps:
- title: Introduction
- title: What you will make
- title: Aiming arrows
- title: Shooting arrows
completion:
- engaged
- title: Shooting arrows
completion:
- internal
- title: 'Challenge: Different scores'
- title: Challenge
challenge: true
- title: What next?
- title: What can you do now?
66 changes: 5 additions & 61 deletions en/step_1.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
--- no-print ---

This is the **Scratch 3** version of the project. There is also a [Scratch 2 version of the project](https://projects.raspberrypi.org/en/projects/archery-scratch2).

--- /no-print ---
## What you will make

## Introduction
Create an archery game, in which you have to shoot arrows as close to the bullseye as you can.

You are going to learn how to create an archery game, in which you have to shoot arrows as close to the bullseye as you can.
--- print-only ---
![A target with three coloured rings. A crosshair is towards the middle of the target and is reporting 200 points. ](images/archery-final.png)
--- /print-only ---

### What you will make

--- no-print ---

Expand All @@ -20,56 +17,3 @@ Click on the green flag to start. Use the space bar to shoot an arrow
</div>

--- /no-print ---

--- print-only ---

![complete project](images/archery-final.png)

--- /print-only ---

--- collapse ---
---
title: What you will need
---

### Hardware

+ A computer capable of running Scratch

### Software

+ Scratch 3 (either [online](https://rpf.io/scratchon){:target="_blank"} or [offline](https://rpf.io/scratchoff){:target="_blank"})

### Downloads

The starter project can be found [here](https://rpf.io/p/en/archery-go){:target="_blank"}.

--- /collapse ---

--- collapse ---
---
title: What you will learn
---

+ Use animations
+ Use broadcasts
+ Use random numbers

--- /collapse ---

--- collapse ---
---
title: Additional information for educators
---

--- no-print ---

If you need to print this project, please use the [printer-friendly version](https://projects.raspberrypi.org/en/projects/archery/print){:target="_blank"}.

--- /no-print ---

You can find the [completed project here](https://rpf.io/p/en/archery-get){:target="_blank"}.

--- /collapse ---


25 changes: 5 additions & 20 deletions en/step_2.md
Original file line number Diff line number Diff line change
@@ -1,30 +1,21 @@
## Aiming arrows

Let's start by creating an arrow that moves around the screen.
Start by creating an arrow that moves around the screen.

--- task ---

Open the Scratch starter project.
Open the Scratch starter project [rpf.io/archeryon](https://rpf.io/archeryon){:target="_blank"}.

**Online**: open the starter project at [rpf.io/archeryon](https://rpf.io/archeryon){:target="_blank"}.

If you have a Scratch account you can make a copy by clicking **Remix**.

**Offline**: open the [starter project](https://rpf.io/p/en/archery-go){:target="_blank"} in the offline editor.

If you need to download and install the Scratch offline editor, you can find it at [rpf.io/scratchoff](https://rpf.io/scratchoff){:target="_blank"}.
--- /task ---

In the starter project, you should see a target backdrop and a cross hair sprite.

![starter projects](images/archery-starter.png)

--- /task ---

--- task ---

When your game starts, broadcast a message to shoot a new arrow.

![target sprite](images/target-sprite.png)
When your game starts, broadcast a message to create a new arrow.

```blocks3
when green flag clicked
Expand All @@ -37,8 +28,6 @@ broadcast (new arrow v)

Once this message has been received, set the arrow's position and size.

![target sprite](images/target-sprite.png)

```blocks3
when I receive [new arrow v]
go to x: (-150) y: (-150)
Expand All @@ -49,7 +38,7 @@ set size to (400) %

--- task ---

Click the green flag to test your game. You should see your arrow get bigger and move to the bottom-left of the stage.
Click the green flag to test your game. You should see your arrow move to the bottom-left of the stage and get bigger.

![larger target sprite in bottom left of stage](images/archery-start-test.png)

Expand All @@ -59,8 +48,6 @@ Click the green flag to test your game. You should see your arrow get bigger and

Add code to your arrow so that it `glides`{:class="block3motion"} randomly around the stage `forever`{:class="block3control"}.

![target sprite](images/target-sprite.png)

```blocks3
when I receive [new arrow v]
go to x: (-150) y: (-150)
Expand All @@ -76,6 +63,4 @@ end

Test your game again, and you should see your arrow move randomly around the stage.

![target in a different position](images/archery-glide-test.png)

--- /task ---
13 changes: 3 additions & 10 deletions en/step_3.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
## Shooting arrows

Let's code your arrow to shoot when the space bar is pressed.
Code your arrow to shoot when the space bar is pressed.

--- task ---

Stop the other script (the one moving the arrow) when the space bar is pressed.

![target sprite](images/target-sprite.png)

```blocks3
when [space v] key pressed
stop [other scripts in sprite v]
Expand All @@ -25,8 +23,6 @@ Test your project again. This time, your arrow should stop moving __when the spa

Animate your arrow, so that it looks like it's moving towards the target.

![target sprite](images/target-sprite.png)

```blocks3
when [space v] key pressed
stop [other scripts in sprite v]
Expand All @@ -39,17 +35,16 @@ end

--- task ---

Test your game again. This time, when you press the space bar you should see your arrow get smaller, as if it's moving towards the target.
Test your game again.

![target with the cross hair on it](images/archery-animate-test.png)
This time, when you press the space bar you should see your arrow get smaller, as if it's moving towards the target.

--- /task ---

--- task ---

Once your arrow is at the target, you can tell the player how many points they have scored. For example, they could score 200 points for hitting the yellow.

![target sprite](images/target-sprite.png)

```blocks3
when [space v] key pressed
Expand All @@ -68,7 +63,6 @@ end

You can also play a sound if they hit the yellow.

![target sprite](images/target-sprite.png)

```blocks3
when [space v] key pressed
Expand All @@ -88,7 +82,6 @@ end

Finally, you need to broadcast the `new arrow`{:class="block3events"} message again to get a new arrow.

![target sprite](images/target-sprite.png)

```blocks3
when [space v] key pressed
Expand Down
8 changes: 6 additions & 2 deletions en/step_4.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
## Challenge: Different scores
Can you add code to your game, so that you get a different score for hitting different parts of the target?
## Challenge

--- task ---

Add code to your game so that you get a different score for hitting different parts of the target.

![cross hair on the blue part of the target with the phrase 100 points](images/archery-challenge.png)

--- /task ---
15 changes: 8 additions & 7 deletions en/step_5.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
## What next?
## What can you do now?

Take a look at the [Sprint](https://projects.raspberrypi.org/en/projects/sprint) Scratch project.
Try our [Sprint](https://projects.raspberrypi.org/en/projects/sprint) project where you will create your own sprint game, in which you have to use the left and right arrow keys to get to the finish line as quickly as you can.

You are going to learn how to create your own sprint game, in which you have to use the left and right arrow keys to get to the finish line as quickly as you can.
--- print-only ---

![A mountain scene with a road and a finish line. Time and distance variables are displayed on the screen.](images/sprint-final.png)

--- /print-only ---

--- no-print ---

Expand All @@ -13,8 +17,5 @@ You are going to learn how to create your own sprint game, in which you have to

--- /no-print ---

--- print-only ---

![complete project](images/sprint-final.png)
Or, why not try out another [Scratch](https://projects.raspberrypi.org/en/projects?software%5B%5D=scratch) project?

--- /print-only ---

0 comments on commit 8a9c73f

Please sign in to comment.