Moves the sprite where the behavior is attached and upper sprites you specify the last sprite by channel number.
property spriteNum
property first
property lastSprite
on getPropertyDescriptionList me
set pdList = [:]
set ls = the currentSpriteNum + 1
addProp pdList, #lastSprite, [#format:#integer,#default:ls,#comment:"Sprite-No. to the last sprite in group"]
return pdList
end getPropertyDescriptionList
on beginSprite me
first = me.spriteNum
end
on mouseDown me
beginMouseLoc = the mouseLoc
repeat while the mouseDown
duringMouseLoc = the mouseLoc
if duringMouseLoc <> beginMouseLoc then
difMouseLoc = duringMouseLoc - beginMouseLoc
beginMouseLoc = duringMouseLoc
repeat with i = first to lastSprite
sprite(i).loc = sprite(i).loc + difMouseLoc
end repeat
updateStage
end if
end repeat
end
Contact
MMI
36 South Court Sq
Suite 300
Newnan, GA 30263
USA