USERNAME:
PASSWORD:
Save Info!
Logging in…
This topic is 1 page long.
[ Profile | Posts | Contact ]
Posted at: 6/7/06 07:35 PM
Sign-Up: 04/10/05
Posts: 46
My flash is a cocklicking peice of... well.... why wont this work: i have a dynamic text, with number 0 and var "redb". then i have a movieclip, with a frame with this code: _root.redb +=10
But when i start the movie, it just says 10 then 1010 then 101010... i want it to say 10-20-30...
when i have the dynamic at 10 and the code in the movieclip at _root.redb -= 1 , it says NaN.. WTF help me plz!
Posted at: 6/7/06 07:38 PM
Sign-Up: 01/07/04
Posts: 4,903
I think its reading your redb variable as a string, thats why it concatenates the 10 on every time.
where you define it , use
var redb:Number = 0;
tell me if it still doesnt work.
Posted at: 6/7/06 07:39 PM
Sign-Up: 09/27/05
Posts: 4,103
try adding redb = 0 on the main timeline.
Click sig for "The Cell 2" Production Blog.
Posted at: 6/7/06 07:40 PM
it still doesn't work. the number is at 0. the code is now _root.main += 1 (i changed var) but it still says 0 then 01 then 011 and so on...
Posted at: 6/7/06 07:45 PM
At 6/7/06 07:40 PM, Regone wrote: it still doesn't work. the number is at 0. the code is now _root.main += 1 (i changed var) but it still says 0 then 01 then 011 and so on...
change +=1 to ++;
Posted at: 6/7/06 07:46 PM
i did now, but then it says NaN :S
Posted at: 6/7/06 08:54 PM
Sign-Up: 07/02/04
Posts: 1,247
_root.redb = _root.redb + 10;
Posted at: 6/26/06 01:07 PM
Sign-Up: 06/06/05
Posts: 2,824
on first frame add: _root.main = 0; _root.main += 1;
On second frame add: _root.main += 1;
on third frame add: gotoAndPlay(2);
Then it will count as hell!
Add my Xbox Live Gamertag: Macintawtsh Mah new ride! :D
Posted at: 6/26/06 01:09 PM
And can you please remove Lopas1 from you're sig... someone might think you're in love!!LOL
maybe YOU (NOT ME) are...
Posted at: 6/26/06 01:11 PM
Sign-Up: 12/04/04
Posts: 3,145
_root.createTextBox("redb", _root.getNextHighestDepth(), 5, 5, 50, 22); _root.onMouseDown(){ _root.redb += 10; }
there ya go
Snubby Land | Cartoons | Games | Comics | Videos
Posted at: 6/26/06 01:12 PM
At 6/26/06 01:11 PM, Snubby wrote:
_root.createTextBox("redb", _root.getNextHighestDepth(), 5, 5, 50, 22); _root.onMouseDown = function(){ _root.redb += 10; }
BAAAH!!!
Posted at: 6/26/06 01:13 PM
Sign-Up: 12/11/04
Posts: 12,766
_root.main = Number(_root.main)+1;
File Uploader (fla, swf, jpg, gif, bmp).
Posted at: 6/26/06 01:30 PM
Sign-Up: 11/05/05
Posts: 2,272
Have your variable and then -(-10);
10 is just an example, but by doing -(-Number), it will add the number.
AlCIAeda.com - The World's Most Profitable Terrorist Organisation
All times are Eastern Standard Time (GMT -5) | Current Time: 07:54 AM
<< Back