Irv Kalb wrote:
>
> Others have already pointed out the need for the "me" variable. But
> I'll add something else. If you have a behavior where to want to
> send something to the same sprite number, instead of hard coding the
> sprite number, use the built in "spriteNum" variable. For example,
> instead of:
>
> sendSprite(3, #checkRight, 15)
>
> use
>
> sendSprite(spriteNum, #checkRight, 15)
>
> And be sure to declare "property spriteNum" as the top of the script.
> This makes the behavior much more general. You could use it in any
> channel, and it will continue to work if you move your sprite from
> channel 3 to some other channel.
>
> Irv
This works when the behaviour is applied to the sprite during authoring,
and it's a wonderful thing.
But, if you apply the behaviour on the fly with Lingo, 'spriteNum'
doesn't get a value. You'll need to set the property explicitly.
--
Carl West [EMAIL PROTECTED]
617.262.8830 x246
I have no superfluous leisure; my stay must be
stolen out of other affairs; but I will attend you awhile.
- Isabella, Measure for Measure, Act 3 Scene 1
[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/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!]