Div Role "Log: Catch The Bugs
Div Role "Log: Catch The Bugs
DOC- <script
Creative Coding With Scratch
{
rip
html> script>
t ”/>
Getting Started
! - -
Select Blue Sky backdrop.
<
<div
}
Choose Beetle, Butterfly 3 and
Ladybug 1 from the sprite library
and decrease size of each.
role=”log
<html
Challenge 1
>
Can you make each of the bugs move up and down forever?
< / class=
>
Challenge 2
Can you make the frog follow the mouse-pointer?
ss= />
c l a
/
tm l
-
<h
-
Challenge 3
!
< element.
Can you make the bugs disappear when the frog touches them?
<
Challenge 4
Can you add messages, sound effects or scoring to improve your
style {
game?
}
I can:
“te select a backdrop and a sprite;
xt/
j av program more than one sprite;
/>
asmake a sprite follow a mouse-pointer;
cri one sprite sense and interact with another sprite; l a ss=
p l c
<htm
make
create ta”simple
/> game.
Page 1 of 2
<!DOC- <script
Creative Coding With Scratch
{
rip
html> script>
t
”/> task, which can be approached
Each Creative Coding Challenge is an open-ended
-
in many different ways. Pupils should be encouraged to have a go and tackle these
-
tasks independently. The following hints are not intended to provide complete
!
solutions but may serve as useful cues for supporting less-confident coders.
<
<div
}
To make a sprite travel forever in a vertical when space key pressed
direction: point in direction 0 secs
role=”log
forever
move 10 steps
if on edge, bounce
<html
/ >
To make a sprite follow a mouse-pointer:
<
when space key pressed
forever
class=
>
go to mouse-pointer
ss= />
c l a
/
ml
-
<ht
-
<! element.
To make a sprite disappear when it touches
another sprite:
if touching Frog then
hide
<
style {
“te
xt /
jav
asc
rip
} c l a ss= />
t ”/> <ht ml
Page 2 of 2