Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » [scratchblocks] OFFICIAL testing topic
- Owengren
-
100+ posts
[scratchblocks] OFFICIAL testing topic
//Very old scratch (0.0)
//Catagorys:
//Movement
[right v] (10)::motion
x: (0)::motion
y: (0)::motion
x+: (10)::motion
y+: (10)::motion
me to [ v]::motion
me glide to [ v]::motion
me skate to [ v]::motion
x: (0) y: (0)::motion
+x: (0) y: (0)::motion
glide [right v] (10)::motion
skate [right v] (10)::motion
//View
(0)% transparent::looks
(0)% bright::looks
size (0 v)::looks
(transparency %::looks)
(brightness %::looks)
(size)
[say v] [] voice: [normal v] pitch: (normal v) speed: (5)::looks
//Sounds
play [ v]::sound
play [ v] before (1) secs::sound
vol (100)::sound
vol+ (10)::sound
(vol::sound)
//Drawings
[start v] draw::pen
switch mode::pen
draw [square v] size: (0 v)::pen
//Project Starters
go::events hat
key [ v] pressed::events hat
[ v] sended?::events hat
send [ v]::events
(last send::events)
(current send running::events)
//Project Enders
hault all::cap variables
hault script::cap variables
hault block::cap variables
run again::cap variables
exit Scratch::cap variables
new project::cap variables
breakpoint::variables
//Controllers
? <>{
}::control
? <>{
}{
}::control
rep (10){
}::control
wait (1 v)::control
rep ∞{
}::control
rep until <>{
}::control
//Sensors
ask []::sensing
(ask answer::sensing)
<touch [ v]?::sensing>
<touch [#000000]?::sensing>
<[#000000] over [#000000]?::sensing>
//Math
(sum () [+ v] ()::operators)
(sqrt (10)::operators)
(abs (10)::operators)
(In (10)::operators)
(pi::operators)
(e::operators)
(proc constant [my constant v]::operators)//Credit to Dream mod
(\([INSERT SUM BLOCK HERE]\)::operators)
(sum () [+ v] () [- v] ()::operators)//For the "([sum block])" block.
<[] = []>
//String
(join [] []::list)
(char (1) in []::list)
(chars in []::list)
//Data
(var::custom)
[var v] set []::custom
[var v] [show v]::custom
(list::custom-arg)
[list v] add []::custom-arg
[list v] del (1 v)::custom-arg
([list v]'s length::custom-arg)
//Procs
proc {proc::grey}::grey hat
proc::grey
- gabriel2708
-
100+ posts
[scratchblocks] OFFICIAL testing topic
Last edited by gabriel2708 (March 16, 2022 03:53:39)
- Owengren
-
100+ posts
[scratchblocks] OFFICIAL testing topic
How do you get that kind of post?
Last edited by Owengren (Aug. 2, 2016 17:47:27)
- Ziggy741
-
1000+ posts
[scratchblocks] OFFICIAL testing topic
when green flag clicked
set (answer) to [your answer]
when green flag clicked
if <if <> then> then
<<> and <>> :: stack
end
- Ziggy741
-
1000+ posts
[scratchblocks] OFFICIAL testing topic
NOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!when green flag clicked
set (answer) to [your answer]
when green flag clicked
if <if <> then> then
<<> and <>> :: stack
end
when [cry v] key pressed
if <[ v] :: custom> then
cry :: custom
<[] = [] :: stack>
@stop
end
when green flag clicked
@greenFlag :: custom // WHAT!!?!?!?!?!?!?!?!???!!!!!!!!!!!!!!!!!!!???????????????????????????????
@turnRight :: custom
Memory from the musical Cats :: operators
Midnight :: operators
Not a sound from the pavement :: operators
Has the moon lost her memory :: operators
She is smiling alone :: operators
In the lamplight :: operators
The withered leaves collect at my feet :: operators
And the wind begins to moan :: operators
Memory :: operators
All alone in the moonlight :: operators
I can smile at the old days :: operators
I was beautiful then :: operators
I remember :: operators
The time I knew what happiness was :: operators
Let the memory live again :: operators
Every street lamp seems to beat :: operators
A fatalistic warning :: operators
Someone mutters and the streetlamp gutters :: operators
And soon it will be morning :: operators
Daylight :: operators
I must wait for the sunrise :: operators
I must think of a new life :: operators
And I mustn't give in :: operators
When the dawn comes :: operators
Tonight will be a memory too :: operators
And a new day will begin :: operators
Burnt out ends of smoky days :: operators
The stale cold smell of morning :: operators
A streetlamp dies another night is over :: operators
Another day is dawning :: operators
Touch me :: operators
It's so easy to leave me :: operators
All alone with the memory :: operators
Of my days in the sun :: operators
If you touch me :: operators
You'll understand what happiness is :: operators
Look a new day has begun... :: operators
That is Memory from the musical Cats! :: operators
when green flag clicked
if <I'm a boolean :: pen> then
else
else
else
else
end
Hi! :: #000000
hide list [ v]
show list [ v]
||: A A A A A A F# :|| :: grey
< :: sensing>
(pick random (pick random (pick random (pick random (pick random () to (10)) to (10)) to (10)) to (10)) to (10))
cry cry cry
(timer)
when green flag clicked
set [timer v] to [timer] :: sensing
if <> then :: stack
say [] for (2) secs
end
[list]
[list]
[list]
[list]
[list]
[list]
[list]
[/list]
[/list]
[/list]
[/list]
[/list]
[/list]
[/list]
timer
timer
timer
timer
timer
<<<
if <pen up> then
end
Last edited by Ziggy741 (Aug. 4, 2016 18:49:22)
- cat0325
-
500+ posts
[scratchblocks] OFFICIAL testing topic
when green flag clicked
go to x: (-209) y: (100)
switch backdrop to [backdrop1 v]
set [Xv v] to [0]
set [Yv v] to [0]
repeat until <(#) = [9]>
if <key [right arrow v] pressed?> then
change [Xv v] by (1)
point in direction (90 v)
end
if <key [left arrow v] pressed?> then
change [Xv v] by (-1)
point in direction (-90 v)
end
set [Xv v] to ((Xv) * (0))
change x by (Xv)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change x by ((Xv) * (-1))
change y by (-5)
if <key [up arrow v] pressed?> then
if <(Xv) > [0]> then
set [Xv v] to [-5]
else
set [Xv v] to [5]
end
set [Yv v] to [10]
else
set [Xv v] to [0]
end
end
end
end
end
end
end
change [Yv v] by (-1)
change y by (Yv)
if <touching color [#fff] ?> then
change y by ((Yv) * (-1))
set [Yv v] to [0]
end
change y by (-1)
if <touching color [#fff] ?> then
if <key [up arrow v] pressed?> then
set [Yv v] to [15]
end
end
change y by (1)
end
repeat until <(#) = [12]>
if <key [right arrow v] pressed?> then
change [Xv v] by (1)
end
if <key [left arrow v] pressed?> then
change [Xv v] by (-1)
end
set [Xv v] to ((Xv) * (0))
change x by (Xv)
end
repeat until <(backdrop name) = [backdrop4]>
if <key [right arrow v] pressed?> then
change [Xv v] by (1)
end
if <key [left arrow v] pressed?> then
change [Xv v] by (-1)
end
set [Xv v] to ((Xv) * (0))
change x by (Xv)
change [Yv v] by (-1)
change y by (Yv)
if <touching color [#fff] ?> then
change y by ((Yv) * (-1))
set [Yv v] to [0]
end
change y by (-1)
if <touching color [#fff] ?> then
if <key [up arrow v] pressed?> then
set [Yv v] to [15]
end
end
change y by (1)
end
repeat until <(backdrop name) = [backdrop5]>
if <key [right arrow v] pressed?> then
change [Xv v] by (1)
end
if <key [left arrow v] pressed?> then
change [Xv v] by (-1)
end
set [Xv v] to ((Xv) * (0))
change x by (Xv)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
end
end
end
end
end
change [Yv v] by (-1)
change y by (Yv)
if <touching color [#fff] ?> then
change y by ((Yv) * (-1))
set [Yv v] to [0]
end
change y by (-1)
if <touching color [#fff] ?> then
if <key [up arrow v] pressed?> then
set [Yv v] to [15]
end
end
change y by (1)
end
forever
if <key [right arrow v] pressed?> then
change [Xv v] by (1)
end
if <key [left arrow v] pressed?> then
change [Xv v] by (-1)
end
set [Xv v] to ((Xv) * (0))
change x by (Xv)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change y by (1)
if <touching color [#fff] ?> then
change x by ((Xv) * (-1))
change y by (-5)
if <key [up arrow v] pressed?> then
if <(Xv) > [0]> then
set [Xv v] to [-5]
else
set [Xv v] to [5]
end
set [Yv v] to [10]
else
set [Xv v] to [0]
end
end
end
end
end
end
end
change [Yv v] by (-1)
change y by (Yv)
if <touching color [#fff] ?> then
change y by ((Yv) * (-1))
set [Yv v] to [0]
end
change y by (-1)
if <touching color [#fff] ?> then
if <key [up arrow v] pressed?> then
set [Yv v] to [15]
end
end
change y by (1)
end
- _nix
-
1000+ posts
[scratchblocks] OFFICIAL testing topic
For code golf.
when gf clicked
set [a v] to [ABCDEFGHIJKLMNOPQRSTUVWXYZ
set [l v] to [1
repeat (26
set [o v] to [
repeat (l
set [o v] to (join (o) (letter (l) of (a
end
set [i v] to (l
repeat ((26) - (l
change [i v] by (1
set [o v] to (join (o) (letter (i) of (a
end
say (o) for (1) secs
change [l v] by (1
end
- JavierR100
-
500+ posts
[scratchblocks] OFFICIAL testing topic
when gf clickedk sory for the spam.
set [infinite grey blocks v] to ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say ({say } @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)} @addInput :: grey ring)
- ronforco
-
81 posts
[scratchblocks] OFFICIAL testing topic
when green flag is ((2000) bc :: sensing ring) :: sensing hatsorry for spamming
set [the big score v] to (say ((say (say (say (say (say (say (say (say (say (say (say (VelocityY)))))))))))))
- agarraga
-
500+ posts
[scratchblocks] OFFICIAL testing topic
when green flag clicked
if <if <> then> then
play drum <stamp> for (0.25) beats
else
set pen color to [#123456]
end
- Owengren
-
100+ posts
[scratchblocks] OFFICIAL testing topic
Use magnifier program, set size to 1x, have colors inverted, hover on the script below and look at the magnifier program!
So funny!
So funny!
when I start as a clone
Why blue?::motion
Why brown?::events
Why bright purple?::custom-arg
Why bright green?::operators
Why purple?::looks
Why green?::pen
Why pink?::sound
I had enough!
- agmmes
-
100+ posts
[scratchblocks] OFFICIAL testing topic
when I receive [vines v]
if <<touching [heart v] ?> and <(costume #) = [2(Red lines sprite # here]>> then
clear graphic effects (something here, or you can use this block.)
end
if <<touching [heart v] ?> and <not <(costume #) = [2(Also red lines # here]>>> then
broadcast [hit v]
[or if you use HP points variable then(DELETE THIS BLOCK, OKAY?)]
change [Soul lives(soul HP var here v] by (-1)
end
vines code for omega flowey if someone want.
here is code coming:
scratch.blocks(without .)
when I receive
if <<touching ?> and <(costume #) = >> then
clear graphic effects
end
if <<touching ?> and <not <(costume #) = >>> then
broadcast
change by (-1)
end
/scratch.blocks(also without .)
Last edited by agmmes (Aug. 3, 2016 13:05:16)
- agmmes
-
100+ posts
[scratchblocks] OFFICIAL testing topic
Last edited by agmmes (Aug. 3, 2016 13:11:54)
- finnb4513
-
100+ posts
[scratchblocks] OFFICIAL testing topic
Let me try something…
when green flag clicked
set pen color to (move (10) steps::motion hat)
- ronforco
-
81 posts
[scratchblocks] OFFICIAL testing topic
beacause blue is motion, Use magnifier program, set size to 1x, have colors inverted, hover on the script below and look at the magnifier program!
So funny!when I start as a clone
Why blue?::motion
Why brown?::events
Why bright purple?::custom-arg
Why bright green?::operators
Why purple?::looks
Why green?::pen
Why pink?::sound
I had enough!
brown is events,
bright purple is custom argument,
bright green is operators,
purple is looks,
green is pen,
pink is sound,
and red is obsolete.
- SuperHal989
-
88 posts
[scratchblocks] OFFICIAL testing topic
when green flag clicked
play sound (join [] [world])
play sound (join [] [world]) until done
- gabriel2708
-
100+ posts
[scratchblocks] OFFICIAL testing topic
Last edited by gabriel2708 (March 16, 2022 03:49:28)
- superkoopa600
-
1 post
[scratchblocks] OFFICIAL testing topic
when green flag clicked
forever
go to x: () y: (0)
go to [ v]
go to [ v]
go to [ v]
go to [ v]
go to [ v]
go to [ v]
end