PDA

View Full Version : How do i make a 'script' command?


RavenOfCode
02-15-2014, 01:36 PM
Im currently trying to make a game with a high score i can save in a .txt file, i found some code in someone else's game and they use a 'script' command, how do i this?:confused:

MrMoke
02-15-2014, 02:41 PM
I did the same thing a few years ago, and it was lot's of fun. If you intend to use scripting then you must first familiarize yourself with Jython(Java+Python) scripting. There are lot's of Web Tutorials out there. Interestingly, "World" variables can be used as "global" variables in the scripts, so that data can pass between the scripts and Alice. This link will take you to an old site at Univ. of West Georgia that describes how to turn it on. After it is turned on, you right-click World, and select "Edit Script". That pane is where you put your script code.

http://www.westga.edu/~drocco/alice/

Unfortunately, Scripting will not work with any versions of Alice 2 newer than version 2.2. I have pointed out this, and several other self-inflicted problems, with the newer Alice versions including 2.4.1, and the Alice is supposed to be fixing them in a timely fashion.