Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




Please Check Script



hi, im working with an FLA i downloaded (lets call its Mask) (cant remember where, awhile back) and its in MX format. I opened it up in MX2004 to apply it to my FLA but since its AS 1 and im using AS2 the coding is wrong. in the Mask FLA this is wut it said in the output window)


Code:
Automatic conversion performed to update your ActionScript to Flash MX 2004:
* Functions were converted to the new recommended case (e.g. GetProperty-->getProperty)

Automatic conversion performed to update your ActionScript to Flash MX 2004:
* x op y was converted to Number(x) op Number(y) for operators +, <, >, <=, >=, =, and <>

Automatic conversion performed to update your ActionScript to Flash MX 2004:
* The old equality operator '=' was converted to '=='
original code

Code:
py = getProperty("", _y);
if (Number(/:b)>Number(/:m)) {
setProperty("", _y, Number(py)+Number(((/:b-2)*244-py)*fs));
} else if (Number(/:b)<Number(/:m)) {
setProperty("", _y, py-(Number((2-/:b)*244)+Number(py))/bs);
}
and in my FLA i applied the same script and changed the wut I could understand but im having alot of trouble with it, if someone could give me hand b/c I dont understand operands to good here is the script I used


Code:
py == getProperty("", _y); {
if (Number(/:b)>Number(/:m)) {
getProperty("", _y, Number(y)+Number(((/:b-2)*331-y)*fs));
}else if (Number(/:b)<Number(/:m)) {
getProperty("", _y, y-(Number((2-/:b)*331)+Number(y))/bs);
}
}
}
error message i get


Code:
**Error** Symbol=mc_pics, layer=action, frame=2:Line 2: Unexpected '/' encountered
if (Number(/:b)>Number(/:m)) {

**Error** Symbol=mc_pics, layer=action, frame=2:Line 3: ')' expected
getProperty("", _y, Number(y)+Number(((/:b-2)*331-y)*fs));

**Error** Symbol=mc_pics, layer=action, frame=2:Line 4: 'else' encountered without matching 'if'
}else if (Number(/:b)<Number(/:m)) {

**Error** Symbol=mc_pics, layer=action, frame=2:Line 5: ')' expected
getProperty("", _y, y-(Number((2-/:b)*331)+Number(y))/bs);

**Error** Symbol=mc_pics, layer=action, frame=2:Line 6: Unexpected '}' encountered
}

Total ActionScript Errors: 5 Reported Errors: 5


thanks
Tracy (sorry so long)



KirupaForum > Flash > Flash 8 (and earlier) > Flash MX 2004
Posted on: 01-07-2005, 02:05 PM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

Reality Check: Flash CS3/AS3 Check Syntax
I need a quick reality check. I've finally started playing around in CS3/AS3 on my Mac. Whenever I click "check syntax" I get a very limited error response: specifically, I get actual syntactical errors (e.g., a missing brace or paren), but I get NO COMPILER ERRORS (e.g., use of an undefined method or property). These compiler errors trigger at runtime, but not having them during authoring makes coding and debugging unnecessarily difficult.

Is this really how it's supposed to work?

In Flash8/AS2, we had compile-checking right in the AS file. If I attempted to access an undefined method or property, the error-checker would catch that right away. No time-consuming compile was necessary to catch these obvious errors (see example below). But AS3 doesn't seem to be as clever.

Am I missing something?

Thanks much!

-------------EXAMPLE---------------







Attach Code

import flash.display.BitmapData;

class myClass{

var _bmp:BitmapData;

function myClass(){
_bmp = new BitmapData(500,300);
_bmp.methodNotDefined();//unknown method of BitmapData triggers an error
myVar = 5;//unknown property of myClass triggers an error
}
}

HELP Check Box W/ DYNAMIC Check Value?
I was wondering if you can make the Check Box component have a dynamically-loaded check value.

I would like to have it read the "&price1" variable from a text file.

If you know how to do this, please help.

thanx!

Check This Out
I'm quickly learning that people are all very opinoniated
but none to helpful

In need of help with the flash guestbook

CHECK IT OUT IT'S MY FIRST
I JUST finished my very very first fully actionscripted movie. It's a very very small file, the swf itself is LESS than 1kb, and I'm so very proud of it. Check it out here http://www.skycastleprod.com/demo/aboutintro.html
Anyways, I know this is soooo easy for some of you guys, but I'm so happy and proud of it that I thought I'd post it here. It's generated randomly every single time, and all of it is done using one movie clip. Anyways, I'm just really happy!!!! Have a nice day!

Riki

Can Somebody Please Check This
Hello,

I have just about had it with this thing. I am not that proficient in actionscript and would really love to learn a few things for starters:

I have two buttons forward & next

Next button:

on (release) {
_root.text.gotoAndStop(_currentframe -1);
}

&

Forward button:

on (release) {
_root.text.gotoAndStop(_currentframe +1);
}

I have a text box on my main timeline called text and I am calling external files with links above it. How do I get these buttons to work properly? Is it possible to record which page the user has last viewed in a textbox.

Any advice on this would be very helpful. I already have the links working to load the files it is the functionality that I put on those buttons that is giving me lots of trouble.

Thanks

WOW Check This
WOW! check out this site it is an insperation to new flash users like myself just thought i would share it with you. Go to http://www.brainwaves.nl/ and click FLASH HIGH END

Can Someone Check This?
I basicly have a puzzle. I have buttons inside of MC which are the pieces to puzzle, with the script below on each button. Everything works fine except the _rotation part. Is my logic wrong or syntax??

Note: The z is and instance of the same MC. It is used to have to pieces snap into place.

on (press) {
grab = true;
if ((_x != _parent.z._x) && (_y != _parent.z._y)) {
startDrag ("");
}
}
on (keyPress "<Space>") {
if (grab == true) {
this._rotation = 90;
}
}
on (release) {
grab = false;
stopDrag ();
if ((_x != _parent.z._x) && (_y != _parent.z._y)) {
if (this.hitTest(_parent.z)) {
_root.i++;
_x = _parent.z._x;
_y = _parent.z._y;
}
}
}

CHECK IT OUT
I thought the title might bring more people to help me, im still working on that Skull smiling etc.
the picture is on
http://www.geocities.com/corruptedrebels/skull.jpg

when i use the pointer tool to distort it
(make the mouth drop) for some reason it creats a NEW skull picture

IM DESPERATE HELP PLEASE
needs to be done

Please Check This Out
When this action script is executed from a button:

on (release) {
gotoAndStop (56);
}

It plays the movie on frame 56. The movie plays and stops. But when I click on the same button again, it wont play the movie again. Any hints??? Thanx in advance!

Check This Guy Out LOL
http://www.useit.com/alertbox/20001029.html

"Summary:
Although multimedia has its role on the Web, current Flash technology tends to discourage usability for three reasons: it makes bad design more likely, it breaks with the Web's fundamental interaction style, and it consumes resources that would be better spent enhancing a site's core value. "


wow what a dork

Planethouse

Ok..Check This Out
Im sort of *new* at this..I know alot..But i dont understand where u put the codes,such as if you want a Loading bar... PLEASE help me..

Check This Out
What would be the best way to replicate the opening image at http://www.atelier-image-in.com and the scrolling buttons whenever you click on any portfolio item? I've seen a couple of tutorials for the scrolling items, but none come close to that. I would appreciate any response. Thanks.

Check This Out
im loading jpegs dynamicly....how to put preloader on each of them or something similar to tell to the user that image is loading...

i cannot solve this problem with my main preloader ...is start show itself after 30% ..any idea please guys...
thanks

Itīs Just A Little Help I Think But I Donīt Check It
I have a little flashmenue in a html document. The Rest is just text with a few anchors. I want to know what should i put in the flashmenue that it will link to each anchors i wanted to?

Example: Services - link to the bottom of the text to the anchor named "services" ...

please help me - Iīm getting crazy....

Check If You Got One
Is there any method by which it can be found out that the person who is viewing my web site doesn't have flash player....and to display him a message to download the flash player if doesn't have it?

On Top Check
is there a way for action script to detect if the Standalone FlashMX player is on top or not ????

i wan't to make a Standalone EXE menu with a nice BG music that can launch exe's so when an exe is started the sound has to stop and when the exe is closed the sound has to continue

i tought the best way to do this is with an on top check from the player , but i have no clue how to do this...... PLZ help me

Check This Out
while trying to find out how to link to applications/folders on the user's computer in Flash, i found this:

http://www.virtualplastic.net/html/art_htm.html

check the last paragraph on section 1, where he says:

"If you would like to use scripts (onClick...) change the url by scripting using window.location.href="run:x:pathexecutable.exe"; or if this doesn't work (?) with a double url change: window.location.href="javascript:window.navigate( "run:"+appName+"")";. In this case don't forget to double the backslashes if you use them. You can download a zipped .js file containing a small Open() function that does this here."

there's gotta be a way to make this work in flash, to get a button in Flash to link to a file/application/etc. is there any way?

let me know please
stealth_space@hotmail.com

thanks
~Lorenzo

Check This Out
http://www.idefilm.se/Robot/robot.htm

I am really bad at modelling in 3dmax and i need some help.
I have made the modell above in swift 3d v3, but it's not at all like i want it to be ( more complex ). Could someone give me some pointers or even take a crack at it. I only need a 3ds fil then i can animate it in swift.

please someone!!

ps. the link is in swedish but I think you will get the hang of it.

Please Check This For Me
Could someone smarter than myself check this code and tell me if it should do what its meant to do.
It's code on a square shaped mc, and a ball(mc) is meant to bounce off each side. ie. hit the left side of square and ball bounces back left. etc..( in effect making it a solid object)

if (this.hitTest(_root.ball)) {
location = this.getBounds(_root);
if (_root.ball.nowBx < this.location.xMax -1) {
_root.ball._x -= 5;
_root.ball._rotation = -_root.ball._rotation;
}
if (_root.ball.nowBx > this.location.xMin-1) {
// bounce ball back left
_root.ball._x += 5;
_root.ball._rotation = -_root.ball._rotation;
}
if (_root.ball.nowBy < this.location.yMax -1) {
// bounce ball back down
_root.ball._y -= 5;
if (_root.ball._rotation>=0) {
_root.ball._rotation = 180+_root.ball._rotation;
} else {
_root.ball._rotation = -(180-_root.ball._rotation);
}
}
if (_root.ball.nowBy > this.location.yMin-1) {
// bounce ball back up
_root.ball._y += 5;
if (_root.ball._rotation>=0) {
_root.ball._rotation = 180-_root.ball._rotation;
} else {
_root.ball._rotation = -(180+_root.ball._rotation);
}
}
}

Can You Check This?
Hello - I was just wondering if some of you could go to the url below and see if my preloader is working for you correctly....it's a spinning disk that says loading. Once you see the text and stars come in the movie has started. Thanks....Jay.

http://arisingstarproduction.com/index4.htm

Check This Out
can sum1 plz check out my site n let me know if the preloader is working.

i have broadband so i can't tell and iv been havn sum probs with it.

could sum1 help me.. plz

www.wrighteousdesign.co.uk

Check This Out
http://www.deltalight.com

For some reason it doesnt fully load on my computer.

Check This
Hi, everyone,

It's a cool effect.But I couldn't figure it out.

http://hjjp.tianshui.net.cn/mac/ppqw.swf

Anybody has idea?

Check If A Var Is Set
Hi all!

I need to check if a variable is set or not, a load some dynaic data in a array, and in some cases I read some places that are not set, when I trace such a value I get "undefined" in the output. But how do know in my script it's not set?

I know in in php it's done like this:


Code:
if(!isset($varname)) echo "this var is not set";
But howto in actionscript? anybody?

Thanks

Check This Out Ppl
My new site has just been released.
Please check it out at http://www.arcadeplus.dot.nu

The site contains some games I made in Flash MX.
The site is almost complete but I just need to
finish a few pages and work on more games.
I will be making tutorials, releasing my code
and giving away my FLA's quite soon.

Please tell me what you think of the site and,
the games, and please tell me what I can do to
make them better.

You can also get into contact with me:
ICQ#: 164274942
Email: dcjnaughton@hotmail.com
MSN Messenger: dcjnaughton@hotmail.com
Yahoo! Messenger ID: declan_naughton

Good people get FLA's!

Thanks in advance,
- Declan

.txt Check
I have a movie with 4 scenes with 4 points each that come up one at a time that runs from a set location (not online) so the content being pulled is a .txt file in the same location using the loadVariables.

Now, I want to use actionscript to check the .txt file before each point to determine if it should A. continue (because there IS a next point) or B. go to the next scene (because there IS NOT a next point).

Any help would be appreciated.

Can Someone Check This Please ?
okay.. i give up... can anyone tell me why this dont work ???
you need to create a movieclip on the time line called menu...

any ideas ???

++++++++++++

menuItems = ["[ info ]", "[ gallery ]", "[ us ]", "[ shop ]", "[ artists ]"];
setInterval(mainNav,100)

opt = -1;

function mainNav() {
if (opt<menuItems.length-1) {
++i
duplicateMovieClip("menu", "menu"+i, i);
this["menu"+i]._y = ((opt+1)*12)+80;
this["menu"+i].word.text = menuItems[i];
this["menu"+i]._name = menuItems[i];
++opt
trace(opt)
}
}

How Do You Check If The Key Is Up?
How do you check if a certain key is up?

Check Box
Hi,

is it possible to get rid of the label area, in a checkbox, so that you can only click on the actual checkbox itself, and not the label beside it, to change its state?

thanks

phil.

Help Check....
http://www.hatfieldphoto.com

I want to find out if it loads correctly and how fast it is.
thanks alot!

send feedback to:
derek@hatfieldphoto.com

Check Box
Hello,

I flash mx (not mx pro) how do I get a value set in a textbox when the user click on a check box?

Thank you.

Check It Out...
I am a rookie at flash and need some desperate help.

I am working at creating my first movie. When I "test movie" everything in the movie keeps repeating itself over and over again. How do I fix this?

Thanks for your help.

Jeremy

AS Check
My clip works fairly well, but I notice it hangs every so often...any suggestions the AS gurus could give me would be greatly appreciated.

onClipEvent (enterFrame) {
// timer ----------------------------------
if (_root.delay == true) {
if (Math.floor(getTimer()/250) == _root.lastTime+1) {
_root.delay = false;
}
}


// action for timer ----------------------------------
else if (Math.floor(getTimer()/250) == _root.lastTime+_root.wait) {
_root.lastTime = Math.floor(getTimer()/250);
_root.delay = true;
_root.artistMC.layersMC["sphere"+_root.count].gotoAndStop(_root.frame);
if (_root.count >= 10) {


// set name text from array ----------------------------------
if (j >= _root.artistLength){
j = 0;
}
else {
j++;
}
_root.artistMC.nameMC.artist = _root.artist[j];
if (_root.artistMC.nameMC.pause == "yes") {
_root.artistMC.nameMC.gotoAndPlay(6);
}
else if (_root.artistMC.nameMC.pause == "no") {
_root.artistMC.nameMC.gotoAndPlay(2);
}
else {
_root.artistMC.nameMC.pause == undefined;
_root.artistMC.nameMC.gotoAndPlay(2);
}


// variable to determine background state and reset action ----------------------------------
if (_root.frame == 1){
_root.frame = 2;
}
else if (_root.frame == 2) {
_root.frame = 1;
}
_root.count = 1;
}


// increase count to loop action----------------------------------
else {
_root.count++;
}
}
}

Could Someone Check This Out..
I'm towards the end of my second flash site and I'm having problems with skippyness. Also, I want better movie quality. Can anyone tell me the best looking clearest way to do video that doesn't skip.
Thank you,Liz
http://www.dbem.net/screen.html

Please Check This Out
Hi,

Please download my .fla and check it out.

I have a movieclip that slides up when rolled_over. Inside this movieclip i have a simple button. The problem is that this button can't seem to be rolled_over.

I know I have done something wrong, is there any easy way around this?

Thanks

Chris

Check This Out
ok so i transfered my flashsite into a full html site, with the iframe i wanted in the right middle. now, before i turned my full flash site into a flash/html i had my flash site set up like this

on frame one was my preloader movie clip, then goto and play 2 and stop and that was my main movie, worked nice but since i have it as an html site not flash thierfore not frames how can i make a preloader load a flash site? maybe on load goto and play ( get url) ?? i dunno help !!


[edit] heres my old code


perc = Math.round((_parent.getBytesLoaded()/_parent.getBytesTotal())*100);
xperc = perc/100;
barlength = 200;
if ((perc == 100) and (bar._width == barlength)) {
_parent.gotoAndPlay(2);
} else {
nperc = perc+"%";
bar._width = barlength*xperc;
bar._x = -100+(bar._width/2);
}

Check It Out :-)
Been playing around with Photoshop CS and Flash MX 2004 for a couple of days and this is what i came up with :-) A menu for a website, complete with a digital display and power on/off button LOL!

Im a newbie for both flash and photoshop but learning fast, and its fun! :-)

Theres no actionscript in this one, except for two STOPīs and the button actions... i donīt know any actionscript yet...

Give me some feedback please!


i hope i can attach an .swf...or this post is gonna look weird...

:-)

/Knop

Check It Out.
When I post my flash project to the net it is much slower. Before I posted my project to the net it matched perfectly with the background music. However, after posting the .swf file to internet it is totally out of sync. The music ends and the animation is still continuing. Does anyone know how to fix this?

Check This Out And See If You Can Tell Me How They Did It
Just out of curiousity, anyone here know what it takes to make a flash page like this one? it's very impressive stuff...i'm just courious-who knows, i may make something with similar script in the future~

(oh yeah, i guess what i especially want to know is how they got the animated little birdie to follow your mouse...and you can switch birdies too if you play around with it...)

check it out here:
http://www.wwd07.com/worldwide.html

Check This Out And See If U Can Tell Me How They Did It
Just out of curiousity, anyone here know what it takes to make a flash page like this one? it's very impressive stuff...i'm just courious-who knows, i may make something with similar script in the future~

(oh yeah, i guess what i especially want to know is how they got the animated little birdie to follow your mouse...and you can switch birdies too if you play around with it...)

check it out here:
http://www.wwd07.com/worldwide.html

Check In Check Out
Recently found a check in/check out feature in Dreamweaver and was wondering if Flash has a similar feature that I'm unaware of...

Any takers?

Many thanks in advance!

Check This Out
I just made something for a new homepage. Check it out.

Click on it to make it react:

http://stephan.syska.dk/flashting/bu...bubbles14.html

Tell me what ya think!

Check If Swf Or Exe
hi,

is it possible to find out if the playing movie is an exe or swf.
thanks
khan

Check For Me, Please...
http://blake.prohosting.com/~tektips...ript/dhtml.htm

I've set up this movie with a javascript detection bit, that monitors the mouse being over the movie area or not.
If you hover the bottom of the movie, a nav bar should appear, and it should close if you hover upwards, if the mouse cursor remains within the movie area.
Now, on the other hand, if you leave the movie area through the bottom or sides of this nav bar, the hitTest is no longer detected, so the nav bar stays up.
I've thus coded this so that a mouse click on the movie's surrounding html area (or on the "target" button), closes the nav bar.

This all works fine for me on Windows, and IE5.5...
What I'd like to know, is does it work for you all or not, and on what OS and/or browsers, does it work or not...

Thanks!

Check This Out
I've seen this navigation on several sites, but can't pinpoint the name or an fla file of it. Here's a sample of the effect I am speaking of:

www.poloto.com

Click on gallery. The navigation using the photos rotating.

Check Box Php
Hi.

I'm using a standard flash check box component as part of an information form. I want to be able to set up the check box so that when it is selected the associated php script shows that the box has been ticked when the user choses to email the information.

I understand how I would do this if it was text in a input text box. But does anybody know how to get the same effect with a check box component? What do I need to do to the component and what do I need to add to the php?

The php script is shown below. Name, email and telephone are gathered from input text boxes in flash.


PHP Code:



<?php
$name = $_POST["name"];
$email = $_POST["email"];
$telephone = $_POST["telephone"];
$message = str_replace("
", "
", $_POST["message"]);
$message = "THE FOLLOWING INFORMATION WAS SENT:

name:        $name
email:        $email
telephone:    $telephone
    

$message

";
mail("something@something.com", "WEBSITE FORM TEST", $message, "From: $email");
?>




Also, would the same principle work for a combo box?!

Thanks

Check Box
I'm making a web site, and i want to make a check box with "music on/off".

Does anybody know which codes i must use to make this work?

Check This Out
Okay, I created a transition effect and now I really want to know what people think about it. Check out the .fla file I attached.

I'm curious if you who are reading this, could recommend a better way to create the transition. I have a feeling that the way I created it is sloppy and my stage would end up being very cluttered and confusing if I was to add more buttons that linked to additional scenes... Is this true? Or is the way I did it the only good way that exists?

BTW, Here's my past post so you can understand what I'm trying to accomplish:

----------------------------------------------------------------

Okay, need some help with Flash MX 2004 because the program's being a pain in the ass. Here's what I'm trying to do:

1) How do I make a transition effect from one scene to another without using the "loadMovie" command to load other .swf files?

I checked the kirupa.com tutorials but they won't work for what I need because the project I'm working on can't use external SWFs. It has to be one single projector.exe file when I'm all done with everything.

Any help would be totally awesome!
Thanks!

Check This...
details version of my problem

http://www.portfolio.amansingh.co.uk/PROBLEMS.rar

Could U Check This? Please
Hi experts out there,
could u check the script ? and tell me where i am going wrong? Please help me.

In flash i have two frame
Flash code:(First Fame)


PHP Code:




var myXML:XML = new XML();
var links:Array = new Array();
myXML.load("myMenu.xml");
myXML.ignoreWhite = true;
myXML.onLoad = function (success:Boolean){
    if(success){
        
    menuItem = this.firstChild.childNodes;
    
    _root.gotoAndStop("success");
    }
}
stop();







Second Frame


PHP Code:




for (var i = 0; i<menuItem.length; i++) {
            item = loadHere.attachMovie("itemClip", "itemClip"+i, i);
            item._x = 0;
            item._y = 20*i;
            item.itemLabel.text = menuItem[i].attributes.name;
            item.movieUrl = menuItem[i].attributes.movieUrl;
     item.onRelease = function() {
      _root.container.loadMovie(this.movieUrl);
                };
        }

        for (var j = 0; j<menuSub.length; j++) {
            sub = loadHere.attachMovie("subClip", "subClip"+j, j);
            sub._x = 0;
            sub._y = 20*j;
            sub.subLabel.text = menuSub[j].attributes.name;
            sub.movieUrl = menuSub[j].attributes.movieUrl;
     sub.onRelease = function() {
      _root.container.loadMovie(this.movieUrl);
                };
        }







XML Code


Code:
<?xml version="1.0"?>
<myMenu>
<myItem name="Profile"/>
<mySub name="About Us"movieUrl="aboutus/aboutus.swf" />
<mySub name="Carlson Wagonlit Travel"movieUrl="aboutus/aboutus.swf"/>
<myItem name="Services"/>
<mySub name="Fedral Travel Management" movieUrl="services/services.swf" />
<mySub name="Business Travel Management" movieUrl="services/services.swf" />
<mySub name="Leisure Travel" movieUrl="services/services.swf" />
<mySub name="Travel Insurance" movieUrl="services/services.swf" />
<mySub name="Visa Assistance" movieUrl="services/services.swf" />

<myItem name="International Travel Information" movieUrl="international/international.swf" />
<myItem name="Resources" movieUrl="resources/resources.swf" />
<myItem name="Career" movieUrl="career/career.swf" />
<myItem name="Contact us" movieUrl="contact/contact.swf" />
<mySub name="Address Details" movieUrl="contact/contact.swf" />
<mySub name="Feedback" movieUrl="contact/contact.swf" />
</myMenu>




What i exartly want is
for this
PHP Code:




<myItem name="... />





tag i want the flash load "itemClip" attached movie clip

and

for this
PHP Code:




<mySub name="... />





tag i want the flash load "subClip" attached movie clip.

i think i am doing some mistake please help me to code this.
i have attached the files.

Copyright Đ 2005-08 www.BigResource.com, All rights reserved