<?xml version="1.0" encoding="ISO-8859-1"?>

<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
	<channel>
		<title>Flash Kit Community Forums - Actionscript 3.0 (incl. Flex/AIR)</title>
		<link>http://board.flashkit.com/board/</link>
		<description>A forum dedicated to Adobe Creative Suite tools, ActionScript 3.0, Flash CS3/CS4, Flash Player related questions as well as Flex and Air, answers, tips and tricks</description>
		<language>en</language>
		<lastBuildDate>Mon, 20 May 2013 03:34:10 GMT</lastBuildDate>
		<generator>vBulletin</generator>
		<ttl>60</ttl>
		<image>
			<url>http://board.flashkit.com/board/images/misc/rss.png</url>
			<title>Flash Kit Community Forums - Actionscript 3.0 (incl. Flex/AIR)</title>
			<link>http://board.flashkit.com/board/</link>
		</image>
		<item>
			<title>Flex and AS3 Z-Index</title>
			<link>http://board.flashkit.com/board/showthread.php?830531-Flex-and-AS3-Z-Index&amp;goto=newpost</link>
			<pubDate>Mon, 20 May 2013 03:29:32 GMT</pubDate>
			<description><![CDATA[Hi, I have a script that calls an as class that adds a child. and a spark datagrid embedded.


---Quote---
<s: DataGrid>..........</s: DataGrid>
<fx:Script>...[as.file]...</fx:Script>
---End Quote---
The problem is I want the DataGrid to be added after the added child so I want it on top.]]></description>
			<content:encoded><![CDATA[<div>Hi, I have a script that calls an as class that adds a child. and a spark datagrid embedded.<br />
<br />
<div class="bbcode_container">
	<div class="bbcode_description">Quote:</div>
	<div class="bbcode_quote printable">
		<hr />
		
			&lt;s: DataGrid&gt;..........&lt;/s: DataGrid&gt;<br />
&lt;fx:Script&gt;...[as.file]...&lt;/fx:Script&gt;
			
		<hr />
	</div>
</div> The problem is I want the DataGrid to be added after the added child so I want it on top.</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>cjm</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830531-Flex-and-AS3-Z-Index</guid>
		</item>
		<item>
			<title>FlashDevelop + Flash Pro mx error</title>
			<link>http://board.flashkit.com/board/showthread.php?830519-FlashDevelop-Flash-Pro-mx-error&amp;goto=newpost</link>
			<pubDate>Fri, 17 May 2013 17:58:05 GMT</pubDate>
			<description><![CDATA[Hi I am trying to use FlashDevelop as the code editor and mainly using Flash Pro. I have already added the path for flex in Flash Pro. I am getting this error: 

"Error: No class registered for interface 'mx.styles::IStyleManager2"

I have searched and found that <mx:Application> has to be added, but I can't figure out how with Flash Pro.
Help would be greatly appreciated. Thanks.]]></description>
			<content:encoded><![CDATA[<div>Hi I am trying to use FlashDevelop as the code editor and mainly using Flash Pro. I have already added the path for flex in Flash Pro. I am getting this error: <br />
<br />
&quot;Error: No class registered for interface 'mx.styles::IStyleManager2&quot;<br />
<br />
I have searched and found that &lt;mx:Application&gt; has to be added, but I can't figure out how with Flash Pro.<br />
Help would be greatly appreciated. Thanks.</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>cjm</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830519-FlashDevelop-Flash-Pro-mx-error</guid>
		</item>
		<item>
			<title>video tearing in air 2.6</title>
			<link>http://board.flashkit.com/board/showthread.php?830517-video-tearing-in-air-2.6&amp;goto=newpost</link>
			<pubDate>Fri, 17 May 2013 15:42:47 GMT</pubDate>
			<description>Hi,
Im running video at 1024x768 in a desktop application.
Its suffering with tearing.
 
I think in air 3.0 and over you can set the render type to gpu and this fixes the issue.
 
But the machine Im running it on does not have gpu or at least an external one.
 
Has anyone any ideas how I can reduce tearing?
 
Thanks
Aidan</description>
			<content:encoded><![CDATA[<div>Hi,<br />
Im running video at 1024x768 in a desktop application.<br />
Its suffering with tearing.<br />
 <br />
I think in air 3.0 and over you can set the render type to gpu and this fixes the issue.<br />
 <br />
But the machine Im running it on does not have gpu or at least an external one.<br />
 <br />
Has anyone any ideas how I can reduce tearing?<br />
 <br />
Thanks<br />
Aidan</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>aidanmack</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830517-video-tearing-in-air-2.6</guid>
		</item>
		<item>
			<title>target objects created dynamically in library items</title>
			<link>http://board.flashkit.com/board/showthread.php?830511-target-objects-created-dynamically-in-library-items&amp;goto=newpost</link>
			<pubDate>Fri, 17 May 2013 09:01:57 GMT</pubDate>
			<description><![CDATA[In my library I've got a movie clip. Completely empty, just containing this code:


Code:
---------
var myText:TextField = new TextField;
addChild(myText);
myText.text="old text"
---------
Then from the main timeline I add this library movie clip which places it on the main stage and the text appears


Code:
---------
var Clippy:textfieldpadding = new textfieldpadding();
addChild(Clippy);
---------
But now I want to change the text of that textfield. Which is inside the just placed library movie clip. But this gives an error:


Code:
---------
var Clippy:textfieldpadding = new textfieldpadding();
addChild(Clippy);
Clippy.myText.text="new text"
---------
Cause it has no clue what 'myText' is from the main timeline.

How can I target a textfield, or any other object when it is all dynamically generated and as a movieclip inside the library?]]></description>
			<content:encoded><![CDATA[<div>In my library I've got a movie clip. Completely empty, just containing this code:<br />
<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">var myText:TextField = new TextField;<br />
addChild(myText);<br />
myText.text=&quot;old text&quot;</code><hr />
</div> Then from the main timeline I add this library movie clip which places it on the main stage and the text appears<br />
<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">var Clippy:textfieldpadding = new textfieldpadding();<br />
addChild(Clippy);</code><hr />
</div> But now I want to change the text of that textfield. Which is inside the just placed library movie clip. But this gives an error:<br />
<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">var Clippy:textfieldpadding = new textfieldpadding();<br />
addChild(Clippy);<br />
Clippy.myText.text=&quot;new text&quot;</code><hr />
</div> Cause it has no clue what 'myText' is from the main timeline.<br />
<br />
How can I target a textfield, or any other object when it is all dynamically generated and as a movieclip inside the library?</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>digitalecartoon</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830511-target-objects-created-dynamically-in-library-items</guid>
		</item>
		<item>
			<title>Evaluating a string value into a variable name</title>
			<link>http://board.flashkit.com/board/showthread.php?830501-Evaluating-a-string-value-into-a-variable-name&amp;goto=newpost</link>
			<pubDate>Thu, 16 May 2013 18:26:14 GMT</pubDate>
			<description><![CDATA[I am new to AS 3.0, but have programmed extensively in AS 2.0.  I have 3 checkboxes on my stage, each of which correspond to a specific boolean variable.  I am trying to create a single eventListener function to handle them.  In AS 2, I was able to take the name of the checkbox that was clicked and use eval to allow me set the appropriate boolean value.  However, when I try to do this in AS 3, it tells me that eval is an undefined method.  Is there a simple way to take the name of an object on the stage and get it's appropriate variable?

Here's what I'm talking about_:

I have 3 checkboxes named count_mc, placement_mc, and spray_mc and 3 boolean variables called count, placement and spray.  In the past, I could get the name of the movieclip that was clicked, strip off the _mc and place that string in an eval statement as follows:

var btnClicked = event.target.name.substring(0, event.target.name.indexOf("_mc"));
btnVar = eval(btnClicked);
btnVar = !btnVar;

I appreciate any help anyone can give me.


Chris]]></description>
			<content:encoded><![CDATA[<div>I am new to AS 3.0, but have programmed extensively in AS 2.0.  I have 3 checkboxes on my stage, each of which correspond to a specific boolean variable.  I am trying to create a single eventListener function to handle them.  In AS 2, I was able to take the name of the checkbox that was clicked and use eval to allow me set the appropriate boolean value.  However, when I try to do this in AS 3, it tells me that eval is an undefined method.  Is there a simple way to take the name of an object on the stage and get it's appropriate variable?<br />
<br />
Here's what I'm talking about<b></b>:<br />
<br />
I have 3 checkboxes named count_mc, placement_mc, and spray_mc and 3 boolean variables called count, placement and spray.  In the past, I could get the name of the movieclip that was clicked, strip off the _mc and place that string in an eval statement as follows:<br />
<br />
var btnClicked = event.target.name.substring(0, event.target.name.indexOf(&quot;_mc&quot;));<br />
btnVar = eval(btnClicked);<br />
btnVar = !btnVar;<br />
<br />
I appreciate any help anyone can give me.<br />
<br />
<br />
Chris</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>chrscote</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830501-Evaluating-a-string-value-into-a-variable-name</guid>
		</item>
		<item>
			<title><![CDATA[[RESOLVED] moving from as2 to as3 need some help]]></title>
			<link>http://board.flashkit.com/board/showthread.php?830499-RESOLVED-moving-from-as2-to-as3-need-some-help&amp;goto=newpost</link>
			<pubDate>Thu, 16 May 2013 00:28:44 GMT</pubDate>
			<description>I have been using as2 for a few years now but want to learn as3. I always learn better by example so I have uploaded a simple AS2 file in CS4 and was hoping someone could convert to as3 so I could dissect and learn. I know it involves a string class and am have difficulty wrapping my head around the whole class issue.</description>
			<content:encoded><![CDATA[<div>I have been using as2 for a few years now but want to learn as3. I always learn better by example so I have uploaded a simple AS2 file in CS4 and was hoping someone could convert to as3 so I could dissect and learn. I know it involves a string class and am have difficulty wrapping my head around the whole class issue.</div>


	<div style="padding:10px">

	

	

	

	
		<fieldset class="fieldset">
			<legend>Attached Files</legend>
			<ul>
			<li>
	<img class="inlineimg" src="/fla.gif" alt="File Type: fla" />
	<a href="http://board.flashkit.com/board/attachment.php?attachmentid=74263&amp;d=1368663898">sample.fla&lrm;</a> 
(64.0 KB)
</li> 
			</ul>
		</fieldset>
	

	</div>
 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>ADVaughn</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830499-RESOLVED-moving-from-as2-to-as3-need-some-help</guid>
		</item>
		<item>
			<title>Custom Class with access to stage or Event Listeners</title>
			<link>http://board.flashkit.com/board/showthread.php?830493-Custom-Class-with-access-to-stage-or-Event-Listeners&amp;goto=newpost</link>
			<pubDate>Wed, 15 May 2013 20:17:45 GMT</pubDate>
			<description><![CDATA[Hello everyone :)

I have a question for you all today, a question off which the answer will probably slap me in the face. Nonetheless, here it is:

I am making (more like attempting) to create Horizontal Arcade like shooter. The project is going good so far:
I have an enemy, who shoots at me. My own ship, who shoots back at him. I'm able to spawn those enemies in waves, etc..

The problem is though that I've have written a whole bunch of code for just one enemy, a whole bunch of code I'm going to use to spawn a bunch of more different types of enemies (faster/slower shooting, faster/slower movement, etc..) and I'm not that keen on having a hundred different .as files for each type of enemy AND each type of weapon.

A small example of my .as file that extends my movieclip in my main .fla file's library:

Code:
---------
public function ballEnemy(tempX:int ,tempY:int ,scoreTemp:int)
---------
What I want to do is make it something like this:

Code:
---------
public function basicEnemy(enemyTemp:MovieClip, tempX:int ,tempY:int ,scoreTemp:int)
---------
Not actually extending the movieclip but rather make an enemy class on its own!
This way I can add more parameters (enemy speed, bullet speed, etc...) without having to write a whole bunch of code.

The main problem is that I use an Event Listener to check if the movieclip entered the frame to start a loop (in which the movieclips moves at a certain speed and destroys itself when it reaches a certain Y coordinate).

The question now is: is it possible to make working Event Listeners in a custom class that is NOT an extension of any kind of object? Or am I making a huge workaround for something that could be done a lot simpler?

EG: the full code of the 'ballEnemy' class.


Code:
---------
package 
{

	import flash.display.MovieClip;
	import flash.events.Event;
	import flash.utils.Timer;
	import flash.events.*;


	public class ballEnemy extends MovieClip
	{

		private var speed:Number = 4;
		private var score:int;

		private var fireTimer:Timer;
		private var canFire:Boolean = true

		public function ballEnemy(tempX:int ,tempY:int ,scoreTemp:int)
		{
			this.x = tempX;
			this.y = tempY;

			score = scoreTemp;

			this.height = this.height * 1.5;
			this.width = this.width * 1.5;

			addEventListener(Event.ENTER_FRAME, loop, false, 0, true);

			fireTimer = new Timer(1200,1);
			fireTimer.addEventListener(TimerEvent.TIMER, fireTimerHandler, false, 0, true);
		}

		private function loop(e:Event):void
		{
			this.y +=  speed;
		
			if (this.y > 640)
			{
				this.destroy();
			}

			if (this.x > basicEngine.mainShip.x - 5 && this.x < basicEngine.mainShip.x + 5)
			{
				fireBullet();
			}
		}

		public function fireBullet():void
		{
			if (canFire)
			{
				var bullet:enemyBullet = new enemyBullet(this.x,this.y,10);
				stage.addChildAt(bullet, 0);
				canFire = false;
				fireTimer.start();
			}
		}

		public function destroy():void
		{
			this.removeEventListener(Event.ENTER_FRAME,loop);
			if (stage.contains(this))
			{
				stage.removeChild(this);
			}
		}

		private function fireTimerHandler(e:TimerEvent):void
		{
			canFire = true;
		}

		public function getScore():int
		{
			return score;
		}
	}
}
---------
Thank you for reading and please, if you can, try to provide me with an answer :D]]></description>
			<content:encoded><![CDATA[<div>Hello everyone :)<br />
<br />
I have a question for you all today, a question off which the answer will probably slap me in the face. Nonetheless, here it is:<br />
<br />
I am making (more like attempting) to create Horizontal Arcade like shooter. The project is going good so far:<br />
I have an enemy, who shoots at me. My own ship, who shoots back at him. I'm able to spawn those enemies in waves, etc..<br />
<br />
The problem is though that I've have written a whole bunch of code for just one enemy, a whole bunch of code I'm going to use to spawn a bunch of more different types of enemies (faster/slower shooting, faster/slower movement, etc..) and I'm not that keen on having a hundred different .as files for each type of enemy AND each type of weapon.<br />
<br />
A small example of my .as file that extends my movieclip in my main .fla file's library:<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">public function ballEnemy(tempX:int ,tempY:int ,scoreTemp:int)</code><hr />
</div> What I want to do is make it something like this:<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">public function basicEnemy(enemyTemp:MovieClip, tempX:int ,tempY:int ,scoreTemp:int)</code><hr />
</div> Not actually extending the movieclip but rather make an enemy class on its own!<br />
This way I can add more parameters (enemy speed, bullet speed, etc...) without having to write a whole bunch of code.<br />
<br />
The main problem is that I use an Event Listener to check if the movieclip entered the frame to start a loop (in which the movieclips moves at a certain speed and destroys itself when it reaches a certain Y coordinate).<br />
<br />
The question now is: is it possible to make working Event Listeners in a custom class that is NOT an extension of any kind of object? Or am I making a huge workaround for something that could be done a lot simpler?<br />
<br />
EG: the full code of the 'ballEnemy' class.<br />
<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">package <br />
{<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; import flash.display.MovieClip;<br />
&nbsp; &nbsp; &nbsp; &nbsp; import flash.events.Event;<br />
&nbsp; &nbsp; &nbsp; &nbsp; import flash.utils.Timer;<br />
&nbsp; &nbsp; &nbsp; &nbsp; import flash.events.*;<br />
<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; public class ballEnemy extends MovieClip<br />
&nbsp; &nbsp; &nbsp; &nbsp; {<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; private var speed:Number = 4;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; private var score:int;<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; private var fireTimer:Timer;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; private var canFire:Boolean = true<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; public function ballEnemy(tempX:int ,tempY:int ,scoreTemp:int)<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.x = tempX;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.y = tempY;<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; score = scoreTemp;<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.height = this.height * 1.5;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.width = this.width * 1.5;<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; addEventListener(Event.ENTER_FRAME, loop, false, 0, true);<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; fireTimer = new Timer(1200,1);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; fireTimer.addEventListener(TimerEvent.TIMER, fireTimerHandler, false, 0, true);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; private function loop(e:Event):void<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.y +=&nbsp; speed;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (this.y &gt; 640)<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.destroy();<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (this.x &gt; basicEngine.mainShip.x - 5 &amp;&amp; this.x &lt; basicEngine.mainShip.x + 5)<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; fireBullet();<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; public function fireBullet():void<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (canFire)<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; var bullet:enemyBullet = new enemyBullet(this.x,this.y,10);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; stage.addChildAt(bullet, 0);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; canFire = false;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; fireTimer.start();<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; public function destroy():void<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.removeEventListener(Event.ENTER_FRAME,loop);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (stage.contains(this))<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; stage.removeChild(this);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; private function fireTimerHandler(e:TimerEvent):void<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; canFire = true;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; public function getScore():int<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return score;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; }<br />
}</code><hr />
</div> Thank you for reading and please, if you can, try to provide me with an answer :D</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>gammagamer</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830493-Custom-Class-with-access-to-stage-or-Event-Listeners</guid>
		</item>
		<item>
			<title>getting multiple buttons to play the same animation.</title>
			<link>http://board.flashkit.com/board/showthread.php?830489-getting-multiple-buttons-to-play-the-same-animation.&amp;goto=newpost</link>
			<pubDate>Wed, 15 May 2013 17:12:45 GMT</pubDate>
			<description><![CDATA[I have a popup text box that I have run it's animation every time a certain button is clicked....and that works. However, when a different button is clicked, that has the same function on it, it won't animate.....and the first button will no longer run it either. I have a trace on the function that shows it is still working, but the animation itself no longer plays. 

this part works, but only until a different button is pressed, then it no longer does.

Code:
---------
this.popUpAnim_mc.gotoAndPlay("anim");

this.hot_btn.addEventListener(MouseEvent.CLICK, popAnim);

function popAnim(myevent:MouseEvent):void{
	this.popUpAnim_mc.gotoAndPlay("anim");
trace("popUp animated slide");
}
---------
Here is one of the other buttons I want to also run the animation. It has another function as well, and I will include all of it's code, in case I'm overlooking something that's causing it to break.

Code:
---------
Object(this).popUpAnim_mc.PopUp_mc.back_btn.addEventListener (MouseEvent.CLICK, backClick);
function backClick (myevent:MouseEvent):void {
	this.gotoAndStop(currentFrame-1);
}
//Hide Button on Frame 1
Object(this).popUpAnim_mc.PopUp_mc.back_btn.visible=false;
//constantly check current frame to determine if it should be hidden
this.addEventListener (Event.ENTER_FRAME, BackButtonVis);
function BackButtonVis (event:Event):void{
if(this.currentFrame==1||(currentFrame==totalFrames)){
	Object(this).popUpAnim_mc.PopUp_mc.back_btn.visible=false;
}else{
	Object(this).popUpAnim_mc.PopUp_mc.back_btn.visible=true;
}
}
this.popUpAnim_mc.PopUp_mc.back_btn.addEventListener(MouseEvent.CLICK, popAnim);
---------
there are two other buttons that have different functions that I want to also run the animation...but if I can just get one to work, I'm hoping the other two will be easy.

Thanks in advance!]]></description>
			<content:encoded><![CDATA[<div>I have a popup text box that I have run it's animation every time a certain button is clicked....and that works. However, when a different button is clicked, that has the same function on it, it won't animate.....and the first button will no longer run it either. I have a trace on the function that shows it is still working, but the animation itself no longer plays. <br />
<br />
this part works, but only until a different button is pressed, then it no longer does.<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">this.popUpAnim_mc.gotoAndPlay(&quot;anim&quot;);<br />
<br />
this.hot_btn.addEventListener(MouseEvent.CLICK, popAnim);<br />
<br />
function popAnim(myevent:MouseEvent):void{<br />
&nbsp; &nbsp; &nbsp; &nbsp; this.popUpAnim_mc.gotoAndPlay(&quot;anim&quot;);<br />
trace(&quot;popUp animated slide&quot;);<br />
}</code><hr />
</div> Here is one of the other buttons I want to also run the animation. It has another function as well, and I will include all of it's code, in case I'm overlooking something that's causing it to break.<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">Object(this).popUpAnim_mc.PopUp_mc.back_btn.addEventListener (MouseEvent.CLICK, backClick);<br />
function backClick (myevent:MouseEvent):void {<br />
&nbsp; &nbsp; &nbsp; &nbsp; this.gotoAndStop(currentFrame-1);<br />
}<br />
//Hide Button on Frame 1<br />
Object(this).popUpAnim_mc.PopUp_mc.back_btn.visible=false;<br />
//constantly check current frame to determine if it should be hidden<br />
this.addEventListener (Event.ENTER_FRAME, BackButtonVis);<br />
function BackButtonVis (event:Event):void{<br />
if(this.currentFrame==1||(currentFrame==totalFrames)){<br />
&nbsp; &nbsp; &nbsp; &nbsp; Object(this).popUpAnim_mc.PopUp_mc.back_btn.visible=false;<br />
}else{<br />
&nbsp; &nbsp; &nbsp; &nbsp; Object(this).popUpAnim_mc.PopUp_mc.back_btn.visible=true;<br />
}<br />
}<br />
this.popUpAnim_mc.PopUp_mc.back_btn.addEventListener(MouseEvent.CLICK, popAnim);</code><hr />
</div> there are two other buttons that have different functions that I want to also run the animation...but if I can just get one to work, I'm hoping the other two will be easy.<br />
<br />
Thanks in advance!</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>Karacature</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830489-getting-multiple-buttons-to-play-the-same-animation.</guid>
		</item>
		<item>
			<title>If statements that load Text according to the Day of the week..</title>
			<link>http://board.flashkit.com/board/showthread.php?830481-If-statements-that-load-Text-according-to-the-Day-of-the-week..&amp;goto=newpost</link>
			<pubDate>Wed, 15 May 2013 01:43:40 GMT</pubDate>
			<description><![CDATA[I am so stuck on this. I have never worked with Dates/Days in AS3 and I cannot figure this out.

What I need is a code that pulls up different .txt files depending on what day of the week it is. So...If it's Monday it loads Monday.txt, if it's Tuesday it loads Tuesday.txt and so on.

In case it matters I'm working in Flash CS4 and AS3. Using this code for a site for a friends bar, they have daily specials that change almost every week. So I want him to be able to change the text with out involving me. Hence the .txt files...and he thought it would be cool to have it on the home page saying "Hey it's Monday come in during Happy hour for $2 tequila shots"

Any helps or pointers would be awesome!

Cheers!]]></description>
			<content:encoded><![CDATA[<div>I am so stuck on this. I have never worked with Dates/Days in AS3 and I cannot figure this out.<br />
<br />
What I need is a code that pulls up different .txt files depending on what day of the week it is. So...If it's Monday it loads Monday.txt, if it's Tuesday it loads Tuesday.txt and so on.<br />
<br />
In case it matters I'm working in Flash CS4 and AS3. Using this code for a site for a friends bar, they have daily specials that change almost every week. So I want him to be able to change the text with out involving me. Hence the .txt files...and he thought it would be cool to have it on the home page saying &quot;Hey it's Monday come in during Happy hour for $2 tequila shots&quot;<br />
<br />
Any helps or pointers would be awesome!<br />
<br />
Cheers!</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>MsChrissyAnn</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830481-If-statements-that-load-Text-according-to-the-Day-of-the-week..</guid>
		</item>
		<item>
			<title>AS3 Presentation Template - adding buttons for every slide</title>
			<link>http://board.flashkit.com/board/showthread.php?830477-AS3-Presentation-Template-adding-buttons-for-every-slide&amp;goto=newpost</link>
			<pubDate>Tue, 14 May 2013 15:03:19 GMT</pubDate>
			<description><![CDATA[I have a presentation made from the 'presentation template' in AS3. Currently, it has the nextframe and prevframe buttons on the main timeline Hierarchy =  main timeline > movie clip > keyframes on frame 1, 2, 3, 4, with movie clips on each of those keyframes.

They want a button for EVERY frame, so if they are at frame 40, they can easily click one button to get to frame 2. How do I do this? I've tried to add buttons, but they're not working correctly. I don't know what layer to put them on, etc. I've tried frame labels.. everything. Please help!

Main timeline:
Attachment 74253 (http://board.flashkit.com/board/attachment.php?attachmentid=74253)

Slides nested within layer "Slides MovieClip" (instance name= slides_mc):
Attachment 74255 (http://board.flashkit.com/board/attachment.php?attachmentid=74255)

A sample of what's in one of the keyframes in the layer "Slides" - this is a movie with instance name slide1871
Attachment 74257 (http://board.flashkit.com/board/attachment.php?attachmentid=74257)]]></description>
			<content:encoded><![CDATA[<div>I have a presentation made from the 'presentation template' in AS3. Currently, it has the nextframe and prevframe buttons on the main timeline Hierarchy =  main timeline &gt; movie clip &gt; keyframes on frame 1, 2, 3, 4, with movie clips on each of those keyframes.<br />
<br />
They want a button for EVERY frame, so if they are at frame 40, they can easily click one button to get to frame 2. How do I do this? I've tried to add buttons, but they're not working correctly. I don't know what layer to put them on, etc. I've tried frame labels.. everything. Please help!<br />
<br />
Main timeline:<br />
<a href="http://board.flashkit.com/board/attachment.php?attachmentid=74253"  title="Name:  
Views: 
Size:  ">Attachment 74253</a><br />
<br />
Slides nested within layer &quot;Slides MovieClip&quot; (instance name= slides_mc):<br />
<a href="http://board.flashkit.com/board/attachment.php?attachmentid=74255"  title="Name:  
Views: 
Size:  ">Attachment 74255</a><br />
<br />
A sample of what's in one of the keyframes in the layer &quot;Slides&quot; - this is a movie with instance name slide1871<br />
<a href="http://board.flashkit.com/board/attachment.php?attachmentid=74257"  title="Name:  
Views: 
Size:  ">Attachment 74257</a></div>


	<div style="padding:10px">

	

	

	
		<fieldset class="fieldset">
			<legend>Attached Images</legend>
			<ul>
			<li>
	<img class="inlineimg" src="/png.gif" alt="File Type: png" />
	<a href="http://board.flashkit.com/board/attachment.php?attachmentid=74253&amp;d=1368543655" target="_blank">Screen Shot 2013-05-14 at 9.59.12 AM.png&lrm;</a> 
(20.6 KB)
</li> <li>
	<img class="inlineimg" src="/png.gif" alt="File Type: png" />
	<a href="http://board.flashkit.com/board/attachment.php?attachmentid=74255&amp;d=1368543725" target="_blank">Screen Shot 2013-05-14 at 9.59.24 AM.png&lrm;</a> 
(17.0 KB)
</li> <li>
	<img class="inlineimg" src="/png.gif" alt="File Type: png" />
	<a href="http://board.flashkit.com/board/attachment.php?attachmentid=74257&amp;d=1368543726" target="_blank">Screen Shot 2013-05-14 at 9.59.38 AM.png&lrm;</a> 
(70.7 KB)
</li> 
			</ul>
			</fieldset>
	

	

	</div>
 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>Kelly v</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830477-AS3-Presentation-Template-adding-buttons-for-every-slide</guid>
		</item>
		<item>
			<title>MouseOver problem - Simple Gallery and Text</title>
			<link>http://board.flashkit.com/board/showthread.php?830467-MouseOver-problem-Simple-Gallery-and-Text&amp;goto=newpost</link>
			<pubDate>Mon, 13 May 2013 23:26:03 GMT</pubDate>
			<description><![CDATA[I'm running CS6 windows 64bit 
Actionscript 3.0

I am trying to make a simple MouseOver gallery ...

I have a banner of 4 pics as buttons, when I MouseOver the pic the (appropriate) text should show, it kind of does but it jiggles and flashes on the screen.

The gallery should have 4 pics but I have removed them to reduce file size so I can upload here.

I did inc the full actionscript tho.




PHP:
---------
stop();

al_btn.addEventListener(MouseEvent.MOUSE_OVER,abuttonOver);
function abuttonOver(event:MouseEvent):void
{
	gotoAndStop(5);
}
al_btn.addEventListener(MouseEvent.MOUSE_OUT,abuttonOut);
function abuttonOut(event:MouseEvent):void
{
	gotoAndStop(1);
}
	
	
	dik_btn.addEventListener(MouseEvent.MOUSE_OVER,bbuttonOver);
function bbuttonOver(event:MouseEvent):void
{
	gotoAndStop(10);
}
dik_btn.addEventListener(MouseEvent.MOUSE_OUT,bbuttonOut);
function bbuttonOut(event:MouseEvent):void
{
	gotoAndStop(1);
}
	
	lab_btn.addEventListener(MouseEvent.MOUSE_OVER,cbuttonOver);
function cbuttonOver(event:MouseEvent):void
{
	gotoAndStop(15);
}
lab_btn.addEventListener(MouseEvent.MOUSE_OUT,cbuttonOut);
function cbuttonOut(event:MouseEvent):void
{
	gotoAndStop(1);
}
	
	mal_btn.addEventListener(MouseEvent.MOUSE_OVER,dbuttonOver);
function dbuttonOver(event:MouseEvent):void
{
	gotoAndStop(20);
}
mal_btn.addEventListener(MouseEvent.MOUSE_OUT,dbuttonOut);
function dbuttonOut(event:MouseEvent):void
{
	gotoAndStop(1);
	}
---------
]]></description>
			<content:encoded><![CDATA[<div>I'm running CS6 windows 64bit <br />
Actionscript 3.0<br />
<br />
I am trying to make a simple MouseOver gallery ...<br />
<br />
I have a banner of 4 pics as buttons, when I MouseOver the pic the (appropriate) text should show, it kind of does but it jiggles and flashes on the screen.<br />
<br />
The gallery should have 4 pics but I have removed them to reduce file size so I can upload here.<br />
<br />
I did inc the full actionscript tho.<br />
<br />
<br />
<br />
<div class="bbcode_container">
	<div class="bbcode_description">PHP Code:</div>
	<hr /><code class="bbcode_code"><code><span style="color: #000000">
<span style="color: #0000BB">stop</span><span style="color: #007700">();<br /><br /></span><span style="color: #0000BB">al_btn</span><span style="color: #007700">.</span><span style="color: #0000BB">addEventListener</span><span style="color: #007700">(</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">.</span><span style="color: #0000BB">MOUSE_OVER</span><span style="color: #007700">,</span><span style="color: #0000BB">abuttonOver</span><span style="color: #007700">);<br />function&nbsp;</span><span style="color: #0000BB">abuttonOver</span><span style="color: #007700">(</span><span style="color: #0000BB">event</span><span style="color: #007700">:</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">):</span><span style="color: #0000BB">void<br /></span><span style="color: #007700">{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">gotoAndStop</span><span style="color: #007700">(</span><span style="color: #0000BB">5</span><span style="color: #007700">);<br />}<br /></span><span style="color: #0000BB">al_btn</span><span style="color: #007700">.</span><span style="color: #0000BB">addEventListener</span><span style="color: #007700">(</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">.</span><span style="color: #0000BB">MOUSE_OUT</span><span style="color: #007700">,</span><span style="color: #0000BB">abuttonOut</span><span style="color: #007700">);<br />function&nbsp;</span><span style="color: #0000BB">abuttonOut</span><span style="color: #007700">(</span><span style="color: #0000BB">event</span><span style="color: #007700">:</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">):</span><span style="color: #0000BB">void<br /></span><span style="color: #007700">{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">gotoAndStop</span><span style="color: #007700">(</span><span style="color: #0000BB">1</span><span style="color: #007700">);<br />}<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">dik_btn</span><span style="color: #007700">.</span><span style="color: #0000BB">addEventListener</span><span style="color: #007700">(</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">.</span><span style="color: #0000BB">MOUSE_OVER</span><span style="color: #007700">,</span><span style="color: #0000BB">bbuttonOver</span><span style="color: #007700">);<br />function&nbsp;</span><span style="color: #0000BB">bbuttonOver</span><span style="color: #007700">(</span><span style="color: #0000BB">event</span><span style="color: #007700">:</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">):</span><span style="color: #0000BB">void<br /></span><span style="color: #007700">{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">gotoAndStop</span><span style="color: #007700">(</span><span style="color: #0000BB">10</span><span style="color: #007700">);<br />}<br /></span><span style="color: #0000BB">dik_btn</span><span style="color: #007700">.</span><span style="color: #0000BB">addEventListener</span><span style="color: #007700">(</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">.</span><span style="color: #0000BB">MOUSE_OUT</span><span style="color: #007700">,</span><span style="color: #0000BB">bbuttonOut</span><span style="color: #007700">);<br />function&nbsp;</span><span style="color: #0000BB">bbuttonOut</span><span style="color: #007700">(</span><span style="color: #0000BB">event</span><span style="color: #007700">:</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">):</span><span style="color: #0000BB">void<br /></span><span style="color: #007700">{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">gotoAndStop</span><span style="color: #007700">(</span><span style="color: #0000BB">1</span><span style="color: #007700">);<br />}<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">lab_btn</span><span style="color: #007700">.</span><span style="color: #0000BB">addEventListener</span><span style="color: #007700">(</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">.</span><span style="color: #0000BB">MOUSE_OVER</span><span style="color: #007700">,</span><span style="color: #0000BB">cbuttonOver</span><span style="color: #007700">);<br />function&nbsp;</span><span style="color: #0000BB">cbuttonOver</span><span style="color: #007700">(</span><span style="color: #0000BB">event</span><span style="color: #007700">:</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">):</span><span style="color: #0000BB">void<br /></span><span style="color: #007700">{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">gotoAndStop</span><span style="color: #007700">(</span><span style="color: #0000BB">15</span><span style="color: #007700">);<br />}<br /></span><span style="color: #0000BB">lab_btn</span><span style="color: #007700">.</span><span style="color: #0000BB">addEventListener</span><span style="color: #007700">(</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">.</span><span style="color: #0000BB">MOUSE_OUT</span><span style="color: #007700">,</span><span style="color: #0000BB">cbuttonOut</span><span style="color: #007700">);<br />function&nbsp;</span><span style="color: #0000BB">cbuttonOut</span><span style="color: #007700">(</span><span style="color: #0000BB">event</span><span style="color: #007700">:</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">):</span><span style="color: #0000BB">void<br /></span><span style="color: #007700">{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">gotoAndStop</span><span style="color: #007700">(</span><span style="color: #0000BB">1</span><span style="color: #007700">);<br />}<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">mal_btn</span><span style="color: #007700">.</span><span style="color: #0000BB">addEventListener</span><span style="color: #007700">(</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">.</span><span style="color: #0000BB">MOUSE_OVER</span><span style="color: #007700">,</span><span style="color: #0000BB">dbuttonOver</span><span style="color: #007700">);<br />function&nbsp;</span><span style="color: #0000BB">dbuttonOver</span><span style="color: #007700">(</span><span style="color: #0000BB">event</span><span style="color: #007700">:</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">):</span><span style="color: #0000BB">void<br /></span><span style="color: #007700">{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">gotoAndStop</span><span style="color: #007700">(</span><span style="color: #0000BB">20</span><span style="color: #007700">);<br />}<br /></span><span style="color: #0000BB">mal_btn</span><span style="color: #007700">.</span><span style="color: #0000BB">addEventListener</span><span style="color: #007700">(</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">.</span><span style="color: #0000BB">MOUSE_OUT</span><span style="color: #007700">,</span><span style="color: #0000BB">dbuttonOut</span><span style="color: #007700">);<br />function&nbsp;</span><span style="color: #0000BB">dbuttonOut</span><span style="color: #007700">(</span><span style="color: #0000BB">event</span><span style="color: #007700">:</span><span style="color: #0000BB">MouseEvent</span><span style="color: #007700">):</span><span style="color: #0000BB">void<br /></span><span style="color: #007700">{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">gotoAndStop</span><span style="color: #007700">(</span><span style="color: #0000BB">1</span><span style="color: #007700">);<br />&nbsp;&nbsp;&nbsp;&nbsp;}&nbsp;<br /></span><span style="color: #0000BB"></span>
</span>
</code></code><hr />
</div> </div>


	<div style="padding:10px">

	

	

	

	
		<fieldset class="fieldset">
			<legend>Attached Files</legend>
			<ul>
			<li>
	<img class="inlineimg" src="/fla.gif" alt="File Type: fla" />
	<a href="http://board.flashkit.com/board/attachment.php?attachmentid=74251&amp;d=1368487167">dogs_test_al_only.fla&lrm;</a> 
(44.9 KB)
</li> 
			</ul>
		</fieldset>
	

	</div>
 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>Pixa</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830467-MouseOver-problem-Simple-Gallery-and-Text</guid>
		</item>
		<item>
			<title>Male / Female voice option</title>
			<link>http://board.flashkit.com/board/showthread.php?830465-Male-Female-voice-option&amp;goto=newpost</link>
			<pubDate>Mon, 13 May 2013 22:31:09 GMT</pubDate>
			<description><![CDATA[Hi,

I'd like to include a Male or Female voice option in an app that I'm making.

The option will be in a SETTINGS scene.

I'm assuming that I need to put both lots of audio into different librarys and have the option reference either one.

Can someone give me some help with this please?

Cheers,

Barry]]></description>
			<content:encoded><![CDATA[<div>Hi,<br />
<br />
I'd like to include a Male or Female voice option in an app that I'm making.<br />
<br />
The option will be in a SETTINGS scene.<br />
<br />
I'm assuming that I need to put both lots of audio into different librarys and have the option reference either one.<br />
<br />
Can someone give me some help with this please?<br />
<br />
Cheers,<br />
<br />
Barry</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>squirt</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830465-Male-Female-voice-option</guid>
		</item>
		<item>
			<title>Loading images from library through a loop</title>
			<link>http://board.flashkit.com/board/showthread.php?830463-Loading-images-from-library-through-a-loop&amp;goto=newpost</link>
			<pubDate>Mon, 13 May 2013 20:42:33 GMT</pubDate>
			<description><![CDATA[Okay I have much MCs named 'object1','object2','object3',etc...
But for testing and example I will use just 10.
So what I need is attaching an image to its own MC. Images are in library and they are named 's1','s2','s3',etc..
This is how far I got with scripting:

PHP:
---------
import flash.utils.getDefinitionByName;


for (var i:uint=1; i<=10;i++) {
	
	var s:String = "s"+i;
	//var cr:String = "CR"+i; something is wrong here xS
	var cr:Class = getDefinitionByName(s) as Class;
	var ss:Bitmap = new Bitmap( new cr(0,0));
	var obj:* = "obeject"+i;
	obj.addChild(ss);
	
}

/*
var s1:String = "s"+1;
var ClassReference01:Class = getDefinitionByName(s1) as Class;
var ss1:Bitmap = new Bitmap( new ClassReference01(0,0));
object1.addChild(ss1);*/
---------
Can you help me out?
Thanks.]]></description>
			<content:encoded><![CDATA[<div>Okay I have much MCs named 'object1','object2','object3',etc...<br />
But for testing and example I will use just 10.<br />
So what I need is attaching an image to its own MC. Images are in library and they are named 's1','s2','s3',etc..<br />
This is how far I got with scripting:<br />
<div class="bbcode_container">
	<div class="bbcode_description">PHP Code:</div>
	<hr /><code class="bbcode_code"><code><span style="color: #000000">
<span style="color: #0000BB">import&nbsp;flash</span><span style="color: #007700">.</span><span style="color: #0000BB">utils</span><span style="color: #007700">.</span><span style="color: #0000BB">getDefinitionByName</span><span style="color: #007700">;<br /><br /><br />for&nbsp;(var&nbsp;</span><span style="color: #0000BB">i</span><span style="color: #007700">:</span><span style="color: #0000BB">uint</span><span style="color: #007700">=</span><span style="color: #0000BB">1</span><span style="color: #007700">;&nbsp;</span><span style="color: #0000BB">i</span><span style="color: #007700">&lt;=</span><span style="color: #0000BB">10</span><span style="color: #007700">;</span><span style="color: #0000BB">i</span><span style="color: #007700">++)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;</span><span style="color: #0000BB">s</span><span style="color: #007700">:</span><span style="color: #0000BB">String&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #DD0000">"s"</span><span style="color: #007700">+</span><span style="color: #0000BB">i</span><span style="color: #007700">;<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #FF8000">//var&nbsp;cr:String&nbsp;=&nbsp;"CR"+i;&nbsp;something&nbsp;is&nbsp;wrong&nbsp;here&nbsp;xS<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">var&nbsp;</span><span style="color: #0000BB">cr</span><span style="color: #007700">:Class&nbsp;=&nbsp;</span><span style="color: #0000BB">getDefinitionByName</span><span style="color: #007700">(</span><span style="color: #0000BB">s</span><span style="color: #007700">)&nbsp;as&nbsp;Class;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;</span><span style="color: #0000BB">ss</span><span style="color: #007700">:</span><span style="color: #0000BB">Bitmap&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">Bitmap</span><span style="color: #007700">(&nbsp;new&nbsp;</span><span style="color: #0000BB">cr</span><span style="color: #007700">(</span><span style="color: #0000BB">0</span><span style="color: #007700">,</span><span style="color: #0000BB">0</span><span style="color: #007700">));<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;</span><span style="color: #0000BB">obj</span><span style="color: #007700">:*&nbsp;=&nbsp;</span><span style="color: #DD0000">"obeject"</span><span style="color: #007700">+</span><span style="color: #0000BB">i</span><span style="color: #007700">;<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">obj</span><span style="color: #007700">.</span><span style="color: #0000BB">addChild</span><span style="color: #007700">(</span><span style="color: #0000BB">ss</span><span style="color: #007700">);<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />}<br /><br /></span><span style="color: #FF8000">/*<br />var&nbsp;s1:String&nbsp;=&nbsp;"s"+1;<br />var&nbsp;ClassReference01:Class&nbsp;=&nbsp;getDefinitionByName(s1)&nbsp;as&nbsp;Class;<br />var&nbsp;ss1:Bitmap&nbsp;=&nbsp;new&nbsp;Bitmap(&nbsp;new&nbsp;ClassReference01(0,0));<br />object1.addChild(ss1);*/&nbsp;<br /></span><span style="color: #0000BB"></span>
</span>
</code></code><hr />
</div> Can you help me out?<br />
Thanks.</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>Morsus</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830463-Loading-images-from-library-through-a-loop</guid>
		</item>
		<item>
			<title>Best way to display a video both on a main and secondary screen (synced)</title>
			<link>http://board.flashkit.com/board/showthread.php?830455-Best-way-to-display-a-video-both-on-a-main-and-secondary-screen-(synced)&amp;goto=newpost</link>
			<pubDate>Mon, 13 May 2013 08:54:02 GMT</pubDate>
			<description>Hi,
Im writting an AIR desktop application.
I want to show a HD MP4 video on a main screen and also show the same instance of the video running on the secondary screen.
Can anybody think of a good way of doing this?
 
The only way Ive thought of doing it is to have to my two air programs running and for them to chat through a local connection.
 
When a mp4 is played in the main air file it tells the secondary air file to also play it.
I then send every x amount seconds what frame the main exe is onto the secondary file to try and keep it synchronized...
 
..Any ideas?
 
Thanks
Aidan</description>
			<content:encoded><![CDATA[<div>Hi,<br />
Im writting an AIR desktop application.<br />
I want to show a HD MP4 video on a main screen and also show the same instance of the video running on the secondary screen.<br />
Can anybody think of a good way of doing this?<br />
 <br />
The only way Ive thought of doing it is to have to my two air programs running and for them to chat through a local connection.<br />
 <br />
When a mp4 is played in the main air file it tells the secondary air file to also play it.<br />
I then send every x amount seconds what frame the main exe is onto the secondary file to try and keep it synchronized...<br />
 <br />
..Any ideas?<br />
 <br />
Thanks<br />
Aidan</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>aidanmack</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830455-Best-way-to-display-a-video-both-on-a-main-and-secondary-screen-(synced)</guid>
		</item>
		<item>
			<title>Seamless flv loop</title>
			<link>http://board.flashkit.com/board/showthread.php?830445-Seamless-flv-loop&amp;goto=newpost</link>
			<pubDate>Sun, 12 May 2013 18:31:22 GMT</pubDate>
			<description><![CDATA[Heya. I'm very new to flash and I'm trying to loop a couple of flv files with Flash. I'm currently using the following code I dug up somewhere:

Code:
---------
import fl.video.VideoEvent;
flvClip.addEventListener(fl.video.VideoEvent.COMPLETE, videoFinished);
function videoFinished(event:Event){
flvClip.play();
};
---------
The problem is that every time the file loops there is a split-second flicker, like a transparent frame between the last and first frame of the flv. Could somebody perhaps lend advice on how to get rid of this flicker?]]></description>
			<content:encoded><![CDATA[<div>Heya. I'm very new to flash and I'm trying to loop a couple of flv files with Flash. I'm currently using the following code I dug up somewhere:<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">import fl.video.VideoEvent;<br />
flvClip.addEventListener(fl.video.VideoEvent.COMPLETE, videoFinished);<br />
function videoFinished(event:Event){<br />
flvClip.play();<br />
};</code><hr />
</div> The problem is that every time the file loops there is a split-second flicker, like a transparent frame between the last and first frame of the flv. Could somebody perhaps lend advice on how to get rid of this flicker?</div>

 ]]></content:encoded>
			<category domain="http://board.flashkit.com/board/forumdisplay.php?102-Actionscript-3.0-(incl.-Flex-AIR)">Actionscript 3.0 (incl. Flex/AIR)</category>
			<dc:creator>Svalbart</dc:creator>
			<guid isPermaLink="true">http://board.flashkit.com/board/showthread.php?830445-Seamless-flv-loop</guid>
		</item>
	</channel>
</rss>
