[Flashcoders] making a set of dynamically loaded buttons to listen to each other
I need a help ! I a working on application where i have a set of 10 buttons. I want that when one of them is clicked the others disappear or do anything else that is assigned to them. I cant figure out how to make each button to listen to event of the others in a simple way ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Re[2]: [Flashcoders] OT: Pirated Books
Hello Andrew, RA Piracy: The unauthorized reproduction or use of a copyrighted RA book, [...] - hmmm... I understand reproduction rule, but use I don't understand. Is libraries closed in your country? Or you need special license to give your book to girlfriend? Mistake of Omar is reproduction in his actions. But for example if he have e-book on CD and gives this CD to anybody... is he pirate too? -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] ActionScript syntax highlighter
Hello, oops. I has found a bug. page is removed. I'm sorry. I http://www.bezier.ru/marker/ I - you can use it offline: swf only needed. -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] ActionScript syntax highlighter
Hello, http://www.bezier.ru/marker/ - you can use it offline: swf only needed. -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] ru.bezier geom package beta
Hello, beta version of bezier.ru geom package: http://www.bezier.ru/rus/AS2/sources/ru.bezier.zip (now comments in russian only). please send me private bugs and requests. good luck, iv -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders]problem with embeded fonts
Hello Esther, short article: http://www.sharedfont.com/eng/faq.html#include EF I'm using Flash 8 Proffessional. EF I have created dynamic text with the authoring tool, embeded the font EF outlines I want to use and created a font symbol in the library (with all EF the options I need). The dynamic text then uses this font. EF At runtime the text is not displayed when my function gives value to my EF dynamic text like this: EF mytext.text='string'; EF I have set some static text in the dynamic text box to test if this only EF happens at runtime with the generated values. I see the text then, which EF means font outlines are being embeded, only I can't see the text generated EF by my code, which also is there, as the code works correctly with device EF fonts, and which I can see doing a trace like trace(mytext.text) EF I can't figure out what is wrong. Any clues? -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Art oriented uses/examples of Flash
Hello Roy, http://www.conclave.ru RP Nice to see the links that people are sharing @ best Flash projects. If RP it's not too much OT, I'd be very interested in links that folks may have RP to specifically art-oriented projects (e.g fine RP art/conceptual/performance/installation type stuff). -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Problem with cascading functions within a class
Hello Andrew, public function grabHTML():Void { var html_data:LoadVars = new LoadVars(); var grabber = this; html_data.onData = function():Void { grabber.doSomething(); }; html_data.load(http://somesite.ca/some.html;); }; -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] finding out which fonts are embedded in aswfatruntime?
Hello Zarate, AS1-AS2 http://www.sharedfonts.com in AS3 it's built in future. Z My feature list would be: Z - Clean, easy, official way to create a swf with one/various fonts. Z - Being able to load at run-time that swf and easily apply those fonts Z to any TextField. Z - Being able to query the swf to get information about the font, Z embedded glyphs, etc. -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] finding out which fonts are embedded in aswfatruntime?
Hello Zarate, 2005 Apr 22 http://chattyfig.figleaf.com/pipermail/flashcoders/2005-April/137682.html -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] syntax highlighting
Hello, Almost every programmer sets his own code highlighting style and gets used to it to the point, that any other highlighting style makes it more difficult for him to read the code. Users of programming-related sites would be pleased to have a possibility to set their own personal code styles. Evidently, setting the right style for every site you read through is annoying. What if you could set the style once and make it somehow propagated to the code listings on every site you visit? Here comes the solution: (for now PC only) - First visit http://www.bezier.ru/ei/. Make and save your highlighting settings there. - Go to http://www.sharedfont.com/ei/ and press the apply button. You should see your setting in effect. The service use no server scripting and can be easily adjusted for any programming language. For this service to launch and spread, it must be appropriately hosted by some well-known project or company domain. I think, this should be interesting for Eclipse, DoxyGen etc. Should you have anything to suggest concerning this project, please drop me a private message. Any thoughts and ideas are highly appreciated. Thank you. -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] syntax highlighting
Hello Michael, MS i wonder how much code can be highlighted without getting slow. MS that is not meant to criticize your work, don't get me wrong. - tons. only css changed on the fly. no more. everybudy can get full project from his browser cache if needed. no any server side scripts. -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] syntax highlighting
Hello Jason, I think a fiels standard of code html-formatting is needed. In this case is it possible to do many tools used one standard. In another case no one parser can't work properly. For create standard and make it popular big members must use and support it. I think it's possible and very simple. For example in our field Adobe declaration of AS code html-formatting standard is enougth for start support this standard by big number of developers. JB I think what I'm getting at is that to really be useful, it ought to scan JB the document for code elements, then parse the text of these nodes, JB applying styles (or adding classed span tags or whatever) to the words JB based on a look-up of keywords, and syntax checking etc. This way, it truly JB could be used on any page that uses code to show code, and could be easily JB extended to allow users to specify which language to use (AS, Java, etc). JB Would make a nifty extension for Mozilla-based browsers, for instance. If JB you don't have all the skills to put together these pieces, would be a good JB project for SourceForge or something. JB I think if you are relying on programmers to pretty-up their code listings JB in HTML, you arent gonna see much use, and also if programmers wanted to go JB to the trouble of doing this, would not be any real extra effort to write JB the CSS. -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[4]: [Flashcoders] syntax highlighting
Hello Jon, Hello Jon, JB Problem 1 is that the tool is re-writing the HTML content of the JB page, which I don't particularly like. - one CSS only. I don't see any problem here. JB It's a great thought, but Flash projects that take text input and JB parse and display it with a user-customizable color space are JB already out there. - yes. I know. But flash solution have much bigest minuses: 1) forget about search engines 2) my idea about cross-domain user settings not implemented yet :) JB Problem 2) there are no standards. I don't like the Adobe JB highlighting standard. Friends of mine that are colorblind have JB their own issues to deal with when it comes to syntax JB highlighting. - I talk not about colors standard. I talk about list of types and corresponding css class names. something like: CSS class name: void Description: Base types 'Void' Members: Void CSS class example: .void { color:#FF; font-weight:normal; font-style:normal; } Usage: function MyFunction ():span class=voidVoid/span {} -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[4]: [Flashcoders] syntax highlighting
Hello Jon, In any case presence of field standard is much better than lack. Developers can use and support it in his projects if standard defined. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[4]: [Flashcoders] syntax highlighting
Hello Jon, JB Problem 1 is that the tool is re-writing the HTML content of the JB page, which I don't particularly like. - one CSS only. I don't see any problem here. JB It's a great thought, but Flash projects that take text input and JB parse and display it with a user-customizable color space are JB already out there. - yes. I know. But flash solution have much bigest minuses: 1) forget about search engines 2) my idea about cross-domain user settings not implemented yet :) JB Problem 2) there are no standards. I don't like the Adobe JB highlighting standard. Friends of mine that are colorblind have JB their own issues to deal with when it comes to syntax JB highlighting. - I talk not about colors standard. I talk about list of types and corresponding css class names. something like: CSS class name: void Description: Base types 'Void' Members: Void CSS class example: .void { color:#FF; font-weight:normal; font-style:normal; } Usage: function MyFunction ():span class=voidVoid/span {} -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Override _xscale and _yscale setter in AS2
Hello Patrick, PMB Anybody has any other idea ? owerriding or watch of properties is impossible. Don't use extending. Use composition: class Test1 { private var __mc:MovieClip; public function Test1(mc:MovieClip){ this.__mc= mc } public function get _xscale ():Number { return this.__mc._xscale; } . etc } -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] createTextField and embedding fonts
Hello orangeflower, http://www.sharedfont.com/eng/faq.html#include ohc I'm sorry to do this and I'm sure someone has an explanation here, but I'm ohc at my wit's end. ohc I have an empty swf that is loading another swf with all of my views, assets ohc etc. I am creating ohc a font symbol in the view swf's library to be used later by dynamic ohc TextFields. The font symbol ohc is being exported for ActionScript and has a linkage identifier. From the ohc container swf I'm ohc dynamically creating dynamic TextFields within the view swf and setting ohc the embedFonts and ohc text properties appropriately like so: ohc textTitleFormat = new TextFormat(); ohc textTitleFormat.font= AkzidenzGroteskBE; ohc textTitleFormat.color = 0x51433D; ohc textTitleFormat.align = left; ohc textTitleFormat.underline = true; ohc textTitleFormat.size= 24; ohc titleText = curProductText.createTextField(Title + _ + date.getTime(), ohc curProductText.getNextHighestDepth(), this.View.copyBox.Title._x, ohc this.View.copyBox.Title._y, this.View.copyBox.Title._width, ohc this.View.copyBox.Title._height); ohc titleText.text = title; // where title is a string; this is tracing out the ohc value I expect ohc titleText.type = dynamic; ohc titleText.embedFonts = true; ohc titleText.antiAliasType = normal; ohc titleText.setTextFormat(textTitleFormat); ohc The question I have is it possible to apply a TextFormat to a TextField ohc using an embedded font that is NOT ohc in the container swf's library? If not then that is my problem and I think I ohc can use shared libraries to counter ohc this behavior. Either way, I was wondering if someone could clarify some of ohc this for me. ohc Thanks, ohc Thomas ohc ___ ohc Flashcoders@chattyfig.figleaf.com ohc To change your subscription options or search the archive: ohc http://chattyfig.figleaf.com/mailman/listinfo/flashcoders ohc Brought to you by Fig Leaf Software ohc Premier Authorized Adobe Consulting and Training ohc http://www.figleaf.com ohc http://training.figleaf.com -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] dynamic runtime sharing Q
Hello John, www.sharedfonts.com JP ie : I have 5 fonts in the library that are importing runtime shared JP swf's. what if, based on a variable passed into the main swf, only 1 of JP these is needed. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] if logical operator
Hello Eduardo, var list_arr:Array = [12, 34, 21, 46, 52]; ... a++; var search_str:String = |+a+|; var list_str:String = |+list_arr.join(|)+|; if (list_str.indexOf(search_str) == -1) { // do something } EB given a list of numbers such as: (12, 34, 21, 46, 52 ... ) EB what would be the best way to achieve this: EB a++; EB if ( a != 12 a != 34 a != 21 a != 46 a != 52 ... ) { EB // do something EB } EB Am doing my research and trying out some solutions but i thought that in the EB meantime someone may have a quick ready answer for this or some good hints. EB thanks a lot! EB Eduardo EB ___ EB Flashcoders@chattyfig.figleaf.com EB To change your subscription options or search the archive: EB http://chattyfig.figleaf.com/mailman/listinfo/flashcoders EB Brought to you by Fig Leaf Software EB Premier Authorized Adobe Consulting and Training EB http://www.figleaf.com EB http://training.figleaf.com -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] if logical operator
Hello Chester, - yes, it's very good way if array is not changed. but testNumber method is unnecessary: // prepare: var nList_array:Array = new Array(12, 34, 21, 46, 52) var nList_object:Object = new Object(); for (var i:Number = 0, len:nList_array.length; ilen; i++){ nList_object[nList_array[i]] = true; } .. // check a++ if (!nList_object[a]) { // do something } -- good luck, iv CM Why not throw another option in the mix :) CM I think this one is more efficient because it only loops through the CM number array once at the beginning... but I'm not an optimization CM expert. CM // define your array of bad numbers CM var nList_array:Array = new Array(12, 34, 21, 46, 52) CM // create an object with a boolean value for each bad number CM var nList_object:Object = new Object(); CM for (var i:Number = 0; inList_array.length; i++){ CM var num:Number = nList_array[i]; CM nList_object[bad+num] = false; CM } CM // create a function to test a number; CM function testNumber(num:Number):Boolean CM { CM if (nList_object[bad+num] === false){ CM return false; CM } else { CM return true; CM } CM } CM // Now test it CM for (var i:Number = 0; i100; i++){ CM if (testNumber(i)){ CM trace(doing something with +i); CM } else { CM trace(BAD NUMBER: +i); CM } CM } CM On Dec 20, 2006, at 4:42 PM, Eduardo Barbosa wrote: Hi all, given a list of numbers such as: (12, 34, 21, 46, 52 ... ) what would be the best way to achieve this: a++; if ( a != 12 a != 34 a != 21 a != 46 a != 52 ... ) { // do something } Am doing my research and trying out some solutions but i thought that in the meantime someone may have a quick ready answer for this or some good hints. thanks a lot! Eduardo -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] MC Tween Problem - Urgent
Hello Berkay, do not use Array.prototype. you can change this code very quick: function inArray (array:Array, what:Object):Boolean { for( var a = 0; a this.length; a++ ) { if( this[a] == what ) { return true; }else if(this[a] instanceof Array) { return inArray(this[a], what); } } return false; } -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] MC Tween Problem - Urgent
Hello Berkay, - this solution is step to next problems only. BU its resolved by adding a ASSetPropFlags(Array.prototype, inArray, 1, 0); BU code line after the declaration of the prototype -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Area of a triangle using perimiter values only
Hello Jason, public function getTriangleArea (a:Number, b:Number, c:Number):Number { var p:Number = (a+b+c)/2; return Math.sqrt(p*(p-a)*(p-b)*(p-c)); } -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Area of a triangle using perimiter values only
Hello, TMK Actually, this does return NaN for some numbers, but it's pretty TMK simple to realize why. For example, it returns NaN if you input side TMK lengths of 1, 2, 4. - it is not triangle. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Create movieclip path within a class
Hello Paul, PS var vBoiler_Obj:Boiler = new Boiler(vBoilerRef); - this line incorrect. use create method public static function create (this_mc:MovieClip, name:String, depth:Number, init_obj:Object):Boiler { var new_mc:MovieClip = this_mc.createEmptyMovieClip(name, depth); var current_constructor:Function = Boiler; new_mc.__proto__ = current_constructor.prototype; var out_mc:Boiler = Boiler(new_mc); for (var i:String in init_obj) { out_mc[i] = init_obj[i]; } current_constructor.call(out_mc); return out_mc; } and call: var depth:Number = this.getNextHighestDepth(); var vBoiler_Obj:Boiler = Boiler.create(this, vBoilerRef, depth) PS: Template for FDT: public static function create (this_mc:MovieClip, name:String, depth:Number, init_obj:Object):${enclosing_type} { var new_mc:MovieClip = this_mc.createEmptyMovieClip(name, depth); var current_constructor:Function = ${enclosing_type}; new_mc.__proto__ = current_constructor.prototype; var out_mc:${enclosing_type} = ${enclosing_type}(new_mc); for (var i:String in init_obj) { out_mc[i] = init_obj[i]; } current_constructor.call(out_mc); return out_mc; } -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Create movieclip path within a class
Hello Paul, If you already have an instances of Boiler on the stage you can use boiler's self-registering in your game class. For example you have in library: Game_mc, linkage - Game_mc, AS 2 class - Game. Bolier_mc, linkage - Boiler_mc, AS 2 class - Boiler. On the stage you have an instance of Game_mc contained instances of Bolier_mc inside in example you needn't to know instance name of your boilers example of self-registration: == import Game; class Boiler extends MovieClip { private var game_mc : Game; private function Boiler() { this.game_mc = Game(this._parent); this.game_mc.registerBoiler(this); } } class Game extends MovieClip { private var boilers : Array; private function Game() { } /**registerBoiler (Game.registerBoiler method) * public registerBoiler (boiler_mc:Boiler) : Void; * pre * * /pre * @param boiler_mc:Boiler ≈ * @return Void ≈ * pre * * /pre * BExample:/B * pre * import Game; * * /pre **/ public function registerBoiler (boiler_mc:Boiler):Void { this.boilers.push(boiler_mc); // other actions } } = PS I do not want to create the boiler movie clips as these are already on the PS stage. PS Basically I want to be able to control a nested movie clip within each PS boiler, that is called needle_mc PS And I want the boiler object to store unique properties for each of the PS boilers. PS Your code looks very complex for my requirements - can I not simply PS dynamically create the boiler movie clip path reference and pass it to the PS boiler instance similar to how I passed the path to the Game class? PS Thanks PS Paul PS -Original Message- PS From: [EMAIL PROTECTED] PS [mailto:[EMAIL PROTECTED] On Behalf Of Iv PS Sent: 03 December 2006 14:30 PS To: Flashcoders mailing list PS Subject: Re: [Flashcoders] Create movieclip path within a class PS Hello Paul, PS var vBoiler_Obj:Boiler = new Boiler(vBoilerRef); PS - this line incorrect. PS use create method PS public static function create (this_mc:MovieClip, name:String, depth:Number, PS init_obj:Object):Boiler { PS var new_mc:MovieClip = this_mc.createEmptyMovieClip(name, depth); PS var current_constructor:Function = Boiler; PS new_mc.__proto__ = current_constructor.prototype; PS var out_mc:Boiler = Boiler(new_mc); PS for (var i:String in init_obj) { PS out_mc[i] = init_obj[i]; PS } PS current_constructor.call(out_mc); PS return out_mc; PS } PS and call: PS var depth:Number = this.getNextHighestDepth(); PS var vBoiler_Obj:Boiler = Boiler.create(this, vBoilerRef, depth) PS PS: PS Template for FDT: PS public static function create (this_mc:MovieClip, name:String, depth:Number, PS init_obj:Object):${enclosing_type} { PS var new_mc:MovieClip = this_mc.createEmptyMovieClip(name, depth); PS var current_constructor:Function = ${enclosing_type}; PS new_mc.__proto__ = current_constructor.prototype; PS var out_mc:${enclosing_type} = ${enclosing_type}(new_mc); PS for (var i:String in init_obj) { PS out_mc[i] = init_obj[i]; PS } PS current_constructor.call(out_mc); PS return out_mc; PS } -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Create movieclip path within a class
Hello Paul, opps. a little mistake. replace game constructor: private function Game() { this.boilers = []; } -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Create movieclip path within a class
Hello Paul, PS And I want the boiler object to store unique properties for each of the PS boilers. - every boiler must create his own object for store his properties. for example: class BoilerStore { public var _rotation:Number; public var _x:Number; public var _y:Number; // etc } and add to boiler class this methods: import Game; import BoilerStore; class Boiler extends MovieClip { private var game_mc : Game; private var store_obj : BoilerStore ; private function Boiler() { this.store_obj = new BoilerStore(); this.game_mc = Game(this._parent); this.game_mc.registerBoiler(this); } /**setRotation (Boiler.setRotation method) * public setRotation (angle:Number) : Number; * pre * * /pre * @param angle:Number ≈ * @return Void ≈ * pre * * /pre * BExample:/B * pre * import Boiler; * * /pre **/ public function setRotation (angle:Number):Void { this._rotation = this.store_obj._rotation = angle; } /**setX (Boiler.setX method) * public setX (x:Number) : Void; * pre * * /pre * @param x:Number ≈ * @return Void ≈ * pre * * /pre * BExample:/B * pre * import Boiler; * * /pre **/ public function setX (x:Number):Void { this._x = this.store_obj._x = x; } // etc } -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[4]: [Flashcoders] Create movieclip path within a class
Hello Paul, PS I am still curious though as to why I cannot dynamically create the boiler PS movie clip reference and pass it to the boiler clip constructor - is this PS not possible? - it's possible. private function Boiler () { ref = this; } :) you can't create movieclips using new keyword. only attachMovie or createEmptyMovieClip -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[6]: [Flashcoders] Create movieclip path within a class
Hello Paul, PS I was trying to create a Boiler object instance, not a movie clip. - ok. now I understand. -- Ivan Dembicki __ [EMAIL PROTECTED] | http://www.artlebedev.ru | http://www.sharedfonts.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Global sound control ...
Hello Stephen, you can use stopAllSounds() function Also sound object in flash always depended from movie clip and for example volume works like _alpha in movie clips: my_mc._alpha = 50; // var my_sound:Sound = new Sound(my_mc); my_sound.setVolume(50); both action will set value for all child objects. it's inherited properties of movieclips If you need control start and stop of sound and haven't fla files of external swf you can try to catch calls of sound object using class like this (AS1 hack): this.setSoundClass = function() { delete this.setSoundClass; var IntrinsicSound = Sound; var Sound = function (target_mc) { trace(new Sound(+arguments+)); this.init(target_mc); }; var tmp = Sound.prototype; tmp.init = function(target_mc) { this.__target_mc = target_mc; this.__in_sound = new IntrinsicSound(target_mc); }; tmp.attachSound = function(id) { trace(attachSound(+arguments+)); this.__in_sound.attachSound(id); }; tmp.start = function(secondOffset, loops) { trace(start(+arguments+)); this.__in_sound.start(secondOffset, loops); }; // ... etc _global.Sound = Sound; ASSetPropFlags(_global, 'Sound', 7, 1); }; this.setSoundClass(); // = var my_sound = new Sound(this); my_sound.attachSound(my_song); my_sound.start(); but you can't catch nothing if sound placed on timiline. and another one way: you can stop sound in movie clip using empty sound object: my_sound = new Sound(any_mc) my_sound.stop() - its works for start and event sync a stream sync sound you can stop by this way: any_mc.stop(); good luck! SF I have an interactive demo that consists of one main SWF file that SF loads in other SWF files depending on what the user clicks on in SF the main SWFs navigation. SF Within this main SWF and within all the seperate SWFs are numerous SF movies each with their own timeline doing it's own thing. SF In numerous place on timelines throughout this set of SWFs, sound SF effects have been hardcoded onto their respective timeline (i.e: SF not loaded dynamically using the sound object). SF So is there any way to turn off sound globally regardless of where SF it's located on whatever timeline within whatever SWF. So I can SF just create an on/off button for the main SWF that will control SF sound globally ??? SF Thanks.___ -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Playing video backwards kills my CPU
Hello Ricardo, RS Thanks, If I do that it works, but weight goes from 560Kbs to 7Mbs!!! I RS can't do that :( - don't change keyframe value to 1 and try next: create bitmaps of every frame of your video attach bitmaps in any sequence you need. for example backward... -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Q: passing flash form data with NO server side scripting
Hello bitstreams, bmc I have an unusual flash form project in that the hosting provider bmc doesn't support ANY server side scripting. - change your provider. bmc My goal is to simply pass name value pairs from a form... - SharedObject possible? -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] LONDON: SENIOR FLASH ROLE
Hello Matt, MM [...] You should have an in-depth knowledge of Flash and MM Actionscript, with strong animation skills in terms of both code MM driven and timeline-based motion animation. - I'm looking for a job in London, and my technical skills are more than efficient to meet all of the requirements. However, I find this sort of advertisements scaring as they imply that one should be skilled at design and hand drawing. Could you please clarify, whether you need a pure programmer or a designer capable of some programming? And if you need a strong programmer, why should he master Illustrator, Photoshop etc? Thank you. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] search and replace keywords in textbox with CSS, asfunction.
Hello Kurt, about 2 years ago I did this: http://www.sharedfonts.com/fla/as_highlight.fla possible it can help you. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] htmlText javascript link being ignored in Safari
Hello Marlon, - use allowDomain=always in html. MH I have a dynamic text field where I create an html link based on a MH couple of pieces of data. MH Here's an example of the code for the link: MH var aTag:String = p class = 'landing'a MH href=\javascript:openVidPlayer('/vidplayer.html?video=+sel.v_id+category=+sel.cat+');\ target = '_parent'+sel.ttl+/a/p; MH My problem is that the popup works fine in Windows IE, Mac/Win Firefox MH just fine. It won't work in Safari. It shows as link, but when you MH click, nothing happens. Can anyone think of a reason why this wouldn't MH work? MH ___ MH Flashcoders@chattyfig.figleaf.com MH To change your subscription options or search the archive: MH http://chattyfig.figleaf.com/mailman/listinfo/flashcoders MH Brought to you by Fig Leaf Software MH Premier Authorized Adobe Consulting and Training MH http://www.figleaf.com MH http://training.figleaf.com -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] help with embedded fonts...
Hello grimmwerks, http://www.sharedfonts.com/eng/faq.html#include -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Shared Fonts puzzle (hell)
Hello Marcelo, http://www.sharedfonts.com/eng/faq.html#include -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Shared Fonts puzzle (hell)
Hello Marcelo, - you need to separate problems. in first step don't use sharing. when your app will work fine you can start sharing your fonts. MdMS In sum, I╢ve been through a hard time trying to get this shared font thing MdMS to work with TextFields. With v2 components I got it to work by setting it╢s MdMS style ( setStyle('fontFamily','fontName'); setStyle('embedFonts',true)) I MdMS assume the v2 framework deals with the TextFormat issue, but with regular MdMS TextFields... it╢s a hell confusing... -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Shared Fonts puzzle (hell)
Hello Marcelo, MdMS The swf I╢m loading is a v7 swf and the host is v8. Could that be causing MdMS some this issue? http://www.sharedfonts.com/eng/faq.html - a bit info about it in the first question. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[6]: [Flashcoders] Shared fonts
Hello Joeri, JvO We use font-family JvO terms like MainFont, or BoldFont, and when letting the FontLoader JvO parse the stylesheet, it replaces them with the actuall font name JvO loaded linked with that identifier... JvO So with just replacing the font libs, the entire site will have new fonts :). - yep. it is in recommendation section on my site. http://www.sharedfonts.com/eng/help.html#practice but not many peoples want read a rules :) -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[6]: [Flashcoders] Shared fonts
Hello Zбrate, Z I just want to understand what Ivan means with: Z use solutions with dubious copyrights - my congratulations. you have good and interesting solution. your OWN solution. Now I has seen it first time. I has experiments with self included libraries too but I used textfields for include fonts. Shared library mc was placed in second frame. In first frame I hase a code for avoid recursive shared libraries loading. In my case it was very difficult for understanding by users and hard for create and debug font libraries. I think you know and understand this problems very good. - In your articles I don't understand text, sorry, but I has found a link to sharedfonts.com and my name. Thank you. I'm glad if I made something for find you your solution. And again: it's your own solution. Thank you. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[8]: [Flashcoders] Shared fonts
Hello Zбrate, Z you cannot blame someone else for using a similar approach to solve Z the same problem. - similar and the same - is different things. Z I cannot blame someone using my one-file-per-font approach as well. - now yes. because you share it. But if you has invest a money to your own unique solution based on your discoveries I think you can expect from community respect for your interests. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Shared fonts
Hello Bernard, - thank you! BV Last weeks/months I see more and more questions about shared fonts. BV I've used the following for about a year now and it works for me. BV The basic is the same as sharedfonts (2 swf's to load the fonts), I'm sorry BV for all the people behind sharedfonts for this. BV Example: http://www.debit.nl/flashcoders/fonts/ BV FontLoader.as : http://www.debit.nl/flashcoders/FontLoader.txt BV Source of the example: http://www.debit.nl/flashcoders/FontLoader.zip BV Good luck with the code. BV Bernard BV ___ BV Flashcoders@chattyfig.figleaf.com BV To change your subscription options or search the archive: BV http://chattyfig.figleaf.com/mailman/listinfo/flashcoders BV Brought to you by Fig Leaf Software BV Premier Authorized Adobe Consulting and Training BV http://www.figleaf.com BV http://training.figleaf.com -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Shared fonts
Hello Bernard, - really it isn't a problem: SFM work principles was published many times but sales not stopped yet. Trere are many companies and peoples which can't allow himself to use solutions with dubious copyrights. Of course many companies and peoples don't think about it. In any case it isn't my clients. Also SFM is free for web site developers and if developer can't add SFM to project budget for client he can receive it free from me. I understand situation: I'm developer too. I hope my english is understandable, good luck! BV I believe we had the discussion about this more than a year ago ;) BV You know the code is different from the sahredfonts code and there is no AS BV involved in the lib's BV I'm sorry.. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[4]: [Flashcoders] Shared fonts
Hello Bernard, BV In my opinion SFM is too old and can't be successfully used in BV an FAME (or other) enviroment. - SFM is AS2 class compatible for the most hard parser settings in FDT. But for licensed users only :) -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[4]: [Flashcoders] Shared fonts
Hello Bernard, - and.. I'm sorry, but your code have imperfections. It's works, but you need support experiance with many languages and different situations for find a problems in your code. It's one more reason for use original solution. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Accessing the Color Picker in an application.
Hello artkast, http://www.dembicki.org/GradientAndSafePalette.as -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Linked font from class
Hello Michael, http://www.sharedfonts.com/eng/faq.html#include -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] _global is _global or what?
Hello Jason, MJ Say clip A is the main _level0 clip where the _global.myVar is defined. MJ Clip B is an external .swf references the _global myVar. - http://www.sharedfonts.com/eng/faq.html a bit about it read the first anhswer. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Problem: Bold, italic, normal text style in a dynamic textfield
Hello Ramon, RMMT I embedded all characters, for testing purposes. - incorrect embedding. read the article: http://www.sharedfonts.com/eng/faq.html#include -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[3]: [Flashcoders] AS2 Vs. AS1
Hello, I try convert this code to AS2 [...] oops. my code is incorrect. but main is not in my code. main in principle: always use path to variables (or var declaration) if you needn't scope missunderstanding. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[5]: [Flashcoders] AS2 Vs. AS1
Hello stone, - yes. a little trick needed: import mx.utils.Delegate; class EmailForm extends MovieClip { private var submit_btn:Button; private var new_lv : LoadVars; private var email : TextField; // private var request_url : String = emailSubmit.php; private var request_url : String = emailSubmit.txt; private function EmailForm () { this.submit_btn.onRelease = Delegate.create(this, this.onReleaseHandler); } private function onReleaseHandler() : Void { this.sendEmail(); } private function sendEmail() : Void { trace(sendEmail+this); var lv:LoadVars = new LoadVars(); this.new_lv = new LoadVars(); lv[email] = this.email.text; this.new_lv.onData = Delegate.create(this, this.getResponse); lv.sendAndLoad(this.request_url, this.new_lv); // , POST } private function getResponse (loaded_data:String):Void { if (loaded_data == null) { trace(Error); return; } trace(EmailForm.getResponse(+[arguments]+)); // trick var lv:LoadVars = new LoadVars(); lv.onData(loaded_data); for (var i : String in lv) { trace(i+=+lv[i]); } } } -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[7]: [Flashcoders] AS2 Vs. AS1
Hello stone, sl I'm etting an error on the class says it needs to be sl external? - wow! of course. sl Is there a reason this works in AS1 and not AS2? - possible I understand you incorrect... -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Help with shared library fonts
Hello Hypno, HJ Is there a way to keep fonts in an external movie and load them HJ dynamically into a movie when needed? - yep. www.sharedfonts.com -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Can't reference a library font from inside a static class (?)
Hello Jason, http://www.sharedfonts.com/eng/faq.html#include -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] Can't reference a library font from inside a staticclass (?)
Hello Jason, From reading that article, what is SFM? - Shared Fonts Manager www.sharedfonts.com about it. MJ Also, this is recommending using text fields placed off-stage which show MJ all the characters? I wanted to just do this from a class and have MJ minimal interaction with the .fla - the article also seems written for MJ an older version of Flash. Is this really the only way to reference a MJ font in the library from a static class? In AS2 you can use special class for access to formats instead _level0.fmt_container object for example: class FontsLibrary { private static var container:Object; public static function registerFormat (from_text_field:TextField):Void { container = container || {}; if (!from_text_field.embedFonts) { return; } var t_fmt = from_text_field.getNewTextFormat(); var name:String = t_fmt.font; if (t_fmt.bold) { name += _bold; } if (t_fmt.italic) { name += _italic; } container[name] = t_fmt; } public static function isRegistered (font:String, bold:Boolean, italic:Boolean):TextFormat { var name:String = t_fmt.font; if (t_fmt.bold) { name += _bold; } if (t_fmt.italic) { name += _italic; } if (container[name]) { return true; } return false; } } your class: class com.icfconsulting.objects.SimpleTextField{ public static function create(target_mc:MovieClip):TextField{ //(Note:I just want a simple text field, so values are hard coded for now) var my_fmt:TextFormat = new TextFormat(); my_fmt.font = Swis; my_fmt.color = 0x00; my_fmt.size = 16; target_mc.createTextField(tf_txt,0,20,20,200,20); target_mc.tf_txt.embedFonts = FontsLibrary.isRegistered(Swis, false, false); .. and in the FLA you need register formats, possible using class: import FontsLibrary; class TextFormatsHolder extends MovieClip { function TextFormatsHolder () { for (var i:String in this) { var text_field:TextField = TextField(this[i]) FontsLibrary.registerFormat(text_field); } this.swapDepths(this._parent.getNextHighestDepth()); this.removeMovieClip(); } } add to library in FLA TextFormatsHolder class movieclip and add textfields with embeded fonts. don't set export in first frame and add this movieclip to timeline after preloader. it's just a principle of solution. script not checked. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[4]: [Flashcoders] Can't reference a library font from inside astaticclass (?)
Hello Jason, http://www.sharedfonts.com/fonts.zip -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] What's your job title?
Hello Kirk, KR Here's a non-technical question: what is your job title? - Flasher hehe -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[6]: [Flashcoders] Can't reference a library font from insideastaticclass (?)
Hello Jason, http://www.sharedfonts.com/fonts.zip MJ I tried that and couldn't get it to work. Thanks though. - It's works. Tested. Possible you haven't fonts used in example. Just set your fonts in textfields and set embeded character set. Look at registered array and trace your fonts names. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] RE: getDepth: highest depth, middle depth, lowest depth
Hello Flash, FM I am not allowed to use Flash 8 for this project. FM They want it published in Flash 6. From what I was reading the new FM DepthManager class only works with Flash 8. http://proto.layer51.com/d.aspx?f=834 use property below main code. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re[2]: [Flashcoders] RE: getDepth: highest depth, middle depth, lowest depth
Hello, example of pyramidal depth management: MovieClip.prototype.addProperty(topDepth, function () { var mc, mcd, d; for (mcd in this) { if ((mc=this[mcd])._name == mcd mc instanceof MovieClip mc._parent == this) { return (d=this[mcd].getDepth()+1)1 ? 1 : d; } } return 1; }, null); // --- this.onReleaseHandler = function() { this.pyramiDepth(false); }; this.pyramiDepth = function(depth, direction) { if (depth === false) { depth = this._parent.topDepth-1; this.swapDepths(depth); this.next_mc.pyramiDepth(depth-2, 1); this.prev_mc.pyramiDepth(depth-3, -1); } else { this.swapDepths(depth); if (direction == 1) { this.next_mc.pyramiDepth(depth-2, 1); } else if (direction == -1) { this.prev_mc.pyramiDepth(depth-2, -1); } } }; this.createAnyMc = function(this_obj, name, depth, prev_mc) { var mc = this_obj.createEmptyMovieClip(name, depth); mc.prev_mc = prev_mc; prev_mc.next_mc = mc; mc._x = (prev_mc._x+30) || 20; mc.lineStyle(0, 0xFF, 100); mc.beginFill(0xCC, 100); mc.lineTo(40, 0); mc.lineTo(45, 20); mc.lineTo(40, 40); mc.lineTo(0, 40); mc.lineTo(-5, 20); mc.lineTo(0, 0); mc.endFill(); mc.onRelease = this.onReleaseHandler; mc.pyramiDepth = this.pyramiDepth; trace(mc.prev_mc); return mc; }; // var prev_mc = undefined; for (var i = 0; i6; i++) { prev_mc = this.createAnyMc(this, mc+i, i, prev_mc); } -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] FP8 AS2 color picker and comboBox
Hello Martin, MW i seek for color picker component (tried many, Illogiz, not MW working in as2), please doeas anyone have some really good? - try this: http://www.dembicki.org/GradientAndSafePalette.as -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] loading swf with embedded fonts.
Hello Magnus, MA been searching (both in this list and on google) for a way to load an MA swf at runtime (with embedded fonts) and access them font within the MA mother clip. MA Anyone knows if this is possible, and if so point me in the right direction? http://www.sharedfonts.com -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Exporting embeded fonts on frame other than 1
Hello Lee, http://www.sharedfonts.com/eng/faq.html#include -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Simulating a rope
Hello Luca, LC Hi to all, how do I simulate a rope in ActionScript? - try this: /** * author Ivan Dembicki,BR/ * version 1.0BR/ * Availability: ActionScript 1.0; Flash Player 6BR/ * usage example below the code */ class org.dembicki.ElasticCord { // public variables /** * gravity value */ public var gravity:Number = 10; /** * elasticity value */ public var elasticity:Number = .2; /** * friction value */ public var friction:Number = .2; // private variables private var __start_point:Object; private var __end_point:Object; private var __segments:Number = 0; // CONSTRUCTOR /** * ElasticCord class constructor * * @param segments Number. Number of segments * @param start_x x position of cord beginning * @param start_y y position of cord beginning * @param end_x x position of cord end * @param end_y y position of cord end */ function ElasticCord(segments:Number, start_x:Number, start_y:Number, end_x:Number, end_y:Number) { this.initCord(segments, start_x, start_y, end_x, end_y); } // PROPERTIES // _segments public function get _segments():Number { return this.__segments; } // PUBLIC // setStartPoint public function setStartPoint(x:Number, y:Number):Void { this.__start_point.x = x || 0; this.__start_point.y = y || 0; } // setEndPoint public function setEndPoint(x:Number, y:Number):Void { this.__end_point.x = x || 0; this.__end_point.y = y || 0; } // reDraw public function reDraw(mc:MovieClip):Void { // -- recalc -- var segments:Number = (this.__segments*2+1); var elasticity:Number = this.elasticity; var friction:Number = 1-this.friction; var gravity:Number = this.gravity/segments; // mc.moveTo(this.__start_point.x, this.__start_point.y); var current_point:Object = this.__start_point.next_point; while (current_point.next_point) { // target is middlepoint between previous and next points var target_x:Number = (current_point.prev_point.x+current_point.next_point.x)/2; var target_y:Number = (current_point.prev_point.y+current_point.next_point.y)/2; // step current_point.x_step += (target_x-current_point.x)*elasticity; current_point.y_step += (target_y-current_point.y)*elasticity+gravity; current_point.x_step *= friction; current_point.y_step *= friction; // move point current_point.x += current_point.x_step; current_point.y += current_point.y_step; // calc next point current_point = current_point.next_point; } // -- redraw -- if (mc) { var control_point:Object = this.__start_point.next_point; while (control_point.next_point) { mc.curveTo(control_point.x, control_point.y, (control_point.next_point.x+control_point.x)/2, (control_point.next_point.y+control_point.y)/2); control_point = control_point.next_point; } mc.lineTo(control_point.x, control_point.y); } } // PRIVATE private function initCord(segments:Number, start_x:Number, start_y:Number, end_x:Number, end_y:Number):Void { if (!segments || segments1) { segments = 1; } this.__segments = segments; this.__start_point = {x:start_x || 0, y:start_y || 0}; // var x_step:Number = (end_x-start_x)/segments || 0; var y_step:Number = (end_y-start_y)/segments || 0; var current_point:Object = this.__start_point; while ((--segments)0) { current_point = this.addPoint(current_point, x_step, y_step); } current_point = this.addPoint(current_point, x_step, y_step); this.__end_point = {x:end_x || 0, y:end_y || 0, prev_point:current_point}; current_point.next_point = this.__end_point; _global.ASSetPropFlags(this.__start_point, next_point, 7); _global.ASSetPropFlags(this.__end_point, prev_point, 7); } private function addPoint(prev_point:Object,
Re[2]: [Flashcoders] Detecting the dominating colour in a rectangle of a bitmap
Hello elibol, Perhaps, you could use scaling BitmapData instance to the size of 1 pixel. The color of that pixel should be the mean color value of all pixels in scaled BitmapData instance. I would like to ask if anyone already have some sort method that calculates which colour in a rectangle is the dominating colou in a BitmapData instance. -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Re: [Flashcoders] lightweight flash7 color picker?
Hello Rajat, http://www.dembicki.org/GradientAndSafePalette.as -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Re: [Flashcoders] Drawing dotted lines
Hello Йric, http://www.dembicki.org/index-eng.html try this: http://www.dembicki.org/FreeSelector.as http://www.dembicki.org/RectangularSelector.as -- Ivan Dembicki [EMAIL PROTECTED] || http://www.design.ru ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders