SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    SitePoint Wizard bbolte's Avatar
    Join Date
    Nov 2001
    Location
    The Central Plains
    Posts
    3,304
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question Director Lingo help

    ok, i have a sprite in channel 2 that i want to swap with a random cast member (one of three) when a certain frame is reached in the score. here is a script i've tried but it isn't swapping the sprite:

    on enterframe
    global randomPic
    randomPic = random(3)
    if randomPic = 1 then
    set randomPic = "blueRec"
    else if randomPic = 2 then
    set randomPic = "redRec"
    else if randomPic = 3 then
    set randomPic = "greenRec"
    end if
    put randomPic
    sprite(2).member = randompic
    updateStage
    end

    anyone have any ideas?

  2. #2
    Don't get too close, I bite! Nicky's Avatar
    Join Date
    Jul 1999
    Location
    Lancashire, UK
    Posts
    8,277
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    You can use
    enterframe
    if all you want to do is change it the one time.

  3. #3
    SitePoint Wizard bbolte's Avatar
    Join Date
    Nov 2001
    Location
    The Central Plains
    Posts
    3,304
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    yes i just need it to change once (this is at the beginning, this way it will be slightly different each time it is started). but, this script i tried didn't work.

  4. #4
    SitePoint Wizard bbolte's Avatar
    Join Date
    Nov 2001
    Location
    The Central Plains
    Posts
    3,304
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm actually thinking of a different way to do this by generating the random number and using that to jump to 1 of 3 markers. i posted this same question on were-here and didn't get anywhere there either.

  5. #5
    Don't get too close, I bite! Nicky's Avatar
    Join Date
    Jul 1999
    Location
    Lancashire, UK
    Posts
    8,277
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    I'm not too hot on Lingo.

    Have you checked that the sprites have been assigned a name?

  6. #6
    SitePoint Wizard bbolte's Avatar
    Join Date
    Nov 2001
    Location
    The Central Plains
    Posts
    3,304
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    yep

  7. #7
    Don't get too close, I bite! Nicky's Avatar
    Join Date
    Jul 1999
    Location
    Lancashire, UK
    Posts
    8,277
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Maybe one of the Flash dudes can come in here and offer some advice!


Bookmarks

Posting Permissions

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