At 18:32 24.01.2002 -0500, Carol Mahaffy wrote:
>hey list --
>simple question.. i thought i saw something a while ago... a simple toggle
>using a "not" to swap sprites but i am really getting the syntax wrong. can
>anyone help? heres the code
>
>on mouseUp me
> member("music_on").name = not member("music_off").name
>end
>
>i know i am not calling the sprites right but i have spent a good portion of
>the last 2 hours looking for where i saw the reference and have come up
>empty. thanks
>--carol
Carol,
supposed you have named the members "0" and "1" you might use a behavior
like this one:
-----------------------
property mySprite
on beginsprite me
mySprite = sprite(me.spritenum)
end
on mouseUp me
mySprite.member = \
member(["0","1"][(not(["0","1"].getPos(mysprite.member.name)-1)+1)])
end
-----------------------
best regards
daniel plaenitz
[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!]