Drag and Drop objects to rearrange anagram

Started by barefoot, Tue 19/01/2010 09:52:54

Previous topic - Next topic

barefoot

Hi

I have looked for an object function/event in the manual etc that will allow user to move objects around via the mouse, but to no effect, as yet.

Basically there is an anagram, which you rearrange until you find the correct phrase, no other action is required.

12 letters (objects) make up the 2 word phrase

all help appreciated

barefoot
I May Not Be Perfect but I Have A Big Heart ..

Lufia

The IsButtonDown funtion will be useful for this.
Basically, you'd set an object coordinates to mouse.x and mouse.y while the mouse button is pressed.

I haven't thought about this in detail, I just hope I can help you get on the right track.

Calin Leafshade

Yeah like lufia says.

just bind the object's x and y to the mouse. To make it even more appealing to the eye have an offset value equal to the position of the mouse on the object when the mouse is first held down. so the object doesn't 'snap' to the mouse.

Store the original value too so that if the mouse is released somewhere it shouldnt be you can snap the object back to its original location.

barefoot

I May Not Be Perfect but I Have A Big Heart ..


SMF spam blocked by CleanTalk