Alice Community

Alice Community (http://www.alice.org/community/index.php)
-   How do I...? (http://www.alice.org/community/forumdisplay.php?f=16)
-   -   how to +/- the index in a "for all in order" (http://www.alice.org/community/showthread.php?t=4527)

gypsy fly 06-01-2010 05:33 PM

how to +/- the index in a "for all in order"
 
It would be nice to do a "wave" by a row of fairies such that the currently indexed object in a "for all in order" is at the "crest" of the "wave" while those besides to the left and right are at the ebb and start of the "wave".

Say a call to the method "standUpWave" uses index, then "sitDown" would need index-1 and "startWave" is called with index+1. Or, startWave uses index while index-1 and index-2 call on "standUpWave" and "sitDown", respectively.

How is the index in a "for all in order" accessed?

Niteshifter 06-01-2010 05:42 PM

It's not accessed. You have to use the loop command and manually make the iterator yourself to access the index.

gypsy fly 06-02-2010 12:30 PM

I thought so .... oh, well!


All times are GMT -5. The time now is 12:33 PM.

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