put the behavior on a sprite which is not on the right place and the behabiorwill ask for which sprite do u want to link the position which is the sprite in the right loc on the puzzle
property mysprite
property other
property f
property myloch
property mylocv
property initialh
property initialv
property wrong
property rightv
Property which
on beginsprite me
mysprite=sprite(me.spritenum)
other=sprite(which)
myloch=other.loch
mylocv=other.locv
on mousedown me
put 1 into f
mysprite.moveablesprite=1
initialh=mysprite.loch
initialv=mysprite.locv
cursor 290
end
on mouseup me
put 0 into f
if mysprite.intersects (which) then
set the loch of mysprite to myloch
else
set the loch of mysprite to initialh
end if
if mysprite.intersects (which) then
set the locv of mysprite to mylocv
else
set the locv of mysprite to initialv
end if
cursor 260
on exitframe me
--to drag and drop
if f=1 then
mysprite.moveablesprite=1
end if
---------------------------------
end
on getPropertyDescriptionList me
set props= [:]
props.addProp(#which, [#format: #integer, #default: 50, #comment: "whichsprite"])
return props
end
Contact
MMI
36 South Court Sq
Suite 300
Newnan, GA 30263
USA