[Squeakland] getting code from a .txt file into a script

Gary Frederick gary.frederick at jsoft.com
Wed Mar 24 05:58:43 PST 2004


Howdy,

Ned Konz wrote:

trim
> So if you could translate your text files into this format you may be able to 
> use them directly (depending on the vocabulary).
> 
> What's the format of your text files? Can you send me one?

The files are programs that run on robots and simulators. They are XML.

> 
> You could do this:
> 
> * make a blank project with a Sketch in it that represents the robot.
> 
> * Make a new script in that Sketch that will prompt for a file and read your 
> text format into methods (it would be best, probably, to put the reader 
> method in another class (perhaps Player) so that you can make multiple Sketch 
> classes that can read such files).

This is where I think I want to go. I'll email you some info personally 
Ned and give you some details. (I'll email anyone that wants, info, I 
don't want to fill this list with stuff that is not really on topic)

trim

> You should distribute projects instead of images.

I will as soon as I find out how to distribute projects :-S

Gary


More information about the Squeakland mailing list