Alice Community  

Go Back   Alice Community > Alice 2 > How do I...?

Reply
 
Thread Tools Display Modes
How do i make a 'script' command?
Old
RavenOfCode
Senior Member
 
RavenOfCode's Avatar
 
Status: Offline
Posts: 409
Join Date: Oct 2013
Location: Northern Virginia
Question How do i make a 'script' command? - 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?


Stuff + Other Stuff + Different Other Stuff = Things :)

My best Alice game:

Clash of the Cubes (an arena fighting game):
http://www.alice.org/community/showthread.php?t=10738&highlight=game
   
Reply With Quote
You Can't
Old
MrMoke
Senior Member
 
MrMoke's Avatar
 
Status: Offline
Posts: 501
Join Date: Sep 2007
Location: Austin, Texas
Thumbs down You Can't - 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.

Last edited by MrMoke; 02-21-2014 at 01:21 PM.
   
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Copyright ©2024, Carnegie Mellon University
Alice 2.x © 1999-2012, Alice 3.x © 2008-2012, Carnegie Mellon University. All rights reserved.