Search content:

 

Personal Menu
Username:
Password:
Save password

Become a member

Forgot Password?

 

Don't miss these
Starfield Behavior
Rotate-a-Sprite
Direct Media Balance Slider
Drop-Down Boxes in Director
Mac Disk
Open File with associated extension.
Set PlayBackMode of a Flash Member
KK
XML Text Renderer v1.1
Copy matching Pixels
MediaMacros Xtras Mall
 

 

 

Behavior Image Mover

Added on 9/24/2002

 

Compatibilities:
D8 D8_5 Mac PC Shockwave

This item has not yet been rated

Author: matt_brown_1 (website)

This script moves a set of images across the stage

-- Image Mover
-- (c) 2002 Matt Brown
-- www.flatspinmedia.com
property pTickCount
property pWait
property pInitialize
property pLastTimer --holds timer value at start of wait
global gImage -- number of image we are on

on beginsprite me
  gImage = 1
  pWait = FALSE
  pInitialize = FALSE
end

on exitframe me
  if not pInitialize then
    if sprite(me.spritenum).loch > 397 and sprite(me.spritenum).loch < 402 then
      pWait = TRUE
      pInitialize = TRUE
      pLastTimer = the timer
    else
      pWait = FALSE    
    end if
  end if
  --  
  if pWait = TRUE then
    if (the timer - pLastTimer) < 60*2.5 then -- (2.5) = seconds to wait
      nothing
    else
      pWait = FALSE
      pInitialize = FALSE
      sprite(me.spritenum).loch = sprite(me.spritenum).loch + 4 -- *
      updatestage  
    end if
  else
    sprite(me.spritenum).loch = sprite(me.spritenum).loch + 4 -- *
    updatestage
    -- ## Now check for image swap ## --
    if sprite(me.spritenum).loch > 850 then -- **
      if gImage = 5 then  -- (5) = number of images to cycle
        gImage = 1
      else
        gImage = gImage + 1
      end if
      NewImage =  member("loopimage" & gImage)
      sprite(me.spritenum).member = NewImage
      sprite(me.spritenum).loch = -50
      updatestage
    end if
  end if
end

-- images must be named loopimage1, loopimage2, ... loopimage5
-- * change the 4 to change the speed of movement.
-- ** the 850 is the position you want the image to be swaped at
-- (c) 2002 Matt Brown
-- www.flatspinmedia.com

 


Upload Provided by ABCUpload ASP

Contact

MMI
22 West Court Sq
Suite 2C
Newnan, GA 30263
USA

Fax - (206) 339-5833

Send e-mail