This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.
  • Index
  •  » Suggestions
  •  » Edge option for distance to block, collective naming for sprites

#1 2007-12-07 10:19:57

ooogabooga
Scratcher
Registered: 2007-10-30
Posts: 56

Edge option for distance to block, collective naming for sprites

There needs to be a block that reports the distance to the edge of the screen. Also, there should be a way to name a large number of sprites the same thing, so you can do simulations of herds, flocks, etc.


I am ooogabooga, lord of all scratch and the Internet, and also the "Suggestions" forum. Buwhahahahahahahahhahaahahahahahhahahhahahahahahah!
   big_smile   big_smile   big_smile   big_smile   big_smile  big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile

Offline

 

#2 2007-12-07 11:21:21

kevin_karplus
Scratcher
Registered: 2007-04-27
Posts: 1000+

Re: Edge option for distance to block, collective naming for sprites

Having a single "distance to edge" operator would be confusing---which edge do you mean?

Distance to a specific edge of the screen is fairly easily computed now:

distance to right edge = 240-<xposition>
distance to left edge = <xposition>+240
distance to top edge = 180-<yposition>
distance to bottom edge = <yposition>+180

Simulating herds and flocks would be a really good use for multiple instantiation of flocks.  Currently, I recommend starlogo for such simulations (free  from http://education.mit.edu/starlogo), though the version I have on my Mac is rather buggy and crashes a lot, so I don't use it with kids (other than my son).  The starlogo people have decided to put all their efforts onto using the latest and greatest versions of java, so their stuff is unlikely to run on any school computers (except in the very richest schools).

Offline

 
  • Index
  •  » Suggestions
  •  » Edge option for distance to block, collective naming for sprites

Board footer