Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » answer bar
- Remixer2-0
- Scratcher
42 posts
answer bar
so I'm trying to make this thing were you have to input answers but I don't know how to get the box that players can type their answer in to
- benk_b4b
- Scratcher
100+ posts
answer bar
It's in sensing, this is what it looks like:
You input the text into there. Once someone answers, the latest thing they answered is stored in this block:
So you can do something like this as an example:
ask [] and wait
You input the text into there. Once someone answers, the latest thing they answered is stored in this block:
(answer)
So you can do something like this as an example:
when green flag clicked
ask [What's 1+1?] and wait
if <(answer) = [2]> then
say [Correct!]
else
say [Incorrect!]
end
I've coded for almost 7 years, decently advanced, though I don't use scratch much anymore.
when I receive [Question v]
Try to solve(question)::custom
say (answer)
- Burnt-Butter-Toast
- Scratcher
78 posts
answer bar
It's in sensing, this is what it looks like:ask [] and wait
You input the text into there. Once someone answers, the latest thing they answered is stored in this block:(answer)
So you can do something like this as an example:when green flag clicked
ask [What's 1+1?] and wait
if <(answer) = [2]> then
say [Correct!]
else
say [Incorrect!]
end
when green flag clicked
ask [What's the quadratic formula for a slope?] and wait
if <(answer) = [y=mx+b]> then
say [Correct!]
else
say [Incorrect!]
end
when green flag clicked
Forget Toast
move (10) steps
Put Butter
- benk_b4b
- Scratcher
100+ posts
answer bar
Yep!
I've coded for almost 7 years, decently advanced, though I don't use scratch much anymore.
when I receive [Question v]
Try to solve(question)::custom
say (answer)
- benk_b4b
- Scratcher
100+ posts
answer bar
Though y=mx+b is slope-intercept form, while the quadratic equation is (-b±√b^2-4ac)/2a
I've coded for almost 7 years, decently advanced, though I don't use scratch much anymore.
when I receive [Question v]
Try to solve(question)::custom
say (answer)
- Remixer2-0
- Scratcher
42 posts
answer bar
I don't understand big maths here but thanks I will try this!
- Remixer2-0
- Scratcher
42 posts
answer bar
it worked I don't understand big maths here but thanks I will try this!
- Discussion Forums
- » Help with Scripts
- » answer bar