Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash








Click And Drag Question


On of FI Study Cases is * DoTu * from Tiny Toons

http://www.fantasy-interactive.com/dotu/

when u enter the site it self the menu system works by clicking the edges and draging it to the middle making a bounce effect.

if anyone knows where i can find a tutorial for this please direct me to it if not if you could make one for me to download please be so kind to helping me out.


THank you all in advanced for ever opening this thread




FlashKit > Flash Help > Flash Newbies
Posted on: 02-07-2005, 02:19 PM


View Complete Forum Thread with Replies

Sponsored Links:

Click & Drag Baby, Click & Drag
Ok peeps, check out this page

You can click & drag this map around, also zooming in and out. As you can see it's constrained so you never run out of image area. However when you zoom in & move the map so you can see the bottom edge, then zoom back out, you get a nasty white gap, which rights itself when you click on the map.

I need some way of stopping this nasty white gap appearing, any ideas anyone?

The "Zoom In" button has these actions applied:

on (release) {
_root.map._xscale += 20;
_root.map._yscale += 20;
}


The "Zoom Out" button has these actions applied:

on (release) {
if (_root.map._xscale>=101) {
_root.map._xscale += -20;
_root.map._yscale += -20;
} else if (_root.map<=100) {
setProperty("_root.map", _xscale, "100");
setProperty("_root.map", _yscale, "100");
}
}

While the map has these actions:

on (press) {
startDrag("_root.map", false, stage.width-_root.map._width,
stage.height-_root.map._height, 0, 0);
}
on (release, releaseOutside) {
stopDrag();
}

Cheers

View Replies !    View Related
[CS3] Click Pickup, Drag, Click Drop
How can I make the following code work so that when I click on a piece it drags when I release the mouse button and then I click again to drop it in place? Thanks in advance!


Code:
piece1.onPress = function():Void {
this.startDrag(true);
this.swapDepths(this.getNextHighestDepth());
xstart = this._x;
ystart = this._y;

};
piece1.onRelease = function():Void {
this.stopDrag();
if (eval(this._droptarget) == target1) {
this.enabled = false;
this.swapDepths(target1);
counter++;
correct = new Sound(soundLoader);
correct.loadSound("Gong.mp3",true);
this._x = target1._x;
this._y = target1._y;
} else {
this._x = xstart;
this._y = ystart;
}
};

View Replies !    View Related
Help Please. Has To Do With Click-and-drag.
First of all, there is a link below to a calculator SWF. Can someone please edit it and make it so you can click on the outside part of the calculator, and drag it to wherever you want on the screen? I'd really appreciate it. Here is the link:

http://www.geocities.com/n355f0ur733n/calculator.swf

View Replies !    View Related
Click And Drag
What i'm wanting to do is... Have a mask and have it to where I can click and drag that mask up and down. So i'm assuming that I would not only need the action script for clicking and dragging but also to set the parameters for its movement. Thanks for any help and a tut would be greatly appreciated.
Pat

View Replies !    View Related
Click And Drag
how do you make a button click and dragable?

View Replies !    View Related
Click And Drag
someone once showed me how to make an abject click and dragable. it had to do with putting a button inside a movie, or a movie inside a button, but i dont know the code it put in it... i know it wasnt much but i dont know much about flash and i forgot

View Replies !    View Related
Click N' Drag
how do i make an object "click and drag"able. i used to know, and it had to do with putting a button inside i movie or the other way around, but i need the code for it

View Replies !    View Related
Click And Drag
can someone post the code to make a symbol click and dragable? i had it before but now i cant get to any of my old files. It had something to do with making a button and puting it in a movie clip then adding code(maybe switched around a little)

-thanks

View Replies !    View Related
Drag/Click MC
I have a project with a bunch of draggable movie clips which are also "buttons" (as in they take you to another frame, etc.) How can I have flash determine if the user is dragging the movie clip or clicking it?

View Replies !    View Related
Click And Drag
Whats an easy way to make an object moveable with click and drag?

View Replies !    View Related
Click And Drag
What is the most simple way to make a graphic or group click-and-dragable? I knew how a loooong time ago, but ive comletely forgotten and i no longer have any of my old flash projects.

View Replies !    View Related
Click And Drag
OKay, fairly simple problem. I have an image I want to have a ton of the same one click and dragable around the screen.. heres my code
ActionScript Code:
this.box_mc.addEventListener(MouseEvent.MOUSE_DOWN, dragMe);

function dragMe (e:MouseEvent): void{
    this.box_mc.startDrag(true)
}

this.box_mc.addEventListener(MouseEvent.MOUSE_UP, releaseMe);

function releaseMe(e:MouseEvent):void{
    stopDrag();
}

but when I drag more then one of the symbol onto the stage only one is click/dragable. Why is that?

Thank you!
Enu

View Replies !    View Related
Click And Drag
Hi,

I has a clip that gets copied if you click and drag. However, if you copy another clip from the main clip the new clip seems to overide the previous clips actions. Basically as you roll over a copied clip flash needs to detect it.

I have attached a fla that explains this much, much better! Hope someone can help!

Thanks

View Replies !    View Related
Click, Drag, Snap..yes No
I know what I want.. the question is how?
Imagine 10 objects ( 5 fixed and 5 draggable)
THe draggables snap into position over the fixed when released in that postion. If the correct draggables are ALL over the appropriate fixed then the movie goes to a new scene/frame, if they are not all correct, the wrong ones snap to their orriginal position. This continues until they are all correctly collocated.

View Replies !    View Related
Drag AND Double Click
what events do you code for when trying to drag something, but do different stuff if double clicked?

right now, i got an onPress Event which then hits up an onEnterFrame to drag

i also set the onMouseDown event to look for double click with an interval, seeing if click was hit more then once before interval expired

but it comes back as always being double clicked??
and if i throw the click thing in the onPress event, it doesnt realize the double click consistently

any ideas?

View Replies !    View Related
Mx2004 Click & Drag MC's
I have a flash document, where there are four layers, each containing a Movie Clip.

I would like to make it so that you can move the four MCs around the page by clicking a dragging... however, I also wish to make it so that when you click on an MC, it becomes the top layer.

(please see an example of what I wish to achieve at http://www.rockstargames.com/vicecity/

goto the metal box in the far back - right hand corner and look inside.

I want the same to happen, but I don't want them to come to the top until you click on them. (i'll just replace the "mouseOver" with "release"... simple

so, does anyone have any idea with what I am talking about??? ... i don't

cheers



DKeegh

View Replies !    View Related
Duplicating MCs With Click-drag
Please look at the script below:

code:
//Frame 1
n=0

//Frame 4
_root.happyBirthday_MC.onPress = function() {
n++;
duplicateMovieClip(_root.happyBirthday_MC, "newArt" + n, n);
}

\Frame 5
gotoAndPlay(4);



happyBirthday_MC is a movie clip with a button inside.

What I want is to click-drag a duplicate of this MC. The way it is working now is I have to click the original MC once, then click-drag the duplicate. I have to do this for each duplicate I want.

Also, writing this as a function in a frame as opposed to putting it directly on the MC seems to negate the button's 'HIT' area.

Any ideas?

Thanks!!

View Replies !    View Related
Game Click And Drag
hi

I'm looking for flash game but doen't really know what to search for. because there are so many movies.

I would like to do a "click and drop" game, there are a few blank placeholders (pictures) on a horizontal line and the user have to choose the correct pictures to put them into the placeholder. its about filters and how and in which order to install them into your houshold (the horizontal line is your water pipe in the cellar)

so there will be 3 blank placeholders and about 5 pictures to choose. the problem is, that there are more possibilities than only 3. because the result will be another, if you install filter 1 on the second place instead of the first. and for each installation variant there should be some descriptive text about the resolution.

could anybody help me with my idea or does anybody have a similar games, because I'm a beginner in flash scripts and my idea was to copy the script from such a "click and drag" game.

would be great to get some helpful answers. thanks a lot!

View Replies !    View Related
Click And Drag Question
Hi, I'm making a flash picture photo gallery system.

http://www.inputoutput.net/piclister/
http://pics.inputoutput.net/picliste...umID=6&index=0

I'm having a problem. Try going to the second link and drag the picture frame(gray border around the picture) out of the stage. I would like to restrict people from doing that. Any suggestions?

Thanks

View Replies !    View Related
Click And Drag Question
On of FI Study Cases is * DoTu * from Tiny Toons

http://www.fantasy-interactive.com/dotu/

when u enter the site it self the menu system works by clicking the edges and draging it to the middle making a bounce effect.

if anyone knows where i can find a tutorial for this please direct me to it if not if you could make one for me to download please be so kind to helping me out.


THank you all in advanced for ever opening this thread

View Replies !    View Related
Click-drag-Image In SWF
Greetings,

Does anyone know of a tutorial or know how to load, say a 600 x 600 image into a 200 x 200 SWF and be able to click and drag to move the image around to see other parts? How about a scaling feature so the image could be reduced or enlarged?

View Replies !    View Related
Double Click And Drag
I have an object that I drag on the page.
The same object I would like to double click to play sound file and load movie.

Is this possible?

View Replies !    View Related
Click And Drag Is Not Working?
Please help me find the reason why this click and drag function is not working.
Thanks
Ecinele

View Replies !    View Related
[F8] Click-drag Dial
Hello one and all,

I'm new here and like most new people I have a problem which I'm stuck on.

I have created a Flash interface and on the interface is a dial. This dial has five stages of rotation which point at five different navigation items. I want to be able to make it so that when I click and drag the dial, it cycles through these five stages and on release at each stage goes to a different frame.

I have created dials that rotate all the way round, but I want this to simply snap between the five options.

I am very new to Actionscript and I would appreciate any help that anyone could give me

View Replies !    View Related
[F8] Click And Drag Limitations
So I have been given a map that was created in Flash that I can click and drag as well as zoom, however, I discovered that I can drag beyond the size of the map. How can I restrict the dragging of the edges to not exceed the image itself?

FLA file is here

Thanks in advance.

View Replies !    View Related
[CS3] [AS2.0] Click And Drag But Changing The Mc
I was hoping that someone could explain to me how I could get the click and drag functions to work but when a person clicks it changes the movie clip to something else. I've tried using gotoAndStop() but when I use that it'll drag the movie clip but then it refuses to let go like it doesn't acknowledge the onRelease or something. I can think of a longer way (much longer) to try but I was hoping that it was just something simple that I maybe overlooking. Thanks.

View Replies !    View Related
Drag Drop And Click
Hi, everybody.
This is my first question around here. thx for any hints.

Is there a way NOT to trigger mouseevent.click doing a drag and drop ?

In other words :
// add event Listener
mymc.addEventListener(MouseEvent.MOUSE_DOWN, onStartDrag);
mymc.addEventListener(MouseEvent.MOUSE_UP, onStopDrag);
mymc.addEventListener(MouseEvent.CLICK, myFunction);

/*whenevver I drag, myFunction triggers (I understand that since when I drag, I click..., but how to AVOID that ?...*/

function onStartDrag(event:MouseEvent):void {
event.target.startDrag();
}
function onStopDrag(event:MouseEvent):void {
event.target.stopDrag();
}

View Replies !    View Related
Mouse Click And Drag
Hello friends,

I have a question. I have an object that I would like user’s to be able to click on and move. As the object is moved it will generate numbers.

The part I need help with is how to make the object movable by users. Kind of a mouse click and drag operation. The object is only going to move along the X axis.

If anyone has an idea how I can do this, I would be very grateful for the assistance. Many thanks in advance for your help and your time.

View Replies !    View Related
Double Click And Drag
I have an object that I drag on the page.
The same object I would like to double click to play sound file and load movie.

Is this possible?

View Replies !    View Related
Click-drag-stretch
hi there,

I'm looking for an option to click a mc in the bottom-right-corner. When dragging the mc scales/stretches bigger or smaller depending of the position of the mouse.

any suggestions?
i tried to find a tutorial but couldn't find any....

thanks in advance

View Replies !    View Related
Click Or Drag // Menus ?
Now here is a question that will get some varied results

Who prefers to CLICK & who prefers to DRAG when opening MENUS?

For example, if I was to open a MENU titled CONTACT. In order to see its CONTENTS would you prefer to DRAG out the CONTENTS or CLICK a BUTTON and watch the CONTENTS come out?

You can probably see where this is going, I am really curious to see what ppls preferences are

View Replies !    View Related
Click And Drag Question
Sorry, this is kind of a stupid question. . .

if you only want to have one of a MC show, but if someone starts to drag that, it duplicates so when it statts to move, it looks like there is anotherone right under it. Also, how do you put a limit on how many there can duplicate?

View Replies !    View Related
Click And Drag (sticking)
Hi-

I am creating a zoom feature, where you click and a larger image is targeted into a box (external swf). The image has a click and drag fuction applied to it. The only problem is that when you move the cursor off the swf, the image seems to stick and keeps moving around. Is there a way to stop the drag function when you move off the swf(out of the box)?

Any help would be appreciated.

Thanks.

View Replies !    View Related
How Do We Click And Drag An Image?
I have a panoramic image that is too big for the page, but it would be a nice effect if I could enable click and drag to scroll thru this long image left and right. Can some one give me a clue where to start with this? Much appreciated!
thanks

View Replies !    View Related
Double Click And Drag
I have an object that I drag on the page.
The same object I would like to double click to play sound file and load movie.

Is this possible?

View Replies !    View Related
Right Click Drag/Drop
Code:
square_mc.addEventListener(MouseEvent.MOUSE_DOWN, pickUp);
square_mc.addEventListener(MouseEvent.MOUSE_UP, dropIt);

function pickUp(event:MouseEvent):void {
event.target.startDrag(true);
}
function dropIt(event:MouseEvent):void {
event.target.stopDrag();
}
square_mc.buttonMode = true;
I am using this code to do a basic Drag/Drop on a movieclip. Is there anyway that I can change the MouseEvent's so that it would work with RIGHT CLICK? Basically I need it so that when the user holds down RIGHT CLICK it drags and when it's released, it drops.

I've looked through some documentation and apparently AIR has these properties, but flash does not?

Thanks.

View Replies !    View Related
Click N Drag, Weird
hi, i have a problem with click n drag tutorial. i followed the tutorial and i test the movie and it looks weird.

when i click on the circle, it follow my mouse moving around. the problem is i cant click it back, and stop to drag it.

in the button(circle) i put the script:

on (press) {
startDrag(this,true, x1, y1, x2, y2); // ???
}

on (release) {
stopDrag()
}

i tried to soft it and i cant. can someone guide me pls!!

and i also tried to do a click n drag menu. and it failed. =(

can someone pls teach me how to do a click n drag menu??

thanks

View Replies !    View Related
Click And Drag Masked Layer
I'm trying to learn how to use masked layers and I'm making a little spotlight effect. I can do that just fine, but how can I make it so that the spotlight can be clicked and dragged, or better yet so that it follows the mouse around?

I don't know why but the normal movie clip with the button in it that has the action to click and drag doesn't work at all when on the mask layer.

Thanx

View Replies !    View Related
MX04 And Alt + Click & Drag A Keyframe
Up to the MX version, if you ALT+Clk and dragged on a keyframe it would allow you move the keyframe right or left. The advantage over just clicking and dragging was it didn't leave regular frames behind when you shortened a timeline.
I just upgraded to MX04 and it seems to have changed that command to a "copy" frame command. The HELP documentation is completely unhelpful because it lists Alt+Clk&drag as doing BOTH moving and copying a frame at the same time. I know this is a kinda petty, but I used that command alot! Any suggestions as to why the confusion?
Thanks
DB

View Replies !    View Related
Click'n'drag 'smudge' Effect?
Howdy everyone,

I was wondering if there is anyone out there that knew if there is a way to make a type of 'smudge' tool (a la Photoshop), but in Flash. I've checked in Movies>Effects and have done a search under 'smudge' and 'blur', but with no success.

What I had in mind was to have just a single/simple/non-animated image, that users can click'n'drag on, to smudge the picture, and when they've smudged themselves silly, they can press a simple 'refresh' or 'start again' button.

Any help or nudge in the right direction will be greatly appreciated.

Take it easy,

Asparagus

View Replies !    View Related
Click And Drag Scroll Not Working
Hello all,

I am uploading an example of this problem...

I found a tutorial on how to make a click and drag scroll. I built my elements on top of the origonal movie's to figure out how it works. It works fantatically UNTIL I out in inside a movie clip on my main timeline. Can anyone tell me why it won't work? I know it's something little.... it always is.

Thanks,
jessicuh

View Replies !    View Related
Dragbox With Specified Area For Click And Drag
I have a mc that loads in my movie, it is basicly emulating a pop-up window. I want to be able to specify a area on the mc for the user can click on and drag the mc. Right now i have a box that i can drag, but the whole mc can be clicked and draged. I need to be able to specify the area that should be clicked.

This is thew current code i am using:

Code:
this.contactBox_mc.onPress = function() {
this.startDrag();
};
this.contactBox_mc.onRelease = function() {
this.stopDrag();
};

View Replies !    View Related
Help Needed On Click-and-drag File
I have a very simple click and drag toy I made on my site, which is a terribly simple attempt at the prinicple used on www.flashcan.com:

http://www.jimpix.co.uk/flash/default.asp?ID=11&catid=6

This works by having a number of m/cs on the stage. Each time I click on one of the clips, which contain a button, this is called:

on (press) {
startDrag("/part", false, 10, 75, 540, 380);
}
on (release) {
stopDrag();
setProperty("/part", _name, "");
setProperty("", _name, "part");
}

This does two things:

1. Allows me to drag the clip when pressing down
2. Renames any existing instance called "part" to nothing, and renames the instance I have clicked on to "part"

Then there are sliders to control width, height, rotation and alpha of the selected instance.

On the first keyframe of the main movie, this is used:

screenwidth = "550";
setProperty("/part", _alpha, getProperty("/alpha", _x)*(150/screenwidth));
setProperty("/part", _rotation, getProperty("/rot", _x)*(500/screenwidth));
setProperty("/part", _xscale, getProperty("/x_sc", _x)*(500/screenwidth));
setProperty("/part", _yscale, getProperty("/y_sc", _x)*(500/screenwidth));

so that the _x position of the sliders is used to control the properties of whatever instance is called "part" at the current time.

I would like to improve this, because the problem with it is that if I click on say, the hat, make it big, rotate it a bit, and change the alpha setting on it, and then click on another instance, that gets renamed to "part" and also takes on the _xscale, _yscale, rot and alpha of the previous item I clicked on.

What would be really great would be to find a way to control things so that if I clicked on any instance, I could find a way to work out the properties of that item and reset the properties sliders back to whatever they should be for that item.

I have tried doing that, but because this is a two frame movie, which loops around, it just goes nowhere, and any resets are dependent on the user clicking on the instance to reset the control bars. Therefore, I can move the hat to the edge of the screen, release the mouse button, and then on clicking again, the hat moves back again to the original position, since this resets the control bars back to the start, and the hats position is taken from the _x of the control bars!!!

Any help greatly appreciated, or links etc. to any open source better versions of this theory which anyone may know of.

Thanks

Jim

View Replies !    View Related
Click And Drag An Image In Window
Greetings,

I am looking for a way (or a tutorial) that will let me load and external photo into an SWF and then have the ability to click-n-drag the image within the SWF frame. An additional feature might be the ability to zoom into the photo or zoom out but still be able to drag the image around.

For example:
Let's say there is an SWF that measures 200 x 200 pixels. It loads a photo into it's window and the photo is 600 x 600. The photo is loaded so it fits into the image area. The user clicks a "+" button to zoom into the image and then click-drags the image so to get a better look at some of the area's that are now being obscure on the outside of the viewable area.

Can it or something similar be done?

View Replies !    View Related
Double Click And Drag/drop Help
Hi, using Flash MX Pro 2004 i am having difficulties with the following action scripting. I modified this action script which i originally pulled from a tutorial. It is a simple double-click script. The script works fine. However i am trying to add a drag and drop feature to it. So pretty much i am workin on the movie clip "mcSnake", when the user double clicks t it toggles frames within the mcSnake. that works fine. I also want it so that the user can also drag mcSnake. The problem is that i can only get it to either double click or drag and drop, but not both, as if they keep canceling each other out. Is anyone able to help me with this script and be able to double click and drag and drop?

My aim is: endf1 if you'd like to IM me



Code:
//set initial variables
click = false;
//function for the button press
mcSnake.onPress = function() {
//if this is the first click
if (!click) {
timer = getTimer()/1000;
_root.click = true;
//find out if it is a double click
} else {
timer2 = getTimer()/1000;
_root.test2 = timer2-timer;
//if it is a double click
if ((timer2-timer)<.25) {
//toggle frames
this.play();
} else {
timer = getTimer()/1000;
_root.click = true;
}
}
};

View Replies !    View Related
[MX] Click 'N' Drag Virtual Magazine
Im just wondering if anybody can send me the code to create a virtual flash magazine as seen on the site below....As in, your able to "virtually" turn the pages with the click 'n' drag of a mouse. The finished product dosen't necessarily have to be as quite as advanced as the example seen on this site, however I wouldn't mind if it was.

Could somebody please send me some code or detailed instructions on how to produce something like this...keep in mind though, my flash scripting skills are only basic to intermediate so please explain yourself as simply as possible so I can understand what your talking about. Either that or paste in some code that I can simply just copy and paste into my project. Any help would be great.

Cheers, Dallas.

http://www.woodentoymagazine.com/index2.html

Instructions: Click and drag the animated drawing in the top right hand corner of the interface. Thats the virtual magazine. Keep doing this until pages run out.

View Replies !    View Related
Shift + Click + Drag Problem
I have a custom list ui where the user can select multiple items in the list by holding down shift and clicking. The user can then drag the selection in mass over a 'duplicate' or 'delete' button and release the mouse.

The problem is if ANY KEY is held down while dragging, any movie clip dragged over will fire its onRelease event repeatedly. Is this normal behavior or should I look more closely for a bug in my code? If this is 'normal' is there any workaround? Thanks for any help.

I'm using Flash MX 2004, publishing AS 2.0 and Flash 7.

View Replies !    View Related
Drag And Drop; Click To Move;
how would i do this for a 2 view and have gravity...
so i can grab my character and drag him across the room and drop him and he will fall to the ground.. like interactive buddy.. except it doesnt move by itself.. you click to a spot and he will move..

View Replies !    View Related
Stopping User Drag Or Click ?
If I have a game and there is a count down process before the game start, what script should I use for stopping user drag or click before the game start?

any one have ideaS?

View Replies !    View Related
Button Click While Using Drag And Drop
hi
I have a movie clip containing picture and buttons over it.I want to move the entire mc using drag and drop.While doing this the buttons are not working,can anybody help me out?

View Replies !    View Related
9 Slice Scaling: Click And Drag
Does anyone know how to use 9-slice scaling when you click and drag? I want to make a resizable UI window with a bottom right click and drag area. Can I define another center for the movieclip so it scales like a OS window?

Thanks

dV

View Replies !    View Related
Copyright © 2005-08 www.BigResource.com, All rights reserved