Action script 3 help
Hi,
I am only a designer, not a programmer so the script is a
mystery for me.
I need the code to stop at a frame (the old release on etc)
and the button code to navigate to a certain frame (the old go to
frame). All in script 3 please.
I need time to catch on AS3, but I need those two codes for
my current movie.
Thank you all helpful programmers out there!
I guess there's nobody helpful here.
That's sad. I have not received one single asnwer to any of
my questions on this forum.
Similar Messages
-
Action Script 3 help me with this tutorial?
Can someone show me what code I am suppose to have made at the end of the tutorial. In my version the button I click doesn't work to move onto the game.
Activity 3:
Aim: Creating a new INIT function for the “Start Screen”.
1. The next step to this game is to create a “Start” screen. Now this is going to be the
first thing that loads when the game start, so the suggestion is we make some changes
to the structure of the current game. The first thing is renaming:
private function init(e:Event = null):void
To:
private function game(e:Event = null):void
This helps make the title for this function more obvious and appropriate.
2. Now that we have made this change we can recreate a brand new init function for the
start screen. We create this above the game function.
The new public function init(e:Event = null):void will contain:
• Declaring the start image as a new Go();
• add it as a child• Position it suitably in the centre of the screen.
Test and Annotate
3. Now that the start button image is displayed on the screen appropriately we need to
make it clickable. So, within the new init function add an “EventListener”, which is
a “MouseEvent” CLICK, which takes you to a new Method called “startgame()”.
4. So now that the listener is in place we need to make the new public function called
“startgame()”, for which the previous listener is pointing to. This will look like:
public function startgame(e:Event):void
//SOME CODE
This is to be placed under your init function. The “e:Event” part states that this will
have some kind of action event happening to it.
5. Within this Method we need to set up a statement that will send the player to the game
itself when the start image is clicked. This will be an “If” statement, and will look like
this:
Start => The e.target==start =(True)=> removechild(start) => game() =>stop// that looks like a pretty poor tutorial. but
public function init(e:Event=null):void{
go=new Go(); // you need to declare go
addChild(go);
go.addEventListener(MouseEvent.CLICK,startgame);
public function startgame(e:Event):void{
removeChild(start_mc); // where start_mc is the movieclip of your start screen
addChild(game_mc); // where game_mc is the movieclip of your game -
Cant fins a brokel link in the action script, please help.
Hi guys. I'm fairly new to flash and I've hit a hurdle which
I think looks pretty simple.
I click on a button in the Nav bar (SERVICES) and the link
seems to be broke.
Do I need to upload the fla file to get help or can you tell
from the movie on line here?
http://www.willpower.net.au/rounddesigncopysite/The link in your message is also broken.
-
Ok so here it is. I have a movie clip with continuous
scrolling thumbnail movie clips inside it. Here is what I need to
happen:
Upon rolling over the thumbnails the movie clip stops
scrolling, when you click on the thumbnails, another movie clip
from the _root timeline plays, when you roll off the movie clip
they begin to scroll again.
I have tried everything to get this darn thing to stop
moving, what am I doing wrong?
here is where the source code lies:
http://www.sortismarketing.com/lifeline/flash/index.htmlok so here is what I have so far:
import mx.utils.Delegate;
function thumbMover() {
this._y = this._y+1;
if (this._y>=418) {
this._y = -50;
function startScrolling() {
for (var i = 1; i<5; i++) {
var feat = this.main.featProd["feat"+i];
feat.onEnterFrame = thumbMover;
feat.onRollOver = Delegate.create(this, stopScrolling);
feat.onRollOut = Delegate.create(this, startScrolling);
feat.onPress = thumbPressed;
feat.onRelease = feat.onReleaseOutside=thumbReleased;
function thumbPressed() {
//this refers to the thumb pressed
if (this == _root.main.featProd.feat1) {
_root.main.feat1_mc.gotoAndPlay(1);
} else if (this == _root.main.featProd.feat2) {
trace("do action for feat 2");
} else if (this == _root.main.featProd.feat3) {
trace("do action for feat 3");
} else if (this == _root.main.featProd.feat4) {
trace("do action for feat 4");
function thumbReleased() {
//this refers to the thumb released
function stopScrolling() {
for (var i = 1; i<5; i++) {
delete this.main.featProd["feat"+i].onEnterFrame;
this.startScrolling();
now here is the problem. When you click on feat1, it plays
the movie, but then when you click it again instead of playing the
movie again, the movie disappears, and then if you click a third
time it plays the movie again. It needs to play the movie each time
you click on feat1
and the same for all the other thumbs: feat2, feat3, feat4.
basically if you click feat1, play feat1_mc, stop all the
other feat_mc's from playing
if you click feat2, play feat2_mc, stop all the other
feat_mc's from playing.... -
Action script 3 help card flip
Help!! I am new to Flash. I am trying to make a card flip, I have a photo on one side and info on the back. It is controlled by a button. I get the card to flip but the infor is on the side2 is flipped to be a mirror image so the text is backwards. I can't figure out how to fix this. Can anyone help?
thanks!
Here is my code:
import fl.transitions.Tween;
import fl.transitions.easing.Strong;
import fl.transitions.TweenEvent;
con.sidea.flip.addEventListener(MouseEvent.CLICK, onflip);
con.sideb.flip.addEventListener(MouseEvent.CLICK, onflip);
addEventListener(Event.ENTER_FRAME,loop);
var isStill: Boolean=true;
var arraytween:Array = new Array ();
function onflip (e:Event) {
if (isStill) {
arraytween.push (new Tween (con,'rotationY', Strong.easeOut,con.rotationY,con.rotationY+180,1,true));
arraytween [0] .addEventListener(TweenEvent.MOTION_FINISH,reset);
isStill=false;
function reset (e:Event) {
isStill=true;
arraytween=[];
function loop(e:Event) {
if (con.rotationY>=90 && con.rotationY<=270) {
con.addChild(con.sideb);
}else {
con.addChild(con.sidea);
con.scaleX=1;
if (con.rotationY>=360) {
con.rotationY=0;If it involves a textfield that you place on the stage manually, then select the textfield and from the menu bar select Modify -> Transform -> Flip Horizontal.
Someone else may have a more intelligent answer for you. I don't have a version of Flash that supports rotationX/Y/Z properties, just rotation, so I am just guessing that this is what you can do to get what you want. -
Action script.. help with using components
i need help using the list component for my text in animation. i want the component to allow viewers to scroll and view text.
this is the situation.
i am making a photography website.
in the text area would be the names of photoshoots in which customers and viewers can scroll through the names.
my ultimate goal is to have a hover image and the text with background appears beside the picture when the picture is hovered over.to help i have added pictures. picture a when it is hovered over has a gallery list that pops up beside it. this can be seen in the image below where the green background displays a list of gallery photoshoots. as you can see the white scrollbar is so the viewers can scroll down and view the other names. i amusing dreamweaver for my webpage and adobe flash for my list animation. i welcome all suggestions and ideas to this problem thank you -
Flash Newbie needs help with Movie Clips/Action Scripting
Hi -
I'm having a problem with my movie clips playing
simultaneously and cannot, for the life of me, figure out what I
have done wrong. I'm new to flash, so I may have set something up
incorrectly, but here's what I have so far:
11 layers, total: 1 layer with 10 control buttons, each
button with the following actionscript:
on (release) {
gotoAndPlay(85);
Where the number changes in relation to which keyframe the
next movie is on.
I have 10 movies, total, but they are only movie clips,
essentially photo slide shows with audio, made all in the library.
The problem happens when I click on the second or third
button. Not only does the movie that I have selected begin to play,
but all of the previous clips do as well, so it all sounds quite
garbled. I don't know what I am missing in the action script, as my
Action Layer has a stop command on it at each keyframe where there
is a new clip to play.
I have tried to add a stopAllSounds command, but I'm afraid
that doesn't do anything because it is not a "sound file" per se,
playing in the timeline.
I'm at the end of my rope and really need some help in
figuring this one out. My project is hanging in the balance on
this, as I have scripted everything else correctly and it runs
beautifully.
Please help!
Thanks,
CarolineEach layer has a blank keyframe before and after each
movieclip. Each movie clip is at a different frame. Even with the
blank keyframes added, the second video starts to play and then the
first video begins to play. Same happens if I click on the third
button. Third plays, and starts 1st and 2nd shortly thereafter. Is
there an action script I can put in that will tell the timeline
that, when a button is clicked, no matter where the movieclip is,
it will stop and start the newly selected movieclip? -
Help with action script please
hay guys, im having trouble with changing my action script to
allow multiple layers of the same thing in order to show a greater
sense of depth than the normal application. im using a flash
toutorial on making a sort of matrix like falling text (
link)
and im not completely understanding what to change in order to
accomplish my goal. i tryed to send them a message using their
contact page, but its broken, forcing me to find a forum. im sure
it has something to do with the third group of code where it
identifies what its using. but whenever i change anything there to
either match the identifiers or movie clip names the action script
crashes when i test the movie. any help is appreciated.
im using flash cs3 and made sure to create it all in action
script 2.0
please excuse my spelling, im sure i made a mistake
somewhere."FlashTastic" <[email protected]> wrote in
message news:e4ir4t$ru4$[email protected]..
>I don't think an enterframe will be your best bet.
>
> You might want to use something like
>
> if(_root._currentframe >= _root.totalframes){
> loadMovie("myMovie.swf",_root)
Why in the world would you do that when you can just put a
keyframe on the last frame and ..
loadMovie("myMovie.swf");
tralfaz -
Help... link URL from XML to Flash Action Script 2
I am trying to link a different URL to each of my files in XML and use this XML in Flash were I created a carousel. In the carousel, when you click on a picture I would like to insert a specific URL. Each picture will have a different URL (http://------------).
Here are my codes:
XML:
<icons>
<icon image="icon1.png" tooltip="Planning" />
<icon image="icon2.png" tooltip="Investments" />
<icon image="icon3.png" tooltip="Education" />
<icon image="icon4.png" tooltip="Insurances" />
<icon image="icon5.png" tooltip="Mortgages" />
<icon image="icon6.png" tooltip="Retirement" />
<icon image="icon7.png" tooltip="Business Owner" />
<icon image="icon8.png" tooltip="Banking" />
</icons>
Flash Action Script 2:
import mx.utils.Delegate;
var numOfItems:Number;
var radiusX:Number = 250;
var radiusY:Number = 75;
var centerX:Number = Stage.width/2;
var centerY:Number = Stage.height/2;
var speed:Number = 0.01;
var perspective:Number = 60;
var home:MovieClip = this;
var tooltip:MovieClip = this.attachMovie("tooltip","tooltip",10000);
tooltip._alpha = 0;
var xml:XML = new XML();
xml.ignoreWhite = true;
xml.onLoad = function()
var nodes = this.firstChild.childNodes;
numOfItems = nodes.length;
for(var i=0;i<numOfItems;i++)
var t = home.attachMovie("item","item"+i,i+1);
t.angle = i * ((Math.PI*2)/numOfItems);
t.onEnterFrame = mover;
t.toolText = nodes[i].attributes.tooltip;
t.icon.inner.loadMovie(nodes[i].attributes.image);
t.ref.inner.loadMovie(nodes[i].attributes.image);
t.icon.onRollOver = over;
t.icon.onRollOut = out;
t.icon.onRelease = released;
function over()
home.tooltip.tipText.text = this._parent.toolText;
home.tooltip._x = this._parent._x;
home.tooltip._y = this._parent._y - this._parent._height/2;
home.tooltip.onEnterFrame = Delegate.create(this,moveTip);
home.tooltip._alpha = 100;
function out()
delete home.tooltip.onEnterFrame;
home.tooltip._alpha = 0;
function released()
function moveTip()
home.tooltip._x = this._parent._x;
home.tooltip._y = this._parent._y - this._parent._height/2;
xml.load("icons.xml");
function mover ()
this._x = Math.cos(this.angle) * radiusX + centerX;
this._y = Math.sin(this.angle) * radiusY + centerY;
var s = (this._y - perspective) / (centerY+radiusY-perspective);
this._xscale = this._yscale = s * 100
this.angle += this._parent.speed;
this.swapDepths(Math.round(this._xscale) + 100);
this.onMouseMove = function()
speed = (this._xmouse-centerX)/10000;
Thanks so much for the help.You should be able to add that data into your xml tags and then extract it in the AS2 onLoad function...
XML:
<icons>
<icon image="icon1.png" tooltip="Planning" linkURL="http://www.someURL.com/somePage.html" />
AS2:
xml.onLoad = function()
etc....
t.onEnterFrame = mover;
t.toolText = nodes[i].attributes.tooltip;
t.urlLink = nodes[i].attributes.linkURL;
etc... -
Flv xml Stream Playlist action script help
So if you go to this site:
click here
you will see a FLV player that has a list of videos that are
pulled from a .xml file...
The action script for this player is as such:
var nc:NetConnection = new NetConnection();
nc.connect(null);
var ns:NetStream = new NetStream(nc);
theVideo.attachVideo(ns);
rewindButton.onRelease = function() {
ns.seek(0);
playButton.onRelease = function() {
ns.pause();
var videoInterval = setInterval(videoStatus,100);
var amountLoaded:Number;
var duration:Number;
ns["onMetaData"] = function(obj) {
duration = obj.duration;
function videoStatus() {
amountLoaded = ns.bytesLoaded / ns.bytesTotal;
loader.loadBar._width = amountLoaded * 194.5;
loader.scrub._x = ns.time / duration * 194.5;
var vlist:XML = new XML();
vlist.ignoreWhite = true;
vlist.onLoad = function() {
var videos:Array = this.firstChild.childNodes;
for(i=0;i<videos.length;i++) {
videoList.addItem(videos
.attributes.desc,videos.attributes.url);
ns.play(videoList.getItemAt(0).data);
videoList.selectedIndex = 0;
var vidList:Object = new Object();
vidList.change = function() {
ns.play(videoList.getItemAt(videoList.selectedIndex).data);
videoList.addEventListener("change",vidList);
vlist.load("videos.xml");
I want to action script something that will make the videos
play one after the other, get rid of the list on the right and have
buttons on player that allow you to go to the next/previous video
listed in the .xml file
Its sort of like the player at
click
here
I know this is a lot to ask, but I am currently in a jam and
any help would be greatly appreciated...
Thanks
Matthelm88gotoAndLearn is a fantastic base to build off of.
but
i'm looking for the same thing... how do you get the files
to play one after another?
i've looked for everyhting ns. related and i can find any
doc's on this one.
i 've found the
function complete_listener(eventObject:VideoEvent):void {
if (my_FLVPlybk.source == "rentv1.flv") {
my_FLVPlybk.play("rentv2.flv");
else if (my_FLVPlybk.source == "rentv2.flv") {
my_FLVPlybk.play("rentv3.flv");
on the flash video live docs.. but i can't find anything on
how to tie it into the XML.
anything anyone can offer would be a huge help ... -
Action Script Help (Flash 8 ONLY)
My department currently has a host of training videos we use
for online courses. Of course, these are all being delivered as
FLVs. Through the Developer's communities, I found a script that
allowed me to add a caption file to the video (XML).
Now I'd like to take it to another level. I'd like to be able
to have my one SWF player play a series of FLVs AND include the
caption file. I began to look at using an Array, but have not been
successful in making it work. I'm not too sure, but I think the way
I coded it started to affect the video - started getting "stuck" at
times. Another attempt caused the caption file from the previous to
be seen in the current video.
I have attached my script and would appreciate any
assistance.
Finally, I need to stick to a Flash 8 and Action Script 2.0
solution. I realize that Flash 9 and Action Script 3.0 would be
helpful, but our district PCs are all imaged with a Flash 8 player.
Sorry.
Thank you for your help.
Frank Erazo ([email protected])Whatever approach you take will depend heavily on the document(s) you have for the bible element of the design. You somehow need to be able to seek within it and determine where matched elements can be found and how to extract the information you intend to present.
I don't think your issue currently lies with how to do this in Flash as much as first coming up with a gameplan that identifies the players and how you can interact with and within them. -
Im taking over a job and I was given the original flash file
that doesnt seem to be working properly.
It a thumbnail menu that loads through xml...the images work
fine but the Links & Titles do not load.
Nor does the rollover effect. Here what I have.
Action Script:
Stage.align = "TL";
Stage.scaleMode = "noscale";
preloader._visible = true;
thumbs_line._visible = false;
import mx.transitions.Tween;
import mx.transitions.easing.*;
my_xml = new XML();
my_xml.ignoreWhite = true;
if (_parent.xml_file == undefined) {
my_xml.load((String(_url.slice(0, (_url.length-3))))+"xml");
} else {
my_xml.load(_parent.xml_file);
my_xml.onLoad = function(ok) {
if (ok) {
process_xml();
} else {
trace("XML not loaded");
function process_xml() {
total_images = my_xml.childNodes[1].childNodes.length-1;
gallery_width =
Number(my_xml.childNodes[0].childNodes[0].attributes.gallery_width);
gallery_height =
Number(my_xml.childNodes[0].childNodes[0].attributes.gallery_height);
max_thumb_height =
Number(my_xml.childNodes[0].childNodes[0].attributes.max_thumb_height);
thumbs_space =
Number(my_xml.childNodes[0].childNodes[1].attributes.thumbs_space);
thumb_border =
Number(my_xml.childNodes[0].childNodes[1].attributes.thumb_border);
image_border =
Number(my_xml.childNodes[0].childNodes[1].attributes.image_border);
fade_in_seconds =
Number(my_xml.childNodes[0].childNodes[2].attributes.fade_in_seconds);
fade_out_seconds =
Number(my_xml.childNodes[0].childNodes[2].attributes.fade_out_seconds);
thumb_fade_seconds =
Number(my_xml.childNodes[0].childNodes[2].attributes.thumb_fade_seconds);
fade_in_seconds += 0.01;
fade_out_seconds += 0.01;
thumb_fade_seconds += 0.01;
thumbs_line._y =
gallery_height-max_thumb_height-(4*thumbs_space);
thumbs_line.thumbs_bg._width = gallery_width;
thumbs_line.thumbs_mask._width = gallery_width;
thumbs_line.thumbs_bg._height =
max_thumb_height+thumbs_space*2+thumb_border*2;
thumbs_line.thumbs_mask._height =
max_thumb_height+thumbs_space*2+thumb_border*2;
thumbs_line._visible = true;
load_thumb(0);
preloader._x = int((gallery_width-preloader._width)/2);
preloader._y = int(thumbs_line._y/2-preloader._height/2);
max_image_height =
gallery_height-max_thumb_height-thumbs_space*6;
load_image(0);
this["link"+t] =
my_xml.childNodes[1].childNodes[t].attributes.link;
function load_thumb(t) {
thumbs_line.thumbs.createEmptyMovieClip('thumb'+t,
thumbs_line.thumbs.getNextHighestDepth());
thumbs_line.thumbs['thumb'+t]._y =
thumbs_space+thumb_border;
thumbs_line.thumbs['thumb'+t]._x =
thumbs_space+thumb_border;
if (t>0) {
thumbs_line.thumbs['thumb'+t]._x =
thumbs_line.thumbs['thumb'+(t-1)]._x+thumbs_line.thumbs['thumb'+(t-1)]._width+thumbs_spac e;
thumbs_line.thumbs['thumb'+t].image_number = t;
thumbs_line.thumbs['thumb'+t].onRollOver =
thumbs_line.thumbs['thumb'+t].attachMovie("thumbov_mc",
"thumbov_mc", 10);
thumbs_line.thumbs['thumb'+t].onRelease = function() {
tellTarget (thumbs_line.thumbs['thumb'+t]) {
var loadListener:Object = new Object();
loadListener.onLoadInit = function(target_mc:MovieClip) {
preloader.visible = false;
thumbs_line.thumbs['thumb'+t].attachMovie("border_grey",
"border_grey", 10);
thumbs_line.thumbs['thumb'+t].border_grey._x -=
thumb_border;
thumbs_line.thumbs['thumb'+t].border_grey._y -=
thumb_border;
thumbs_line.thumbs['thumb'+t].attachMovie("border_white",
"border_white", 20);
thumbs_line.thumbs['thumb'+t].border_white._x -=
thumb_border-1;
thumbs_line.thumbs['thumb'+t].border_white._y -=
thumb_border-1;
if (target_mc._height>max_thumb_height) {
ratio = target_mc._width/target_mc._height;
target_mc._height = max_thumb_height;
target_mc._width = int(target_mc._height*ratio);
thumbs_line.thumbs['thumb'+t].border_grey._width =
target_mc._width+thumb_border*2;
thumbs_line.thumbs['thumb'+t].border_grey._height =
target_mc._height+thumb_border*2;
thumbs_line.thumbs['thumb'+t].border_white._width =
target_mc._width+thumb_border*2-2;
thumbs_line.thumbs['thumb'+t].border_white._height =
target_mc._height+thumb_border*2-2;
if (t<total_images) {
t++;
load_thumb(t);
thumbs_width = thumbs_line.thumbs._width;
thumbs_right_limit = 0;
thumbs_left_limit =
0-thumbs_width+int(gallery_width-thumbs_space-thumbs_space);
var thumb_fade_in:Tween = new Tween(target_mc, "_alpha",
none.easeIn, 0, 100, thumb_fade_seconds, true);
var thumb_loader:MovieClipLoader = new MovieClipLoader();
thumb_loader.addListener(loadListener);
createEmptyMovieClip("img", 30);
thumb_loader.loadClip(this.my_xml.childNodes[1].childNodes[t].attributes.small,
img);
thumbs_line.onMouseMove = function() {
if (_xmouse>=thumbs_line.thumbs_bg._x and
_xmouse<=thumbs_line.thumbs_bg._width and
_ymouse>=thumbs_line._y and
_ymouse<=thumbs_line._y+thumbs_line._height) {
onRollOver =
thumbs_line.thumbs['thumb'+t].attachMovie("thumbov_mc",
"thumbov_mc", 10);
onEnterFrame = function () {
if (_xmouse<(gallery_width/2)-10 and
thumbs_line.thumbs._x<thumbs_right_limit) {
thumbs_line.thumbs._x -=
int((_xmouse-thumbs_line.thumbs_bg._width/2)/(100-scroll_speed));
if (thumbs_line.thumbs._x>thumbs_right_limit) {
thumbs_line.thumbs._x = thumbs_right_limit;
if (_xmouse>gallery_width/2+10 and
thumbs_line.thumbs._x>thumbs_left_limit) {
thumbs_line.thumbs._x -=
int((_xmouse-thumbs_line.thumbs_bg._width/2)/(100-scroll_speed));
if (thumbs_line.thumbs._x<thumbs_left_limit) {
thumbs_line.thumbs._x = thumbs_left_limit;
} else {
onEnterFrame = undefined;
this["link"+t] =
my_xml.childNodes[1].childNodes[t].attributes.link;
this["the_target"+t] =
my_xml.childNodes[1].childNodes[t].attributes.target;
XML File
<?xml version="1.0" encoding= "UTF-8" ?>
<options>
<option gallery_width="730" gallery_height="450"
max_thumb_height="96"/>
<option scroll_speed="75" thumbs_space="0"
thumb_border="1" image_border="2"/>
<option fade_in_seconds="1.5"
thumb_fade_seconds="1.5"/>
</options>
<gallery>
<img small="../flash/hosts/images/pic7.jpg" title="Name
1" link="hosts.asp"/>
<img small="../flash/hosts/images/pic1.jpg" title="Name
2" link="bio1.asp"/>
<img small="../flash/hosts/images/pic2.jpg" title="Name
3" link="bio2.asp"/>
<img small="../flash/hosts/images/pic3.jpg" title="Name
4" link="bio3.asp"/>
<img small="../flash/hosts/images/pic5.jpg" title="Name
5" link="bio4.asp"/>
<img small="../flash/hosts/images/pic6.jpg" title="Name
6" link="bio5.asp"/>
<img small="../flash/hosts/images/pic8.jpg" title="Name
7" link="bio6.asp"/>
<img small="../flash/hosts/images/pic9.jpg" title="Name
8" link="bio7.asp"/>
</gallery>
Thier is a dynamic Text field in the roll over effect that
should contain the "title"
the rollover MC name is: thumbov_mc
the dynamic text field is labeled: title
And the links are not working either?
Does anyone see the problem?
Thank You So Much for you help in AdvanceIf you think you can help just let me now and ill email you
the link to where this menu is...i dont want to post it for
everyone to see..thanks -
Help with Action script 2.0 please
Hi,
I am new to actionscript and i could really do with some help
please. I am trying to load external movie clips into two different
containers depending on which button is clicked. Sometimes there
may be two conatiners attached to a buuton click, whilst other
buttons may only need to load one movie clip. Here is the action
script i have been using:
button1.onPress = function () {
_root.createEmptyMovieClip("container", 1);
_root.createEmptyMovieClip("container1", 2);
unloadMovie("container1");
loadMovie("scene2.swf", "container");
loadMovie("scene5.swf", "container1");
container._x = 50 ;
container._y = 110 ;
container1._x = 170 ;
container1._y = 5 ;
button2.onPress = function () {
loadMovie("scene6.swf", "container");
unloadMovie("container1");
container._x = 50 ;
container._y = 110 ;
This does load the movies, however i have to press button one
first before button two will work. Ideally i need to be able to
call any movieclip at any time. Can anyone tell me where i am going
wrong?quote:
Originally posted by:
NedWebs
Try moving these lines outside of the button function:
_root.createEmptyMovieClip("container", 1);
_root.createEmptyMovieClip("container1", 2);
You can use "this" instead of "_root"... that'll save any
problem if you ever move this within some other movie. Also, move
the x/y assignments just under those lines since they relate to
them directly.
Hey thankyou for your help, that works now. although if i
move the x and y assignments i would have to create another
container right? Thanks again for your help. -
Help with Nav Bar using Action Script 3
I am a flash NOOB to say the least. Trying to teach myself. Thank God for YouTube! LOL! Anyway, I have build a Nav Bar for a site that has a sliding bar on the bottom of it that follows the mouse. The problem with this nav bar is that when you change pages inside the site, the slider resets back to position X/Y = 0 and you really don't know what page you are on for sure without me having to identify each page in the page body itself.
Does anyone know of a way using action script to have the URL of the page sent to flash and in turn use that URL to set the X and Y position of the slider to the appropriate X and Y of the button on the Nav Bar for the page the user is on?
I have heard of using flash.external.ExternalInterface but now for sure how this really works nor if I can assign it to a variable for reference inside the action script.
Any help would be appreciated greatly!!The Flash Nav Bar is at the top of each page. But yes, when you click a button inside the flash nav bar it takes you away from your current page and loads a new one. I am trying to tell the swf file which page it is on so I can set the X and Y position of the slider.
You will have to excuse me if I am so noob that I loose any of your replies to this as just as Flash is new to me, so is the lingo.
Thank you for your help. I will research FlashVar but if you have any other ideas then I am open to them. -
Could someone help me with my action script?
I followed a tutorial on how to make an interactive photo gallery but for some reason the file isn't working. I am new to flash and no very little about action script.
Would someone be willing to take a look at my file and advise me?
ThanksDid your tutorial have you download XML from a server to feed the images to the gallery? Many people forget to check for errors loading the XML file or forget to "do something" once the XML is loaded. Common things not to look for are IOErrorEvent.IO_ERROR or SecurotyErrorEvents warning you the XML you're trying to load is on a different domain (a webserver online) and it doesn't have permission (a crossdomain.xml).
In those situations it can appear like it's doing nothing.
Did you just take the code of the tutorial at the end and try to play it as you went through the tutorial? If you just copy and pasted it all you'lre going to have a hard time isolating the issue. In that case you can always re-do the tutorial until you start to see issues. Then you know where they are.
Maybe you are looking for
-
Deat aspects, Recently i have been to ibm interview. I have few doubts to clarify 1.what are the different types of masterdata records? 2.In credit mgnt dynamin credit check we mention horizon period(for eg.40 days) how system knows dis is the start
-
Regarding the event AT SELECTION-SCREEN ON FIELD ..
Hi experts, Can u plz tell the real advantage of the event AT SELECTION-SCREEN ON FIELD than AT SELECTION-SCREEN .. in which type of situations AT SELECTION-SCREEN ON FIELD is needed?? Thanks & Regards, sathish.
-
Error -: AIP-18510: Error adding objects to configuration config for business process cm_all_agreements I am facing this error after importing the export setup in the tutorial X12_buyer_export.xml.Before importing i purged my existing set up .Please
-
Web page not working for vi when launched from testsetand
we've setup a web page for a vi in labview (web publishing tool) and its visible in IE until you close labview this vi is then run from teststand thou the web page isnt being updated? we need to be able to view the contents of the vi remotely
-
after I exit Firefox all downloading in background files are ended without any information about it. Is there a chance to change it ?