ActionScript 2.0 :: Move Point Around Circle?
Feb 4, 2009how can me move point arrount circle
just i want the point that you press on it and move it arrount the circle
how can me move point arrount circle
just i want the point that you press on it and move it arrount the circle
How can I move a point (or circle) slowly and the point let behind a line.When the point turn back the line will be erase.
View 8 RepliesI am trying to get a circle to move across from one horizontal point to another. I want this to circle to repeat itself after a certain amount of time but for the previous circle to carry on moving. I also want the circle to appear at different vertical points.
[Code]..
It's the beginning of a Monkey Island / Grisworld The Goblin kind of ultra short and simple game. Actually this is the only think I have to figure out.
Actually it already works if you click the x where it's positioned on the screenshot, but it doesn't work other places. And yes I've tried everything, and I'm just nok smart enough to figure this out.
More precisely it's the alternative path, after the arrow collides with the circle, that's causing me problems - since it's going to find it's way to the point clicked on stage.
I want to create circle, and put 8 points on it. So, user can drag each point in order to change it's shape.
Is there any way to do this in flash?
I have some following code:
Ref. - How to draw a continuous curved line from 3 given points at a time
package{import flash.display.Sprite;
import flash.events.MouseEvent;
import flash.geom.Point;
[Code].....
So, can anyone convert these three point curve line to 8 points circle?
It's been a long time since I've done any work with actionscript, and alas I've forgotten nearly everything. I've tried to look for a tutorial that would explain basic animation with actionscript, but the one that I found on Kirupa was no longer there.
Basically I'd like to do this:On the stage I have a movieclip and I'd like the movieclip to move along the x-axis to a certain point and then back to the starting point again. The moving speed of the movieclip should also be adjustable.
how to use these in order to make an object move from point A to point B in an arc.Think of that classic game where you have to input the angle and power and try to hit your opponent.
View 1 RepliesBasically what I like to ask is how to move a object from one point to another point based on the point tat you have clicked on a graph. For example, If I click on this coordinate (2,3) on graph, the object (movie clip) will move to that point.
View 3 RepliesI have a circle (bounding circle) offset from the centre point of my entity and I'm looking on how to move that circle around the entity as it rotates so that it's always in the same spot of the character.For example,say I have a bounding circle for the front of a car, when the car turns, that bounding circle needs to turn to So I have two points: position which is the position of the entity's centre point and offset which is the offset of the circle from that position. This assumes an angle of 0.
So if my car is facing 0 degrees: position (150, 150) and offset (50, 0) then the bounding circle would be at 200, 150.Now if I rotated the car 90 degrees, the bounding circle should be at position 150, 200.This is what I have now:
var differenceX : Number = _centre.x - _offset.x;
var differenceY : Number = _centre.y - _offset.y;
var rotatedX : Number = differenceX * Math.cos(_angle);[code]........But it's giving me these long ovals and now a perfect circle.
I want to add point to curve when i click on the curve ,make sure the Original point not change ,eg. a Original point is a control point after add it is Still a control point ,so,may be it is need add two point at the same time
View 3 RepliesWhat I'm trying to do is make a dial-type of interface, where you click on a point on the edge of a circle and that point will rotate to another point at the top of the circle. What I can't figure out is how the make "Point B" rotate to "Point A", where "Point A" is always fixed at the top of the circle and "Point B" (and Point C and Point D, etc...) are located along different points on the edge of the circle. I'm using the tween function to rotate, so what I need to figure out is how to get the difference in the rotation between the two points.
View 7 RepliesI am trying to rotate some points around the center of the circle(0,0), however I'm getting weird values from the output. I've commented the problem code..
Code:
var r:Number = 10;//radius
var y:Number;
var x:Number;
var a:Number = 90;//angle of which the semi-circle is facing.. could be a random angle.
var ax:Number;//rotated points
[Code] .....
I am using the semicircle in BitmapData collision checking with getPixel(), with a moving circle...
if i move the cursor to a point A, it automatically moves by itself to a point B. then if i move the cursor from B to a point C, it bounces away to a point D. i stumbled upon this site while googling around. i'm not a techie, but yeah, i can handle word processors.
View 5 RepliesI have two circles, an inner circle and an outter circle. I'm trying to find points that reside within the area between the edge of the inner circle and the edge of the outer circle.
View 1 RepliesHow to find out different circle's center point of a bitmap?
just like photo above, how can i locate the 2 center points of circles?
i only know using .getColorBoundsRect to get a point, but this only apply to one circle, in fact i wanna get different points according to the bitmap.
How to make a point rotate about the circumference of a circle upon dragging. How do I go about doing it? Is there something to do with the
startDrag(...); ?
From what I have right now, I can move the point but not on the circumference of the circle.
I posted a while back looking for a function to make one movieClip circle around a fixed point. The solution I was given (which has worked perfectly up until now) is:[code]This function is called repeatedly by a Timer (loopTimer) with delay 10.The problem I have hit now though, is that if I want to modify or reverse the speed of rotation at any point it causes a jump in position (because I am setting the x and y values directly, rather than incrementing them e.g. "x = ..." rather than "x += ..."). Can anyone see a way to modify this function so that I can just increment the x/y positions?
View 5 RepliesI'm drawing a 3D pie chart that is calculated with in 3D vectors, projected to 2D vectors and then drawn on a Graphics object. I want to calculate the most left and right point of the circle after projected in 2d. (So not 0 and 1 Pi!) The method to create a vector, draw and project to a 2d vector are below. Anyone knows the answer?
[Code]...
We have a flex app that will typically run for long periods of time (could be days or weeks). When I came in this morning I noticed that the app had stopped running and a white exclamation point in a gray circle was in the center of the app. I found a post about it on the Adobe forums, but no one seems to know exactly what the symbol means so I thought I'd reach out to the SO community.[URL]..
View 3 RepliesThis should be easy, but I can't find a good way to make an Engine and a couple of Illustrated cars circle around the inside of a snow globe. I'm using Flash CS4 but am not familiar enough with the bones tool or 3d to get it to look rightpoint me in the right direction. This is kind of important. I'll even do frame by frame animation...I feel a little more in control.
View 1 RepliesI need the pink square to travel from one circle to another when a circle is clicked. However, I only want the square to be able to travel to circles that are right next to it (no travelling across circles).
View 1 RepliesI have a square that is a button symbol. There is a cirlce that is a movie clip symbol. I assigned the following actions to the button
on (keyPress "Left") {
currentX = this._x;
this._x = currentX - 2;[code].........
For some reason, the square and the circle both move. how can i just make the block move and not the circle.
note: the <> symbols are not put surroundin the key names
I want to make an editor like this site. [URL] If you browse this link you will find "Button. If you press this button you will navigate to a editor to design your layout. After draw a rectangle or circle or line you can resize that or can rotate that. When you finish if press the "you will back to the previous page where your desinged layout display. If you press the "" again then you will navigate the editor with the previously designed layout. I want to make a site like this. I want to use the flash cs4 to make the editor. Anybody knows how to draw a rectangle or circle shape with mouse and how to scale by setting the point and how to rotate by setting the rotation point also by using flash cs4 and as3?.
View 3 RepliesDoes anybody know how to make an object moving in a smooth circle?
View 9 RepliesI need to build an animation. Some pictures must move around an imaginary circle and react on mouse events. What i mean is that images must move to left or right depending on mouse position.However, the mouse events issue is not the problem. The problem is that i have no clue about how can i build the animation of the pictures.The animation what i'm talking about is something like that found on URL...
View 2 RepliesThis should be a bit of simple geometry: How do I calculate the points to draw the lines in the code below so that it makes a 2D cone or wedge shape?
import flash.geom.Point;
//draw circle
var mc=new Sprite()[code]...........
UPDATE:I should have mentioned my aim is not to draw a wedge shape, but to draw a line from a random point to the edge of an existing circle.If you're more comfortable with algebra than actionscript,
I am trying to figure out a way to randomly move a ball inside a bigger circle. The motion has to be smooth and completely random.
View 3 Replieswhat i am trying to do is make a circle turn and act like a wheel... what code would i use to make a circle turn and move in the direction it is turning while on the ground?
View 12 Repliesso at the moment i have this in my maze game...[URL] i want it so i can move the circle with my arrow keys, which i can do and then when it hits the walls it makes them go back to the losing screen however i have tried but i cant seem to get it to work. i know maze games are newby but i am new =]
View 2 RepliesSo let's begin. I want to build a wheel which you can spin, similar to a roulette wheel. You can do this both ways (CW and CCW, this issue causing the bug, actually). The wheel has some acceleration to it too, and I achieve this by measuring the start and final angle of the drag movement, using Math.atan2(dy, dx). The problem is the following: atan2 outputs the following angle scheme, assuming the point relative to which the math is done is in the center of the circle.
atan2 returns a value measured in radians, so I'm using the classic angle*180/Math.PI formula. I've changed this original scheme into the following, using some simple math to shift the angles a bit, to resemble more accurate circle angles (going up to 360 degrees) The problem that I'm facing at the moment is should the user decide he wants to swipe clockwise, and moves through the right point, where 0 turns into 360 or 180 turns into -180, the whole angle difference thing is capsized. It registers a CCW movement (as if the user swiped his mouse all around the circle). So, I'm looking for some ideas as to how I can work around this small issue.