ActionScript 2.0 :: The Square And The Circle Both Move?

Jul 27, 2003

I 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

View 1 Replies


Similar Posts:


ActionScript 3.0 :: When A Circle Hits A Square

Oct 15, 2009

i would like to know when a circle hits a square.Following code returns true when the rectangle of the MovieClip (blue) hits the square and not the circle itself:

circle.hitTestObject(square);

In as2 you had an extra parameter to indicate that.

View 3 Replies

ActionScript 2.0 :: Square 1 + Triangle 1 + Circle 1 = Movie 1 ?

Jan 30, 2009

I want to build a specifik thing in flash, and don't really know where to start.... Say I have:

3 images of 3 three different squares

3 images of 3 three different triangles

3 images of 3 three different circles

The first thing you see is Square 1, Triangle 1 and Circle 1. If you were to click on Choose Square, Square 2 will appare in Square 1s place. If you click on it one more time, Square 3 will appare, and then round again to Square 1. Same thing for all the shapes.When you're satisfied with your selection of shapes you click OK and then you get to see a movie, based on whatever choices you've made. Because there are 3 different shapes and 3 different objects within each category, there will be 9 different movies to watch (3x3=9).One example of how this could turn out is:

Square 1 + Triangle 1 + Circle 1 = Movie 1

Another one could be

Square 2 + Triangle 2 + Circle 2 = Movie 6

View 10 Replies

ActionScript 3.0 :: Square Object In The Middle Of Circle?

May 28, 2010

I have a square object in the middle of circle.and i can move square object using up, down, left, riht arrow keys. I need script for when square object touches circle, then it goes to back, I have use for this below code :

var myobjdim:Array=new Array;[code].....

In above code "myobjdim" is square object and "bg1" is circle object..

View 1 Replies

ActionScript 2.0 :: Circle Stop Moving At Obstacle (Square)

Jul 10, 2009

I have a circle and a big square. The circle can be moved using the keyboard. I want the square to act as an obstacle, so the circle cannot be moved into it and the circle stops when it hits it, just like a if i were to try to walk into a building. Is there an easy way to do this?

View 7 Replies

ActionScript 2.0 :: Draw A Square/circle/anything One Pixel At A Time?

Jul 27, 2005

how to draw a square/circle/anything one pixel at a time, using Actionscript instead of tweens?

View 1 Replies

ActionScript 2.0 :: Moving Circle To X Position When User Click On Square

Jun 18, 2008

I have a circle and a square on the stage. When you click on the square the circle will go to "circle._x = 300" when the circle is at 300 I want to make it when you click on the square the circle will go "circle._x = 45"

Code:
moveCircle = function () {
circle._x = 300;
if (circle._x >= 300) {
circle._x = 45;
}} square.onRelease = function() {
moveCircle();
trace(circle._x + "is the position of the circle");
}

View 5 Replies

ActionScript 2.0 :: Motion Method - Take A Circle And Place It In The Center Of A Square Scene

Aug 15, 2003

-Take a circle and place it in the center of a square scene.

-Make a rectangle and snap its left edge to the circle's center.

-Make another rectangle and snap its left edge to the right edge of the first rectangle.

How would you make it so movement doesn't happen at the registration point but on the whole arm. Say i ran a rotation script on the upper arm with +=1 and the lower arm with +=2. How would you place the parts, what format would they be converted to and what would the script format be. Multiple methods would be welcome of course!

View 1 Replies

ActionScript 2.0 :: Movieclip Move In Drawn Square?

Oct 7, 2009

How would it be possible if draw a square, then put movieclip to move in it. It would move when rotate another movieclip..

View 0 Replies

How To Make A Trainset Move In A Circle

Nov 16, 2010

This 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 Replies

ActionScript 3.0 :: Make A Box Move From One Circle To Another?

Feb 27, 2009

I 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 Replies

ActionScript 2.0 :: Move Point Around Circle?

Feb 4, 2009

how can me move point arrount circle

just i want the point that you press on it and move it arrount the circle

View 0 Replies

ActionScript 2.0 :: Make An Object Move In A Circle?

Apr 14, 2004

Does anybody know how to make an object moving in a smooth circle?

View 9 Replies

Professional :: Images That Move Around An Imaginary Circle

Jan 18, 2010

I 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 Replies

ActionScript 2.0 :: Get A Circle To Move Across From One Horizontal Point To Another

Jan 1, 2011

I 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]..

View 1 Replies

ActionScript 3.0 :: Move Movieclip Around A Circle Using Point And Click?

May 5, 2011

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.

View 1 Replies

Randomly Move A Ball Inside A Bigger Circle?

May 26, 2009

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 Replies

ActionScript 3.0 :: Make A Circle Turn And Move In The Direction?

Oct 15, 2010

what 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 Replies

ActionScript 1/2 :: Obstacles - Move The Circle With Arrow Keys

Jun 26, 2011

so 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 Replies

ActionScript 2.0 :: When Creating A Dynamic Square With The Api - Won't Drawing Api Square Object

Dec 2, 2010

when creating a dynamic square with the api. 400 by 400. I am not sure why it wont draw the object

[Code]...

View 2 Replies

IDE :: Random Movement - Randomly Move A Ball Inside A Bigger Circle

May 26, 2009

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 1 Replies

ActionScript 2.0 :: Have An Enemy Square That Chases The Player Square?

Jan 15, 2010

I have this game, and some levels have a moving square as the player, you move the square with your arrow keys.... I want to have an enemy square that chases the player square.... They only chased mario when you didn't look at them? Kinda like that...... but in this regards:

I only want the enemy square to chase the player square when the player square moves.... soo say the player square moves 5 pixels per movement (know how to do all that), I want the enemy square to move when the player square moves..... towards the player square at like 7 pixels per movement..... so eventually you won't be able to avoid the enemy square....

View 4 Replies

ActionScript 2.0 :: Move A Point (or Circle) Slowly And The Point Let Behind A Line?

May 3, 2006

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 Replies

ActionScript 2.0 :: Calculate The Direction And Speed A Circle Has After Colliding With A Static (non-moving) Circle?

Mar 8, 2005

I'm developing a game atm, and I need some help on the mathematics/coding of colliding circles (and their change in x/y speed). What i need to know is how to calculate the direction and speed a circle has after colliding with a static (non-moving) circle. I know how to detect a collision between the two, but I'm not sure about the maths I need to give the circle the right speed and direction after the collision

If i do know how far away the two circle-points (in the middle of each) are to each other (in both x and y coords) would it be easy for me to find the new speed and direction of the large circle in the example above? I know that I somehow should use the angles to pretend the circle hits a flat "wall" (as it only hits one point), and then calculate the new speed/direction. My only problem is that I'm not sure how to decide the angle of this flat "wall" and how x and y speeds should change when colliding with a wall that is angled. Does anyone here have any insight, links or tips on how I can du this?

View 6 Replies

ActionScript 2.0 :: Make One Circle Follow The Mouse Cursor Inside Another Circle

Sep 30, 2005

i want to make one circle follow the mouse cursor, inside another circle. Similar to an eye looking at the cursor. Ive attached an example.

View 4 Replies

ActionScript 2.0 :: If Statement / Variable - Say If Circle Shows Up Change It To Circle (french)

Nov 5, 2008

I have text in a dynamic field showing up as circle. I want to say if circle shows up change it to cercle (french).

[Code]...

View 1 Replies

ActionScript 2.0 :: Calculate Direction And Speed Circle Has After Colliding With A Static Circle?

Mar 8, 2005

What i need to know is how to calculate the direction and speed a circle has after colliding with a static (non-moving) circle. I know how to detect a collision between the two, but I'm not sure about the maths I need to give the circle the right speed and direction after the collision.If i do know how far away the two circle-points (in the middle of each) are to each other (in both x and y coords) would it be easy for me to find the new speed and direction of the large circle in the example above? I know that I somehow should use the angles to pretend the circle hits a flat "wall" (as it only hits one point), and then calculate the new speed/direction. My only problem is that I'm not sure how to decide the angle of this flat "wall" and how x and y speeds should change when colliding with a wall that is angled.

View 6 Replies

ActionScript 3.0 :: Graphics - Paint (change Color) Inside Of Circle When A User Draw A Circle

Aug 24, 2009

I`m working on a app that you can draw lines.....like circles, rectangles... my problem is when a user draw a circle for example....i wanna be able to paint (change color) inside of this circle. I`ve tried working on Shapes with cacheAsBitmap = true and Bitmaps with BitmapData but it doesn`t seens to work.

View 4 Replies

Actionscript 3 :: Change Shape Of Circle By Dragging Point On Circle

Mar 16, 2012

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?

View 1 Replies

ActionScript 2.0 :: Drawing A Circle - Circle Diameter Has To Be Controlled By A Button

Oct 6, 2009

I have to draw a circle using action script. The Circle Diameter has to be controlled by a button.

View 0 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved