Ask a Question related to Macromedia Director Lingo, Design and Development.
-
ieraks webforumsuser@macromedia.com #1
how can i make a sprite un-moveable
I use this script to drag a sprite and match it with another
and works very good with the rest of my script.
I have one problem with it , i want to force it not to be moveable when i am trying to drag it for second time.
e.g. when i am trying to drag it the first time , the sprite moves and itis ok.
now , if i try to drag it again i want the sprite being unmoveable
i know about moveablesprite=false or true but nothing
can you help me please
thanks a lot
[ on beginSprite me
pPressed = FALSE
pOrigLoc = sprite(me.spriteNum).loc
end
on mouseDown me
pPressed = TRUE
pClickDiff = sprite(me.spriteNum).loc - the clickLoc
end
on mouseUp me
release(me)
end
on mouseUpOutside me
release(me)
end
on exitFrame me
if pPressed then
sprite(me.spriteNum).loc = the mouseLoc + pClickDiff
end if
end ]
ieraks webforumsuser@macromedia.com Guest
-
How to make a sprite so mouse accept its shape?
Hi everyone! I have made a circle in Photoshop and the area out of the border of the circle is transparent. It gets into Director as it really... -
Using the moveable sprite property
hi, I've been using the moveable sprite property button in the property inspector to enable a user to move a sprite. I notice that the moveability... -
make one sprite follow another
I'm making a small game. I want one sprite to jump and if it intersects the other sprite in another channel, it is to follow this sprite, who moves... -
Moveable Text Sprite
Hi I am trying to add multiple 'post it' style notes to a director(8.5) project i can get the editable text fields to move(on the stage during... -
Make Sprite hide and then appear.
I have a project were I need certain layers to be hidden and when it gets to a certain page number in the projector then those layers will be turn... -
rick@mcorp webforumsuser@macromedia.com #2
Re: how can i make a sprite un-moveable
-- This might help:
property pactive
on beginSprite me
pactive = 0
end
on mousedown me
if pactive = 0 then pactive = 1
end
on mouseUp me
pactive = 2
end
on mouseUpOutside me
pactive = 2
end
on exitFrame me
if pactive = 1 then
sprite(me.spriteNum).loc = the mouseLoc
end if
end
-- good luck!
rick@mcorp webforumsuser@macromedia.com Guest



Reply With Quote

