Alice Community

Alice Community (
-   How do I...? (
-   -   parameters (

maxf 10-17-2009 07:55 PM

I have a parameter that is set by the user in my starting method. but i need to use the value of that parameter in another method use later in the program. how can i move the parameter from one method to the other without asking the user for the value again? (i already tried the clipboard and it didn't work)

x2495iiii 10-18-2009 03:56 AM

Since it's a number that is used by more than one method, it would be better suited as a world-class variable. Go to the properties tab of the world and create a variable which sets its value to whatever the user wants it to be at the start of the world. This way, you can have any method reference the variable at any time wthout worrying about passing values.

All times are GMT -5. The time now is 05:49 AM.

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