Tcl/Tk is slow, but it has something that fast, compiled languages lack: It is an interpreter. While conventional languages implement evolution by evolving parameters (e.g. making an agent faster by increasing its Speed value), interpreted languages can also evolve the rules themselves. Besides, Tcl/Tk is a beautiful language.
Rule evolution is not yet implemented in the current version of tFloys, but I hope to add it to future versions.
Sun's Tcl/Tk plugin Ver 2 is needed for the tFloys tclet. It is downloadable from http://www.scriptics.com/products/tcltk/plugin.html
Instructions
Bottom Button Bar
| Run | Start tFloys activity |
| Scramble | Randomize tFloys properties, including groups and colors, and restart activity |
| Environment | Modify environmental properties and restart activity. The delay parameter should be kept as low as possible, such that the application does not get stuck. Lower values provide smoother movement. Number of tFloys is preferably kept below 10, although higher values may work too. |
| Traits | Modify tFloys properties. Most important is the relation between acceleration and attraction to target. Play with all the properties to see their effect. |
| Test | A test button, used for debugging purposes |
| Quit | Quit program. This button is used in Wish, but has no significance in plugin environment. In a browser simply move to another URL. |
Left Button Bar
| Insert Picture | Insert a background scene. Picture loading might take several seconds. A second click will remove the picture |
| Insert Obstacle | Insert a bar shaped obstacle. The bar appears at the top left corner, and you can drag it to any other location. The bar functions as a barrier to tFloys movement. Remove the bar by clicking the obstacle button again. |
| Insert Target | Insert a draggable target symbol (The red circle can stand for food), and the tFloys will be attracted to it. The symbol appears at the center, but you can drag it anywhere. Remove by a second click. |
| Toggle Behavior | Toggle between two types of behavior. Type 0 is more social, meaning that tFloys tend to stick together, while type 1 more individualistic. Each click switches to the other behavior. |
| Pause Execution | Click on Pause and all movement is freezed. Click again and movement is resumed. |
| Stop Execution | Stop execution and erase screen |
Right Button Bar
| Show Current | Display a table with current properties of all tFloys. Only available after Run is selected and activity begins. |
| Start Log | Start/Stop debug logging. Currently logging is mainly used for debugging, and it does not have any useful function |
| Save Log | Save log information to a file. Not available in plugin environment (for security limitations) |
| Reset Log | Reset log information, to restart logging from scratch. |
| Show Log | Display log information within the Tclet |
| Notepad Log | Display log information in Windows' Notepad. Available only in Wish under Windows OS (not in plugin environment) |
Tcl/Tk is promoted by the Tcl/Tk Consortium, a non-profit organization dedicated to promoting Tcl/Tk.