?

Log in

Tue, Jun. 19th, 2012, 01:11 pm
Scratch: A Simple Dice Roller Part 1

Started up scratch.
Scratch 1

I've added some commands to it, but I can't seem to make them do anything. Figured out I could rotate my sprite. I have these motions in a stack now. What in the hell do I do?

Greenshot_2012-06-19_12-22-49

Ultimately failed and had to go to the guide... bad.

Apparently clicking on the pieces makes them apply to the action to the object you're on. When you've stacked the blocks though clicking on any of the blocks only runs the first action. I'll presume this is a bug. You have to separate them to get the other actions to do anything. Frustrating.

Turns out it was because of my stack that it was doing this. I remember a speach in Objects in Design about Alice where they noted that you *have* to show people what happened or it will be confusing. In his case he showed somebody setting the bunny to a move in a location that was off screen. He set it into the non-default immediate mode and the bunny simply disappeared. In the default animated mode you watch the bunny slowly slide off screen.

The problem this was meant to solve just happened to me. I set my character to move, rotate 15 degrees, and then point at 90 degrees. The final operation reverses the middle operation so it looked like nothing was working because I didn't understand that the stack would be applied simultaneously. I think this exact moment is instructive for what the Alice design was about, but I'm curious if, in the future, I'll prefer that this stacking applies everything at once all of the time rather than some running versus designing distinction.

Greenshot_2012-06-19_12-30-50

The sprite editor is really easy to use and really helpful. It could use a few extra features like the size of the rectangle you're creating and the like, but for basic stuff it's easy to see all of the options. When you're done with a sprite it properly detects where you've drawn and cuts out all of the extra space for you. I like this a lot.

Greenshot_2012-06-19_12-36-25

It was hard for me to adjust, but I think the paradigm makes sense. I started off trying to answer this using a far too complicated answer. I had forgotten the lesson from Visual Basic.

Greenshot_2012-06-19_12-58-09

Greenshot_2012-06-19_13-10-45

After rethinking it, you put the behavior on the costumes of the sprites to create a dice roller. I don't like that I can't easily duplicate code. I can only duplicate objects. Once you have that in though, it seems to work great!

I have some more work to do to get this thing to the full GURPs features I want, but today's exploration is successfully complete.