divinedesigns1 Posted April 29, 2012 Share Posted April 29, 2012 (edited) hey i been trying to do this loading thingy but i have no idea how to fix these 2 last errors Scene 1, Layer 'action', Frame 1, Line 2 1078: Label must be a simple identifier. and Scene 1, Layer 'action', Frame 1, Line 4 1071: Syntax error: expected a definition keyword (such as function) after attribute and, not font. and this is my codeimport flash.text.Font;font-family: "Time New Roman";property:fontFamily = "Time New Roman";and font-weight: "Time New Roman";property:fontWeight = "Regular";Font.registerFont(mytext);function loadProgress(my_content:ProgressEvent):void { var percent:Number = Math.floor( (my_content.bytesLoaded * 100) / my_content.bytesTotal );mytext.text = percent + "%";circularloader.gotoAndStop(percent);}function loadComplete(e:Event):void {currentFrame + 1;}loaderInfo.addEventListener(ProgressEvent.PROGRESS, loadProgress);loaderInfo.addEventListener(Event.COMPLETE, loadComplete); can anyone say whats wrong here? Edited April 29, 2012 by DDs1 Link to comment Share on other sites More sharing options...
Ingolme Posted April 29, 2012 Share Posted April 29, 2012 This doesn't look like valid Actionscript: font-family: "Time New Roman"; The first part is subtracting "family" from "font", the colon indicated a typed variable except there's no name after it. Then you have a string after that. Link to comment Share on other sites More sharing options...
divinedesigns1 Posted April 29, 2012 Author Share Posted April 29, 2012 (edited) This doesn't look like valid Actionscript: font-family: "Time New Roman"; The first part is subtracting "family" from "font", the colon indicated a typed variable except there's no name after it. Then you have a string after that. oh, i rewrote the script and didnt need those code anymore 0.o but now im having this annoying errorScene 1, Layer 'action', Frame 1, Line 5 1086: Syntax error: expecting semicolon before Number.there were other errors in this code also which i can easily fix but this one is giving me a bit of a problemimport flash.events.ProgressEvent;import flash.events.Event;function loadProgress(my_loader:ProgressEvent):void{var percent Number = Math.floor( ( my_loader:bytesLoaded * 100 )/ my_loader:bytesTotal );MyLoadText.text = percent + "%";preloader.gotoAndStop(precent);}function loadComplete(e:Event):void{currentFrame +1;}loaderInfo.addEventListener(ProgressEvent.PROGRESS,loadProgress);loaderInfo.addEventListener(Event.COMPLETE,loadComplete); not too sure where the semi colon have to go, i been moving it around on that line to match what the error is saying but did not work or do i have to remove something? since thats how i fixed the last erroralso if i placed the semicolon before Number, that wouldnt make much sense since semicolons are for ending a statement, etc. But i tried it and it outputted another error asking for a colon var percent; Number = Math.floor( ( my_loader:bytesLoaded * 100 )/ my_loader:bytesTotal ); so that above quote wouldnt work, now ill try to figure it out when i wake up Edited April 29, 2012 by DDs1 Link to comment Share on other sites More sharing options...
dsonesuk Posted April 29, 2012 Share Posted April 29, 2012 gotoAndStop? precent or percent, that is the question Link to comment Share on other sites More sharing options...
divinedesigns1 Posted April 29, 2012 Author Share Posted April 29, 2012 gotoAndStop? precent or percent, that is the question ............. thank you ill correct that Link to comment Share on other sites More sharing options...
divinedesigns1 Posted April 30, 2012 Author Share Posted April 30, 2012 that didnt fix the error still getting the output error Scene 1, Layer 'action', Frame 1, Line 5 1086: Syntax error: expecting semicolon before Number. Link to comment Share on other sites More sharing options...
divinedesigns1 Posted April 30, 2012 Author Share Posted April 30, 2012 i think i fixed the problem 0.o not too sure tho Link to comment Share on other sites More sharing options...
divinedesigns1 Posted April 30, 2012 Author Share Posted April 30, 2012 (edited) what does this mean? TypeError: Error #1010: A term is undefined and has no properties.at Flashwebsite_fla::MainTimeline/loaderF() error fixed, was a misspelled word again Edited April 30, 2012 by DDs1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now