ActionScript 2.0 :: FMX: Cannot -= _x Value Past Zero With Small Numbers?

Jul 7, 2004

I am having a little trouble understanding why my code is not functioning. It works if I subtract and combine numbers above .1 but if I use a number below .1 the _x and _y values stop at 0. I would like the _x and _y values to go into the negative. I am using Flash MX.

function movePastCorner(mc){
mc._x = 2;
mc._y = 2;

[code]......

View 2 Replies


Similar Posts:


ActionScript 3.0 :: When Use Small Numbers The Dynamic Text Box Displays NaN

Jan 11, 2011

im trying to do a simple calculation and display it in a dynamic text box however when I use small numbers the dynamic text box displays NaN.

PHP Code:

lambdas = rk / lp;
lambdas.toString();
test_txt.text = String(lambdas);

lambdas is is the variable i am trying to display in the dynamic text box (instance name is test_txt). rk and lp are input text numbers. I am trying to use rk = 0.05 and lp = 0.2. 0.25 should be displayed in the box

View 3 Replies

ActionScript 1/2 :: Cannot Get Scroll To Go Past

Jul 22, 2010

I have an fla that has a scroll which is large, 4591.60 is there a limit where flash will scroll and then stop? I did not create the file but I cannot get the scroll to go past where it is now as there is more to the scroll.

View 1 Replies

ActionScript 2.0 :: Generate A Variable Number Of Random Numbers Less Than 16 With No Duplicate Numbers

Nov 2, 2004

how to do this and not found much, so here goes:

I want to generate a variable number of random numbers less than 16 with no duplicate numbers

Ive posted the fla, and what i'm doing is generating a random number and putting it into an array then using a for loop to cycle through the array for each new random number to check if its already there. if it is, then i want to regenerate that number.

if you test the fla you'll see that all i get in my array is some lovely zero's and i sort of know why this is, but don't know how to stop it.

View 3 Replies

ActionScript 3.0 :: AIR Handling Large Numbers - Convert A String Having Numbers To An Integer

Feb 18, 2010

I am trying to convert a string having numbers to an integer.

//15 9's are there
var str:String="999999999999999"
var res:Number = new Number(str);

But it is not able to convert correctly as the the var res now has the value 100000000000000000. I know that the number has 52 bits of memory, then why is it not able to do the conversion?

View 6 Replies

ActionScript 3.0 :: Generate Four Random Numbers With Total Of 4 Numbers Equal To 100?

Feb 19, 2011

Generate four random numbers with the total of the four numbers equal to100?[code]...

View 8 Replies

ActionScript 2.0 :: Health Bar Keeps Going Past 100 When Healed?

Jul 25, 2009

i have an apple and the character the character can walk over and touch the apple when he touches it he gets 30 random health but then if he health is already 100 the apple will give him 130. ??? is their any way to make it so his health doesnt go past 100

heres the code on the apple

PHP Code:

onClipEvent (enterFrame) {
}
if (this.hitTest(_root.char)) {

[code].......

View 2 Replies

Flex :: End Up Getting A Http 500 Error And Have Not Been Able To Get Past That?

May 24, 2011

I have used wsdl2js to generate the javascript needed to communicate with the service.However I end up getting a http 500 error and have not been able to get past that. I have looked through the provided examples from the Apache CXF download and I have done some searching and cannot find a solid example of creating the javascript client. A lot of examples seem to somehow access the wsdl file at runtime from a server but my javascript is already generated from the CXF tool and I just include the scripts.

Adobe Flex and AS3Another option I have considered is using Adobe Flex. I create a new Mobile Flex project in Flash Builder using the BlackBerry PlayBook SDK and Flex 4.5. However when I use the menu options to connect to a web service I get prompted with "This option is only available for flex projects."Are there any other options out there that provide a solution to this problem? If you need more information just let me know

View 1 Replies

ActionScript 3.0 :: Cs4 Will Not Let Rezise An Image Past 28.8

Sep 23, 2009

i have a movie clip symbol (its just a red square 1x1).

at frame 1 it is just in the centre at 1px x 1 px.

i go to frame 60 ( the end of the movie clip ) and i want 2 resize it quite a bit.

but it WILL NOT let me resize past 28.8 for widht and height.

p.s. if i remove the tween then i can resize it to my hearts content.

View 0 Replies

ActionScript 3.0 :: Movie Not Getting Past The Preloader

Feb 8, 2010

I've got a couple of questions regarding the same project.

1- When you view URL... in IE, you'll notice that it sometimes doesn't go past the preloader. I asked why this happened in an IRC channel, and was told to use swfobject. However, with swfobject, I have the same problem. Is something else the problem?

2- I have the code [code]

View 2 Replies

ActionScript 2.0 :: Getting The Date With Past Days?

May 9, 2010

I've got a number of days from the date to today. Like 1689 days. How can I get from this the date subtraction past days with date?

View 1 Replies

ActionScript 2.0 :: MC Advances Past Its Max Y Position?

Aug 24, 2009

I have a scroller mc that I want to control by clicking underneath its y position to advance it down its y axis by a predetermined amount.The below code works to move it, but it advances past its max value of 496.5 (off the screen).Have I made a mistake in the code below? The scroller mc and associated text block is in their own mc on the root timeline. This code is on a frame on the root timeline.Has it got to do with the relative y positions of the stage compared with the y positions in the actual MC that I am trying to control?

Code:
principals_mc.johnTxt_mc.scrollerZone_mc.onRelease = function () {
var scrollerAmount:Number = 80;
if (this.hitTest(principals_mc.johnTxt_mc.jfscroller_mc)) {[code]......

View 6 Replies

ActionScript 3.0 :: Creating Function To Pick Out Numbers From A Set Of Numbers?

Nov 18, 2009

create a function that picks out X amount of numbers from a set of numbers? So if X=3, then i need this function to pick out 3 different numbers from say a set of numbers (1, 2, 3, 4, 5, 6, 7, 8) and then stored it into X number of variables.

In saying that, X will only =2, and =5. So in the first instance, i'll need 2 random numbers from the set above that are not the same numbers, and second instance 5 random numbers from the set above (also no repeats of numbers). Then i need to be able to store those 2 or 5 different random numbers from the set into variables to call them with other functions.

View 2 Replies

ActionScript 3.0 :: Buttons Don't Work Past First Scene

Aug 17, 2009

in the first frame, first scene. Shouldn't that be where I but the include? (the buttons do work in scene) The buttons that are defined in external.as work in the first scene, but not in the other scenes. When I do an "include" in every scene, I get errors, no buttons work (makes sense....that should throw errors).

[Code]..

View 4 Replies

ActionScript 3.0 :: GotoAndPlay() Doesn't Go Past A Certain Frame?

Apr 27, 2010

gotoAndPlay() is the only actionscript I have in my flash and all I want it to do is go to a frame. If I tell it to go to a frame past a certain one it will not. It always (unless I pick a frame previous to the messed up one) goes to that frame. I have only one scene.

View 10 Replies

ActionScript 3.0 :: Lock The Stage So Cannot See Past Edge?

Feb 7, 2010

my stage is set at 500x400 in flash cs4. I created a rectangle for the background and set the same size as my stage that covers the whole stage but I noticed when I hit ctrl+enter to test the movie clip, it initially looks fine but when I expand the window large, you can see white area all around.

View 3 Replies

ActionScript 2.0 :: Past An URL To A GetURL Without Actually Opening A Window?

Oct 3, 2007

i want to past an URL to a getURL without actually opening a window, this url is a like a tracking tag...

View 1 Replies

IDE :: Press As Past On The Mouse Before Time Runsout?

Apr 3, 2010

i made a small game. the player needs to press as past as he can on the mouse before time runsout.

well, i want to send the score of the player by post (php)

i have read alot of guids but i didn't mannaged to do thise, so i came here.

[Code]...

View 1 Replies

ActionScript 2.0 :: [fmx] Keep Variables Past The Onload Call?

Jan 20, 2004

I've created a multi-framed flash file that's calling multiple variables from an external php (text) file. I'm using an onload command to do this and for some reason the variables seem to "disappear" once I leave the first frame (where the onload and load commands are)I'm figuring that my problem has to do with 'variables scope'. I've read the article on this site but I don't know actionscript well enough to proceed.I ultimately want to do away with using multiple frames by using multidemsional arrays and for...next loops, but this is what I have to work with (for now). I'm going crazy trying to get THIS to work.

[AS]
// ##################################
// FRAME 1

[code]......

View 4 Replies

ActionScript 2.0 :: CS3 Mouse Trailers Extend Past SWF File?

Mar 4, 2009

I'm currently working on a project where I have a mouse trailer in my flash header. It drives me crazy when the effect cuts off when your mouse goes out side of the flash area.

Does anyone know any tricks that I can use so that the effect doesn't cut off? I need to keep it in ActionScript 2.

View 3 Replies

Stop A Rectangle From Going Past An Object After Collision Is Detected?

Oct 11, 2009

Assuming, for a rectangle that is controlled by the user using the arrow keys, that I do the following[code]...

Assuming that works in detecting the collision, what would I use to actually stop the rectangle from progressing through the wall?

View 1 Replies

Quiz Doesn't Go Past The Welcome Page When Test Movie

Oct 21, 2009

I am using a quiz template and have placed video in the first frame. Now the quiz doesn't go past the welcome page when I test movie... I'm sure what I am missing is simple!

View 1 Replies

ActionScript 3.0 :: Clear Browser Cache For Past Hour?

Apr 24, 2010

Been trying to clear browser cache for the past hour, tried almost everything on google and also went Tools>Net options and cleared it. Yet everytime I load the website it shows the old version.

View 1 Replies

ActionScript 2.0 :: Automatic Scrolling If Textbox Past Height

Jan 31, 2007

I am looking for a way to have my content scroll vertically automatically if it is past a certain height.

Code:

var my_format1:TextFormat = new TextFormat();
my_format1.font = "EventFont";
my_format1.size = 50;
my_format1.color = 0xFFFFFF;

[Code]....

View 7 Replies

ActionScript 2.0 :: Pick 6 Random Numbers From 49 Numbers?

Aug 18, 2010

what is the syntax to pick how can i pick 6 random numbers from 49 numbers

View 9 Replies

ActionScript 3.0 :: Generating Random Numbers Between Two Numbers?

Apr 1, 2011

I am generating random numbers between two numbers by the code bellow:

ActionScript Code:
public function randomRange(max:Number, min:Number = 0):Number
{
return Math.round(Math.random() * (1+max - min) + min);
}
trace(randomRange(3,-31));

But I need a code which will return some times '3' and some times '-31'. Not the number between them.

View 2 Replies

ActionScript 3.0 :: Adding Up Odd Numbers From An Array Of Numbers?

Mar 7, 2012

I have been using Actionscript 3.0 in Adobe Flash Builder for a few weeks,and I really like it! Bare with me because I'm not really good at it, yet. Anyway, I was wondering how would I go by adding up odd numbers from an array of numbers? I know how to make all of the numbers add up, but adding only the odd numbers I'm not so sure how to do it.

View 5 Replies

ActionScript 2.0 :: Past A Certain Point It Is Scaled Down In Size And It Locks In To A Specified X And Y Position?

Sep 16, 2009

I have a MC that can be dragged. when it goes past a certain point it is scaled down in size and it locks in to a specified x and y position. The problem is this is causing the onPress function and onRelease function to not work properly. once the mc goes in i cant get it out. this is on the first frame of the timeline

Code:
flatline.onPress = function() {
if (_currentframe == 1) {

[code]....

View 3 Replies

ActionScript 2.0 :: Add A Little Bounce Effect That When Scrolled It Went A Hair Past The Destination

Jan 24, 2006

[Code]...

if i wanted to add a little bounce effect that when scrolled it went a hair past the destination but came back how would that look?

View 5 Replies

ActionScript 2.0 :: SWF Menu Of Past Projects: Change Current Directory?

Sep 10, 2008

I am trying to create a menu in Flash to access different Flash interactives I have created.When a button is clicked it brings up a different Flash project, but I am having problems with it now bring up it's own assets because they are all referenced as if we were in the sub-folder of the current swf.

View 2 Replies







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