[Flashcoders] Dynamically setting color and adding a glow [Flash 8 AS2]

2009-05-20 Thread Paul Steven
I am trying to dynamically set the color and apply a glow to a movie clip as follows however one seems to overwrite the other. Anyone know why this is not working and how to fix it? My code is as follows: function setGameBackgroundColourAndGlow(passedHexColour:Number):Void {

[Flashcoders] Implicit coercion error with inheritance

2009-05-20 Thread Mendelsohn, Michael
Hi list... Seemingly simple, but why do I get an Implicit coercion error 1067 when instancing this: var ceilingApparatus:EachItem= new FloorItem(); and, this error too: var ceilingApparatus:FloorItem = new FloorItem(); // undefined trace(ceilingApparatus[init]); package NewBuildingDirectory{

[Flashcoders] RE: Implicit coercion error with inheritance

2009-05-20 Thread Mendelsohn, Michael
Sorry list. Problem solved, it was a linkage setting. :-( ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

RE: [Flashcoders] Implicit coercion error with inheritance

2009-05-20 Thread Merrill, Jason
but why do I get an Implicit coercion error 1067 when instancing this: var ceilingApparatus:EachItem= new FloorItem(); Because you're mis-casting FloorItem as an EachItem. Where is EachItem defined? I only see EachFloor in your code. You could try: var ceilingApparatus:EachItem= new

RE: [Flashcoders] Implicit coercion error with inheritance

2009-05-20 Thread Mendelsohn, Michael
Yeah, I really struck out on this one! There's only two classes EachFloor and FloorItem. So EachItem was a typo, and I had the base class as for FloorItem as flash.display.MovieClip instead of NewBuildingDirectory.EachFloor. Ugh. tail between legs - MM EachFloor vs. EachItem? Because

[Flashcoders] Parsing HTML tags within flash from an XHTML file?

2009-05-20 Thread Jonathan Wing
Hi, I'm new to this group, so forgive me if I'm going about asking this the wrong way. Is there a practical way to search old questions? Anyway, I'm using the Gaia Framework and I'm trying to parse basic tags such as h1 and a in flash via an XHTML file. Steven over at the Gaia forum suggests

[Flashcoders] JSON Experiences

2009-05-20 Thread Gregory Boland
Dear list, I am looking into using JSON to bring data into Flash as opposed to XML and I wondering what other people's experiences have been with it. People tell me that its much easier to use than xml and easier to implement. Does anyone know of a good place to see some AS3 code that uses JSON

[Flashcoders] Advice on creating dynamic crossword cluesth resize function

2009-05-20 Thread Paul Steven
I am creating a crossword where the words and clues are read in from an xml file. I need to be able to display the clues in a small area hence these will need to scroll. I also need to highlight a particular clue if the word on the crossword is clicked. Problem is that some clues will be on more

Re: [Flashcoders] JSON Experiences

2009-05-20 Thread Steven Sacks
If your XML has namespaces (like YouTube's xml feeds), then, yes, JSON is easier to implement. Namespace support in E4X is the very definition of Royal Pain In The Arse. It's why the AS3 code lib for YouTube uses their JSON feed instead. It's just too ridiculous to deal with all those

RE: [Flashcoders] Advice on creating dynamic crossword cluesth resize function

2009-05-20 Thread Kerry Thompson
Paul Steven wrote: I am creating a crossword where the words and clues are read in from an xml file. I need to be able to display the clues in a small area hence these will need to scroll. I also need to highlight a particular clue if the word on the crossword is clicked. Problem is that some

RE: [Flashcoders] Dynamically setting color and adding a glow [Flash 8 AS2]

2009-05-20 Thread Jack Doyle
The color transform (setRGB()) affects the entire MovieClip including all filters. There are two options that come to mind that would accomplish what you're after: 1) Wrap your objTileColor MovieClip in another MovieClip. Then you can tint/color the inner clip and apply the glow to the

Re: [Flashcoders] Implicit coercion error with inheritance

2009-05-20 Thread Matt Gitchell
EachFloor vs. EachItem? On Wed, May 20, 2009 at 7:56 AM, Mendelsohn, Michael michael.mendels...@fmglobal.com wrote: Hi list... Seemingly simple, but why do I get an Implicit coercion error 1067 when instancing this: var ceilingApparatus:EachItem= new FloorItem(); and, this error too:

RE: [Flashcoders] Advice on creating dynamic crossword cluesth resize function

2009-05-20 Thread Kevin Bath
Paul - why don't you use a scrollpane, add all the clues as separate mc's into this component. That way you can target them separately to change the text colour if you click on a square. You could space the clue mc's by using the textheight property of the textfield within the clue mc. If you

Re: [Flashcoders] JSON Experiences

2009-05-20 Thread Manish Jethani
On Thu, May 21, 2009 at 12:12 AM, Gregory Boland breakfastcof...@gmail.com wrote: Does anyone know of a good place to see some AS3 code that uses JSON so i can see how it works? Using JSON is fairly simple using the corelib library: http://code.google.com/p/as3corelib/ You have to use the

Re: [Flashcoders] How to embed assets in pure as3?

2009-05-20 Thread Manish Jethani
On Wed, May 13, 2009 at 8:34 PM, ACE Flash acefl...@gmail.com wrote: hi there, I'd like to use pure  actionscript 3 to embed my assets in flash. and use addChild() to add them on the stage.        [Embed(source=/assets/img1.gif , mimeType=image/gif)]        public var newImage:Class; [...]

Re: [Flashcoders] JSON Experiences

2009-05-20 Thread Taka Kojima
IMO, there are times to use JSON and times to use XML. JSON is very easy to implement and not very hard to grasp... all you're basically doing is running an encode when you send data out and a decode when you bring data in. So you only need two functions. E4X is definitely powerful, however if

Re: [Flashcoders] JSON Experiences

2009-05-20 Thread Steven Sacks
Agreed! On May 20, 2009, at 3:45 PM, Taka Kojima wrote: IMO, there are times to use JSON and times to use XML. JSON is very easy to implement and not very hard to grasp... all you're basically doing is running an encode when you send data out and a decode when you bring data in. So you

Re: [Flashcoders] JSON Experiences

2009-05-20 Thread Karl DeSaulniers
Sorry to be so dinosaur, but is there something like this for AS2? Encoding and decoding sent data for and AS2 project? Karl DeSaulniers Design Drumm http://designdrumm.com On May 20, 2009, at 6:17 PM, Steven Sacks wrote: Agreed! On May 20, 2009, at 3:45 PM, Taka Kojima wrote: IMO, there

Re: [Flashcoders] JSON Experiences

2009-05-20 Thread Taka Kojima
http://www.json.org/json.as On Wed, May 20, 2009 at 5:18 PM, Karl DeSaulniers k...@designdrumm.comwrote: Sorry to be so dinosaur, but is there something like this for AS2? Encoding and decoding sent data for and AS2 project? Karl DeSaulniers Design Drumm http://designdrumm.com On May

Re: [Flashcoders] JSON Experiences

2009-05-20 Thread Karl DeSaulniers
Thank you Taka. Much obliged... Karl On May 20, 2009, at 7:45 PM, Taka Kojima wrote: http://www.json.org/json.as On Wed, May 20, 2009 at 5:18 PM, Karl DeSaulniers k...@designdrumm.comwrote: Sorry to be so dinosaur, but is there something like this for AS2? Encoding and decoding sent

[Flashcoders] Operator Help!!

2009-05-20 Thread Karl DeSaulniers
EEEk.. anyone!!! What am I doing wrong?? This is AS2. var sunrise:Array = new Array(6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17); var sunset:Array = new Array(18, 19, 20, 21, 22, 23, 0, 1, 2, 3, 4, 5); var time:Date = new Date(); var hour:Number = time.getHours(); var hours:String =