Instance Name Wrong ...
hello
I'm trying to dropTarget a MC onto another MC ... both with instance names ... but when i trace(event.target.dropTarget.name); i get a name of "instance 132" .
why is it not using the instance name i setup on the stage ?
ActionScript.org Forums > ActionScript Forums Group > ActionScript 3.0
Posted on: 06-12-2008, 12:54 AM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Wrong Instance Being Dragged
I am trying to have a mc (called "first") that is clickable and have a new instance created and then dragged. The problem is - the orginal mc ("first") keeps dragging instead of the new instance. Here is the code that is within the symbol in the library:
this.onPress = function () {
if(this._name == "first") {
_global.circleNum += 1;
duplicateMovieClip(this,"circle" + _global.circleNum,_global.circleNum);
startDrag(eval("circle" + _global.circleNum));
trace("circle" + _global.circleNum);
} else {
startDrag(this);
trace(this._name);
}
}
this.onRelease = function() {
stopDrag();
}
Something Wrong With These Instance Names ?
Would there be any conflicts with these instance names:
sound_mc
tracks_mc
track1
...the reason I ask is I have problem - and I i have checked my code 20 times and there is NOTHING wrong with it. I have used the code several times before in other projects.
If it isn't the names then I'm lost
Is There Anything Wrong With How I've Made These Instance Names For These MovieClips?
For context, I've created a library item with a linkage name called "livesIcon". I want to place them on the stage sequentially, which was successful. The problem is simply referencing them later on.
code: var livesIcon:MovieClip;
var currentIcon:Object;
var lives:Number = 3;
[...]
for (l = 0; l < lives; l++) {
currentIcon = eval("livesIcon"+l);// creates "livesIcon0", "livesIcon1"..
livesIcon = attachMovie("livesIcon", currentIcon, l+20, {_x:l*50+50, _y:350});
}
At the moment, I have no problems with these Instances appearing where I want them to (mainly because of that last parameter in attachMovie().), but for some reason, the Instance names don't respond when I reference to them either via my currentIcon variable or by their specific names.
For example none of these lines of code seem to do anything to the Instances I just made:
code: livesIcon0._y = 0;
currentIcon._y = 0;
Is there anything wrong in the way I made them?
Instance Names...changing...or Addressing Txt Field Instance Based On Instance Of Mc
i'm creating a mail form, that has a text effect which displays the type of info to be entered in each input box. To create this effect, i had to assign the variable name txt to the input boxes as well as the instance name txtBox. each of these text fields is contained within a movieclip, each with a unique instance name. what i need to do, is somehow assign a value/variable to each text field to pass to PHP to generate an email. I have always used components for contact forms so i'm not sure how to make the switch, AND.. the script i use for my contact form is an EXTERNAL AS file. (i use a customized version of a contact form from www.actionscript-toolbox.com [which apparently is no longer Flash related site])
ok.. this is hard to explain..... so bear with me....
If my original mail form component instance names were: tiName, tiEmail, tiSubject and taMsg (ti for textInput and ta for textArea)
and my current instance names for the mc's which CONTAIN the input boxes (with txtBox textfield instance inside them) are: name_txt, email_txt, subject_txt & comments_txt...
how would i pass/convert the users input text in each movieclip's txtBox, into the original instance name for my mail form so i can continue to use the form/PHP i have been using??
OR....
how do i take the values input by the user in each txtBox (i.e name_txt.txtBox.insertedTextFromUser or name_txt.txt, email_txt.txtBox.insertedTextFromUser or email_txt.txt) and send them to a new PHP script to send mail??
please keep in mind i am PHP retarded... hence why i re-use the same form over and over..
thanks in advance for any help. it's greatly appreciated...
if you're confused about my problem, please let me know... i'm having a difficult time explaining....
"this" Refers To Wrong Instance...
Hi guys! Bumped into a problem and don't understand why this is happening. I got _root timeline, there I placed mc.map (movieclip), inside it I got a button, and on that button I placed this code:
Code:
on (press) {
trace(this._name);
}
And in the output window I see the name of the movieclip instance ("map"). Why? I need it to refer to that button...
Access Property/function Of Instance From Inside Another Instance
Might be something really obvious, but I'm still trying to get my head round as3...
I need to call up a property and function of another instance of the same class, similar as in as2 (called from within "_root.instance_mc1"):
ActionScript Code:
_root.instance_mc2.someNumber = 0;
_root.instance_mc2.someFunction();
Now in AS3 I can access the object (extending sprite) itself (and inherited properties like x) by using:
ActionScript Code:
this.parent.getChildByName("row2").x
but if i try to access public variables/functions from that object (this.parent.getChildByName("row2").someNumber) I get Error 1119: Access of possibly undefined property someNumber through a reference with static type flash.displayisplayObject.
Anyone know how I can get this to work?
Code In One Instance Is Referencing The Previous Instance
I have the following code in a button symbol:
on (release) {
gotoAndStop (2);
_root["answer" + this._name.substr(1)] = "true";
}
I also have an instance of the button in 2 consecutive keyframes. The first instance is named "Q5" and the second instance is "Q6".
I expected the code: this._name.substr(1)]
to reference "5" and "6" from the instance names (Q5 and Q6), but instead instance "Q6" is referencing "Q5"!
The *really* strange thing, is that when I insert a blank keyframe between the two original keyframes, the code works perfectly!
Does anyone know what's happening?
[MX04] Get Instance Name Of Rolled Over Array Instance
Hi
I am willing to do a rollover image gallery which enlarges image on rollover event and shifts the neighbouring ones aside..
Here is the code so far
Code:
_root.bttn.onRelease = function() {
createGallery();
};
function createGallery() {
var row11:Array = new Array("DSCF5659", "DSCF5807q", "DSCF5773q");
for (i in row11) {
_root.createEmptyMovieClip(row11[i], _root.getNextHighestDepth());
_root[row11[i]].loadMovie("segi/"+row11[i]+"small.jpg", [row11[i]]);
_root[row11[i]]._x = i*150;
}
}
_root.onEnterFrame = function() {
function roll() {
var row11:Array = new Array("DSCF5659", "DSCF5807q", "DSCF5773q");
for (i;i<row11.length;i++) {
_root[row11[i]].onRollOver = function() {
this._xscale += 10;
};
}
}
roll();
};
What I would like to do is to:
ask flash which particular movieclip was rolled over , what is its instance name and than perform string operation to get a number (order) of that clip (I am naming all dynamically with image name + number in order)
Can anyone help me please ???
Thanx in advance
How Do I Copy A Sprite Instance Into A BitmapData Instance?
I apologize if this is covered elsewhere: I just don't even know what terms to search on to find what I'm looking for...
I have a sprite that receives various user-drawn lines on it during runtime. I would like to be able to copy this Sprite into a BitmapData instance, then send the pixels from the BitmapData instance to a PHP script. I think I'll be all right with the PHP end of things, but I just don't know how to copy my Sprite into a BitmapData.
(If there were a way to just use BitmapData and use the moveTo, lineTo, mouseX, mouseY, etc, methods, then I'd do that, but I don't even know if that's possible...Obviously, I'm not as well-versed in AS3 as I'd like to be.)
Thanks in advance for any help!
Instance On Top / Movie Instance Depth
Hi everyone,
I would like to know how, if possible, i can get the depth of a movie instance. Basically I just want to make the movie instance clicked on on top of all the others. I was going to try to do this using the swapdepths action but if anyone knows of a better way please tell me!
thanks a lot
jordan woolley
Returning The Instance Name Of A Class From Within The Instance
Hi,
I'm trying to do some error reporting in my actionscript.
I have a class MyData which can be instantiated several times over in each project e.g.
var myData1:MyData = new MyData();
var myData2:MyData = new MyData();
In the error reporting I have put statements like
trace("MyData.loadData reports error.... message...");
However, I'd really like it to return the instantiated name, not the generic class name so that I can trace errors to the particular instance that is failing. Does anyone know how to do this? I've tried
trace(this.toString() + " reports error.... message...");
but I just get a name of [object object] which isn't that helpful!
Many thanks!
Removing Instance X Inside Instance X
In Flash CS3 in library I have a MovieClip symbol Help (exported for AS).
The function below opens an instance of the symbol when the button is clicked.
ActionScript Code:
function showHelp(e:MouseEvent):void {
var helpwindow:Help = new Help();
helpwindow.x = 50;
helpwindow.y = 50;
addChild(helpwindow);
}
This works and instance "helpwindow" shows on the screen.
Now inside the symbol Help i have another button which will run a function that would close that instance. How do I get rid of that instance? I was trying with removeChild but errors occurr.
ActionScript Code:
function removeHelp(e:MouseEvent):void {
removeChild(MovieClip(parent).helpwindow);
}
Quote:
TypeError: Error #2007: Parameter child must be non-null.
How To Call The Instance Name Inside That Instance?
Ok this is what I want...
I am inside an instance of a movie clip. And I want to access the properties of this movie clip. Now the problem is (if) I don't know the name of the instance of the movie clip (suppose I create the instance of the movie clip on the fly!!!), how do i refer to the name of the instance.
Is there something called this. in actionscript?
Any help would be appriciated!!!
Sushubh
Dynamic Instance Name Vs Manual Instance Name?
Hello,
I would like to access this object (taken from Debug > List Objects of in flash player)
ActionScript Code:
Target="_level0.promotion0.loader_mc.instance87.promo TXT"
This is what I am trying to access it with:
ActionScript Code:
trace( this.getChildByName("promotion0").loader_mc.getChildByName("instance87").promoTXT.text );
Error:
ActionScript Code:
1119: Access of possibly undefined property loader_mc through a reference with static type flash.displayisplayObject.
what is the correct way to do this?
Is My Whole Layout Just Wrong, Wrong, Wrong
I have uploaded my layout, I am starting to think that this is not how its done, I will explain.
I have one main swf where I have 5 diffrent section where I want to load 5 different swf into, but I also need one of the swf's which would be a button based one to be able to comunicate with the other 4. I totally think now tehre is an easier way of doing this than the way I'm doing it, can someone help me out here cos as you guy's know, the roots of a good page is in the layout at the begining.
I have uploaded my swfs so you know what I'm talking about.
Please, please comment...
How To Get Button's Instance Name On Stage? OR Can A Button Ahve 2 Instance Names?
i have a button the the stage, with an instance name of: "butt1"
the button itself lives inside a movieclip, where it is called thisButton
when flash runs and I click the button I want to output the button's instance name on the stage (i.e. butt1) but i'm only getting the button's instance name in it's own movie
this._name gives me = thisButton
is the name i want stored in a separate property?
edit: sorry - i realise that the problem is that the button code is inside the mc itself, where the button's name is thisButton
Function Went Wrong....very Wrong.
Okey so i made a function that should, make two movieclips (balls) move around bouncing the edges of the screen....
but something is wrong... plz help...
when i start the movie, the whole picture is moved down to the right, and the balls aint moving, thou i can drag them around...
PHP Code:
left = 0;
right = 550;
top = 0;
bottom = 400;
xspeed = 5;
yspeed = 5;
ball01.onPress = doDrag;
ball01.onRelease = noDrag;
ball01.onReleaseOutside = noDrag;
ball02.onPress = doDrag;
ball02.onRelease = noDrag;
ball02.onReleaseOutside = noDrag;
ball01.onEnterFrame = ball;
ball02.onEnterFrame = ball;
function doDrag() {
this.startDrag();
this.dragging = true;
}
function noDrag() {
stopDrag();
this.dragging = false;
}
function ball() {
if (!dragging) {
_x = _x-xspeed;
if (_x-_width/2<left) {
_x = left+_width/2;
xspeed = -xspeed;
} else if (_x+_width/2>right) {
_x = right-_width/2;
xspeed = -xspeed;
}
_y = _y-yspeed;
if (_y-_height/2<top) {
_y = top+_height/2;
yspeed = -yspeed;
} else if (_y+_height/2>bottom) {
_y = bottom-_height/2;
yspeed = -yspeed;
}
}
}
Instance Name Instead Of Instance Number
hey there,
the following code returns strange names for the instance: I get 'instance61' and 'instance55' when clicking the button in the MC named 'tabber'. I would expect to see 'tab' and 'tab2'.
Is there a way to get the instance name instead of the instance number?
cheers!
PHP Code:
package { import flash.display.MovieClip; import flash.events.MouseEvent; import flash.display.SimpleButton; public class content extends MovieClip { public function content() { //content.stop(); var tab:tabber = new tabber(); tab.x=118; tab.y=75; tab.butt.addEventListener(MouseEvent.CLICK, ms2); addChildAt(tab,1); var tab2:tabber = new tabber(); tab2.x=228; tab2.y=75; tab2.butt.addEventListener(MouseEvent.CLICK, ms2); addChildAt(tab2,1); } function ms(event:MouseEvent):void { trace(event.target.parent.name); } }}
Any Way To For A Class Instance To Ask What Its Instance Name Is?
Hey. I have a class which needs to create a movie clip on the stage. Since each instance of the class will only ever have 1 movie clip on the stage at a time, it seems reasonable that I have the instance create a movie clip with its own name, prefixed with "mc_" or something of the sort.
Here's where I don't know quite what to do... How do I get at this information? For instance, when you a dealing with an XMLNode, you can simply use...
the_answer = xmlNodeInstance.nodeName;
...I know the analogy fails, but hopefully you know what I'm looking for.
Thanks!
Calling An Instance Within An Instance
Hi,
I've got 3 movieclip buttons with instance name, "btn1", "btn2" and "btn3". Inside these clips is another movieclip named "mousedetect".
How do I use a loop on the "mousedetect" movieclip to initiate an action? Without a loop it will look like this:
btn1.mousedetect.onRelease=functiion(){
btnRelease();
}
I've tried something like:
for (i=1;i<=3;i++){
this["btn"+i].mousedetect.onRelease=function(){
btnRelease();
}
}
but an error shows up, what should be the correct syntax?
Thanks!
Actins:wrong Syntax=correct, Right Syntax=wrong
Has any body made a similar observation:
when I want to load a pic into mc and write
_root.loadMovie("pic.jpg","mc");
I get a little window just the size of my pic but not my stage. But when I write:
_root.mc.loadMovie("pic.jpg");
everything is fine. I have a Mac, OS9.1. Is this related to the flashplayer in mac or what?
Want Opening Movie Clip Instance To Close Underlying Movie Clip Instance
Just so you all know, I'm one of three people in our company that uses Flash and I'm considered "the expert". However, we don't do more than a few Flash projects a year, so my scripting knowledge is very, very green. Thanks in advance for your patience.
I have 22 buttons that play an assigned movie clip from the library. I suspect I'm building these things the wrong way (probably true), but here is how each button is constructed....
Each instance that I'm calling a button is actually identified as a movie clip intance with a button in it. It sits on its own layer. When I double-click an instance, several layers are displayed, the majority of which belong to the presentation of the movie clip. The clip lasts five frames.
The first frame consists of blank keyframes for each layer except for one layer that has stop() assigned to the frame and another layer with the actual button. The layer with stop() at frame 1 is then blank for the next three frames, and then another stop() on frame 5 (the last frame).
The button layer lasts all five frames. Here's the script for "display1980":
on (rollOver) {
_root.display1981.gotoandstop(1);
_root.display1982.gotoandstop(1);
_root.display1983.gotoandstop(1);
.
.
.
_root.display2003.gotoandstop(1);
_root.display2004.gotoandstop(1);
_root.display2005.gotoandstop(1);}
on (release) {
_root.Play();
play();
}
For each instance, there is no line of script that refers to itself. In this example for display1980, "_root.display1980.gotoandstop(1);" is not used.
As I mentioned earlier, each instance is on the main stage on its own layer. I've done this with only eight of my instances, so there are now eight layers. (There are--in fact--more than eight layers, but those are not part of this issue.)
The script I created does the job of getting rid of any previously displayed movie clip, but I created a new conumdrum: If I rollover any other button, the currently displayed clip closes. I've tried replacing "on (rollOver)" with "on (press)" but that doesn't work.
Like I said, I suspect I'm buildng this wrong. Is what I built a waste of time, or can it be salvaged? Or, is there a much better and efficient way (and I suppose there is) that can be described so that my green experience can absorb to good effect?
Accessing Movieclip Instance Within Another Movieclip Instance
Accessing library movieclip instance within another library movieclip instance issues.
I have a movieclip in the Library called menuBar. In the menuBar mc I added two buttons. I want to be able to click on each button to play a video for each corresponding button. When I mouse over the button the pointer turns into the hand, suggesting it recognizes it as a button. But I'm unable to access the button (menuBar.button1 in AS2) in my code, I'm using AS3. Any help would be much appreciated. Thank you for your time.
What's Wrong With This?
When I click the button, this AS should run;
on (release) {
ggg = getTimer();
}
In the fram I also have an MC with an animation in it. I do not want the animation to run at load, but to hold a few seconds, and then start running.
onClipEvent (Load) {
stop();
}
if (ggg = ggg ++ 3000) {
MC.play();
}
But, apparently there's something wrong, 'cause when I execute my movie Flash says that there's a ')' missing, but I cannot understand/locate where! I think that it has something to do with my equation in the if-action.
Btw, the script doesn't work in action, the animation starts immediately
What's Wrong?
hello!
i want to publish in flash 4 format.
i have got a button in a movie clip called 'nav' which is nested in a movieclip called 'navigation' which lives on the main timeline. on releasing the button i want the 'navigation'-movie to play. this is what i have got but it does not work. it forces the movie to start at frame one of the main timeline:
on (release) {
tellTarget ("_level0.navigation") {
play();
}
}
_root.navigation did not work at all.
what's wrong with it? or talking basic: how to target another clip in flash 4?
thanks for any help,
elo.
What Am I Doing Wrong?
Can anyine help what am I doing wrong?
Have a menu that I am trying to load variables into from a perl script. Within the script i placed the variables so that it would load into flash:
<PARAM NAME=movie value="/dragg2.swf?category={$ARGV[1]}&item={$ARGV[2]}">
Than in flash i have a button with the following:
on (press) {
loadVariables ("auction.cgi", "$ARGV[1]&$ARGV[2]&$firstbid[0]");
}
on (release) {
getURL ("http://www.sitename.com/cgi-bin/auction/all_categories.cgi?ask&category=$ARGV[1]&item=$ARGV[2]");
}
What's Wrong?
i'm creating a dynamic pie chart based on the tute i found here in flashkit. i have this part in my the AS:
aCount = new Array(47, 4, 23, 2, 4, 1, 13, 2);
aCategory = new Array("HEAD", "CDROM", "CONN", "MM", "COB", "DAT", "FDD", "PM",);
nElements = aCount.length;
aColor = new Array(0x339900, 0x0000FF, 0xcc66cc, 0x00cccc, 0x9933cc, 0xcc66cc, 0xcc33cc, 0x3366cc);
aPercent = new Array(nElements);
nDepth = 1;
but when i preview my movie i keep getting these errors:
Scene=Scene 1, Layer=Layer 1, Frame=1: Line 2: Operator '=' must be followed by an operand
aCategory = new Array("HEAD", "CDROM", "CONN", "MM", "COB", "DAT", "FDD", "PM",);
Scene=Scene 1, Layer=Layer 1, Frame=1: Line 3: ')' or ',' expected
nElements = aCount.length;
i can't seem to understand the error since im not that good in scripting stuff. hope someone could point me out what's the error all about and how could i remedy it. thanks in advance
Something Wrong Wif My Key Pls HELP
I put a "Pause_Play" MC on the layer "Actions", and write the following in the Object Actions,
onClipEvent (enterFrame) {
if (Key.isDown(80)) {
stop ();
}
}
but when i do a Test Movie, the movie doesn't stop uppon pressing "P" on my keyboard. Why?
What's Wrong ? Help Me Please :(
What do you think about this flash ? What's wrong with it ? when it loads for the first time, it ask a quastion to cancel some scripts, then when you refresh the page all is correct ! Help me please.
http://www.navid.8k.com/baha/
Don't Know What Went Wrong...
Here's my current situation:
I have 2 scenes,"mainsite"(contains my main website) and "preloader" (which is my ...erm...preloader).
In my mainsite timeline, i have 3 frames. In frame 1 i have this:
virgin = 1;
in frame 2 i have a stop(), and frame 3 onwards is an animation.
Now, in frame 2 i have an MC which contains a 30-frame animation. at frame 30, i have this:
stop ();
if (_root.virgin != 0) {
_parent.gotoAndPlay("mainsite", 3);
}
What im trying to do is to get the MC animation to finish playing before playing the animation in my main timeline.
Everything worked perfectly, UNTIL i inserted my preloader.
In frame 1 of my preloader i have this:
ifFrameLoaded ("mainsite", 18) {
gotoAndPlay ("mainsite", 1);
}
After i did my preloader, my "mainsite" gets stuck at frame 2, where my stop() is.
Anyone knows where the problem lies? Thanx...
What Went Wrong?
when I tried to reply on a question in a previous thread my computer hung and then the thread broke. so here the question again. sorry albywalbywoo for not answering on your reply.
you asked for more details on the problem though....well I hope this will do
I have a scrollbarr wich scrolls dynamic txt (pretty nice design by ilanJ). It loads .txt files with loadvariables from the root of the same folder where the .fla is in.
I format these files using HTML tags.
For lots of things this works just fine, but I want to use a button in this .txt file that can play a MC in flash....
hope that's enough informtion about it
thanks
Can Someone Tell Me What's Wrong With This?
I am trying to set a conditional statement to test to see which button is pressed. If button01 is pressed then load "movie01.swf" into level 1, if button02 is pressed then load "movie02.swf" into level 1, and so forth.
I attached the following to a mc on the root timeline of level0
the buttons are also on this level as well.
-------------------------------------------------------
onClipEvent (load) {
var button01 = "1";
var button02 = "2";
var button03 = "3";
}
onClipEvent (enterFrame) {
if (button01 == "1") {
loadMovieNum ("movie01.swf", 2);
} else if (button02 == "2") {
loadMovieNum ("movie02.swf", 2);
} else if (button03 == "3") {
loadMovieNum ("movie03.swf", 2);
}
}
-------------------------------------------------------
and then this to the buttons accordingly
on (release) {
button02 = "2";
}
I am unable to get it to work.
can you tell me what it is I am doing incorrectly?
Thanks
Do Not Know What Is Wrong
Hi everybody! I am kind of new to Flash and just completed my few first sites that posed two problems that I can't figure out myself.
1)My last site i did would behave differently on diffrent screen sizes running on identical systems. It's realy strange. On my computer it works perfectly as well as on many others. But since i had lots of people going to the site i've got number of complaints that site is not working. People would say that nothing is moving and they can not get to diffrent sections. It's seems to be only a problem on smaller monitors (however I am not completely sure). So if you people could go and see it (it's http://www.zeitny.com) and if you incounter the same problem and know how to fix it please let me know 'couse i am going bananas.
2)Also if somebody could give me a hint how to do those java pop-up windows i also would be very gratefull.
Thanks for your time
Pete
What Wrong With This
just won't work...is this right?
_level50.Area.gotoAndPlay("areaDropOut");
basically I am trying to target a movieclip thats on the _root of level 50 called area and get that clip to go to a frame called "areaDropOut" within it...
what's wrong with it..am I going mad..
stu
Why Is This Wrong?
stop ();
function createButtons(){
// create the invisible buttons!
for(i=0;i<6;i++) {
for(k=0;k<6;k++) {
attachMovie("masterpiece","button"+i+k,4);
_root["button"+i+k]._x = 183.3 + (i*56) ;
_root["button"+i+k]._y = 24.4 + (k*50);
}
}
}
i want it to make 36 movie clips like this (all on one layer, they arent going to move)
should be:
x x x x x x
x x x x x x
x x x x x x
x x x x x x
x x x x x x
x x x x x x
what really happens
x
tell me why
Help..what Could Be Wrong In Here?
Here is the problem:
I Have two Swf right?
and in the second swf file I want to link to the second scene of the first swf file (scene1,since the first one is named as preloader, and only for this time I would like to skip it )
I am doing something like this
In the first frame of the first swf file:
var x;
x = "1";
y = _level0.x;
if (y==1) {
gotoAndPlay (1);
} else if (y==2) {
gotoAndPlay ("Scene 1", 1);
}
then
in the second swf file in the first frame:
var y;
y = _level0.x;
and in the button of the second swf file:
on (release) {
loadMovie ("ano1.swf", "gotoAndPlay (_level0.x)");
}
The problem is that this do not work.
Any Help? Please?
thanks
Am I Doing Something Wrong?
The musicloops I download from flashkit won't loop as I want 'em to loop. What I mean is there's allways a little "hack" in the end of the loop. Am I doing something wrong or do I have to live with this? Maybe I should mention that I download the loops as Mp3.
//raw
What Am I Doing Wrong?
im trying to get a scrolling text box with a text source from flash 4 to work when i import it to flash 5 .......all i get is when i try to manipulate the script is " the script wasnt copied due to errors" what can i do???
WHAT'S WRONG WITH ME?/
Why the heck won't this syntax work???? It's pissing me off to no end (pardon my french).
on (rollOut) {
nav = "nav services";
}
on (rollOver) {
tellTarget ("services") {
play ();
if (nav = "blank") {
} else if (nav = "nav services") {
tellTarget ("services") {
stop ();
}
}
}
}
Initially, the variable "nav" is set to "blank" in a timeline frame. What I want to happen is to when I rollOut the hotspot, I want the variable "nav" to be set to "nav services" so that if you roll over the hotspot again and nav = "nav services" the movie it's calling won't play again (and return to it's initial invisible state) ... here's the link. PLEASE HELP ME!!!!! I'M AN IDIOT!!!
http://www.20202020.net/allnetnav.htm
thanks a million,
greg
420
What Am I Doing Wrong.....?
Hello pplz,
Here i am generating some sort of count down based upon a fixed date (lets say may 15th, as used in the code below)
If i can still do some calculating i should get a result somewhere (counted from this post's entry date March 22) around the 55, but when running this script the result displayed in my swf doesn't go further than 39
is there anyone in the house that can tell me what goes wrong down here......
//-------------CODE--------------------------------
now = new Date();
dateNow = now.getDate();
monthNow = now.getMonth();
daysInMarch = 31;
daysInApril = 30;
daysInMay = 15;
if (monthNow == 1) {
daysLeftInMarch = daysInMarch-dateNow;
daysLeft = daysLeftInMarch+daysInApril+31;
} else if (monthNow == 2) {
daysLeftInApril = daysInApril-dateNow;
daysLeft = daysLeftInApril+31;
} else if (monthNow == 3) {
daysLeftInMay = daysInMay-dateNow;
daysLeft = daysLeftInMay+31;
} else {
daysLeft = 31-dateNow;
}
DateCount = daysLeft;
//----------------CODE-------------------------
Thanx in advance
No No No You Got Me All Wrong Man
ok, what you see on that link, this is how I did it:
1. I make 5 MCs, and place them off the stage, and give them names.
2. I make 5 instances of my button - 1btn per MC.
3. when I roll over button 1, it moves MC1 from it's orig. location (off-stage) to a new location on the stage.
4. when I roll out of button 1, MC1 goes back to original position.
I do this for every button, referencing each MC.
**********************
now what I REALLY want to do, is to make MC1 fade away after I roll out of button1, so it doesn't go away instantly, but rather fades away.
**********************
sid
What´s Wrong Here?
Hello all. Have a look at this:
------------------------------
var1 = 1;
var2 = 1;
if (var1 == 1 && var2 == 1) {
trace ("Result OK");
} else {
trace ("Operation Failed");
}
------------------------------
Is this script ok?, If it is, why it returns
"Operation failed".
Thanks for having a look, I´m stuck in there.
aX--.
What Is Wrong HERE?
The MC is duplicated just fine but it won't go away afterwards!
onClipEvent(enterFrame){
if(this.hitTest(_root.view)){
pylon2.duplicateMovieClip("pylon2", "pylon2"+_root.i,1);
_root.++;
_root["pylon2"+i]._x=200;
_root["pylon2"+i]._y=200;
}
else
{
_root["pylon2"+i].removeMovieClip();
}
}
I've tried many MANY different combinations.
What's Wrong?
What is wrong here?:
stop ();
if (Key.isDown (Key.UP) && Key.isDown (Key.RIGHT)) {
nextFrame ();
}
It won't work
Thanks
What Am I Doing Wrong ?
can someone please tell me what i've done wrong, i have two movie clips. One of them is not suppost to move and the other is moved using actionscript which increases the x value of the movie using setproperty.
However when i do this although i have given each movie a different instance name and am only changing the x value of one movie they both move across the screen.
Why is this happening ???
WHAT AM I DOING WRONG?
Hi All.
i am trying to produce a portfolio, i have created all the elements, but i am having a problem.
i want to show a larger version of a design as you mouseover a smaller version of the graphic, i have done this using the following code between the button and movie:-
on (rollOver, release) {
if (myMovie._currentframe == 1) {
myMovie.gotoAndPlay(1);
};
}
but when i mouse over the next small portfolio image it just overlays the movie over the previous movie, how do i adjust this code so the previous movie is cleared when i mouseover the next image so they don't overlay each other??
thanks
Cappa
------------------
What Am I Doing Wrong?
I have a script:
on (release) {
if (password == "" and account == "") {
gotoAndPlay ("scene 1", 32);
} else {
password = password.toLowerCase();
account = account.toLowerCase();
getURL ("http://www.somesite.com/check.asp?a="+account+"&p="+password);
}
}
But It will not flag the password and account if they are empty. It just passes the empty params to the .asp page!!!
What is wrong with this script?
Can Someone Tell Me What I'm Doing Wrong?
Ok, this might be a little hard to explain but here goes. Let me try to simply it. 5 Frames, I'm trying to spell the work Flash. Frame 1 spells, out the F. Frame 2 spells out the F with the L added in. Frame 3 with FLA. and when Frame 4 comes around, when I add in the S, the S appears in the previous 3 frames, why is that, what would cause it to do that? I've tried a few different things, but everytime, I add in anything past the FLA, it always appears in previous frames. Hope someone can help, thnx
|