So I ran tests this time before posting (=]) and I'm still stuck, so
here goes.
I want to have a list of objects, which form a "stack" of current
operations being
performed. Each time a new operation needs to take place, the handler
"getStackPointer" is called, which finds an empty space in a linear
list, creates a new instance of an object, and then returns the position
in the list of the new object, ie:
(my stack is declared on startmovie to be a linear list of 25 positions)
global myStack
on getStackPointer
counter = 1
repeat with counter = 1 to myStack.count
if myStack[counter] = 0 then
myStack[counter] = new(script "myScript")
return counter
end if
end repeat
end getStackPointer
Everything seems straightforward here, and the script compiles without
syntax errors. However, when I run the movie and call the handler
myStack[counter] is always returned as VOID. Since the list is filled
with 0's at startMovie, I at least know the value is being changed. Why
is it not changed to the new script instance? Do I have a logic error
that anyone can see, or is this just illegal?
~matt desimone
[EMAIL PROTECTED]
www.syrupnyc.com
[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/lingo-l.cgi To post messages to the list, email
[EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for
learning and helping with programming Lingo. Thanks!]