Attaching behaviour to sprite with Lingo?

Ask a Question related to Macromedia Director Basics, Design and Development.

  1. #1

    Default Attaching behaviour to sprite with Lingo?

    Attaching behaviour to sprite with Lingo?!
    Created On Sunday 29, June, 2003 2:11 PM
    Attaching behaviour to sprite with Lingo?!



    TomaHawKPT
    Junior Member

    Posts: 1
    Joined: Jun 2003
    Sunday, June 29, 2003 2:11 PM (New!)



    Hi,

    I have a script that I want to attach a behaviour to a sprite dinamicly with Lingo. How can I do that? The behaviour as several property elements

    I've tried the next with no sucess
    sprite(mapSprite).member = member("map_crop")
    sprite(mapSprite).puppet = true
    scriptTemp = new(script "zoomInOut", 25, 740, 540, 80, 80, 400, 300, 530, 530)
    sprite(mapSprite).scriptList.append(scriptTemp)

    I have no idea what so ever of what to do :(

    Thank you





    TomaHawKPT webforumsuser@macromedia.com Guest

  2. Similar Questions and Discussions

    1. Copy sprite behaviour
      Hi All Is there an easy way to copy / cut the behaviour attached to a sprite to a new behaviour that can then be attached to multiple sprite...
    2. Attaching behaviors on the fly and other misunderstood Lingo
      I am trying to cause several sprites stacked one on top of the other on the stage to have a more natural falling action. Let's say there are 5 box...
    3. Lingo attaching scipt to a field
      I have just written a script which creates field with a key-number and text in the cast. I know how to put those fields to stage but now I was...
    4. Attaching a sprite to a cursor
      Hi All, Can anyone help me on how to attach a sprite to a cursor so that it follows the cursor whever it goes on the screen? I'm a newbie so...
    5. How do I change a propert of a custom behaviour attached to a sprite with lingo.
      Kevin Fink wrote: When you want to change the value of a property of a instance of a behavior (or object), you only need to do :...
  3. #2

    Default Re: Attaching behaviour to sprite with Lingo?

    In article <bdmqj0$2tv$1@forums.macromedia.com>, "TomaHawKPT"
    [email]webforumsuser@macromedia.com[/email] wrote:
    > I have a script that I want to attach a behaviour to a sprite dinamicly
    with Lingo. How can I do that? The behaviour as several property elements
    >
    > I've tried the next with no sucess
    > sprite(mapSprite).member = member("map_crop")
    > sprite(mapSprite).puppet = true
    > scriptTemp = new(script "zoomInOut", 25, 740, 540, 80, 80, 400, 300, 530, 530)
    > sprite(mapSprite).scriptList.append(scriptTemp)
    >
    > I have no idea what so ever of what to do :(
    >
    If member("map_crop") is a behavior type of script this will work:

    sprite(mapSprite).scriptInstanceList.append((scrip t "map_crop").new())

    You were close.

    Gretchen Macdowall
    [url]http://www.updatestage.com/[/url]
    Gretchen Macdowall Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139