So I am working on a project in which I need to trigger a click event. However, its a little more complicated then just that. I know how to dispatch an event by doing btn.dispatchEvent(), but the problem is I dont know which button it will be. Basically I am creating a wheel that spins. I need to trigger the click event of the element th...
Hi guys,
First of all, I am new to AS3. What I am trying to do is to make the ball, rotate in circular form. This is my current code:
this is the Circular.as
public class Circular extends Sprite {
private var ball:Ball;
private var centerX:Number = stage.stageWidth / 2;
private var centerY:Number = stage.stageHeight / 2;
...
Hello, are there any compilers for ActionScript 3 under *nix like systems or appropriate toolkit to work with Flash?
...
I want to create an endless loop, 8 items moving in a circular shape. When you roll over of each item, it will stop the moving, and you should be able to click it.
I dont know what should I use, should I use Event.ENTER_FRAME or the circular shape should be in movie clip, so that when there is a mouse over event, it will stop moving? I ...
Hi,
I am having trouble getting a Flex application (with as3httpclient) to work.
I compiled it (compc -load-config=build-swc.xml), put the as3httpclientlib-1_0_6.swc in my libs dir, and ran
mxmlc -compiler.include-libraries lib/as3crypto-1_3_patched.swc
lib/as3httpclientlib-1_0_6.swc lib/corelib.swc -- App.mxml
In my actionscript I ...
I'm building a realtime action multiplayer game in Flash which is using too much bandwidth because it sends message objects as XML (as required by the Smartfox server). I'm now trying to cut down on that by serializing my objects to strings before feeding them to Smartfox.
I've tried JSON but it doesn't help much. Is there another seria...
I'm struggling to make a flexible data structure (like a relational database) for a quiz in ActionScript 3.0.
I have a number of questions, each with 2 alternatives:
Questions
| id | alt1 | alt2 | correctAlt |
---------------------------------------
| 0 | Sweden | Denmark | 1 |
| 1 | Norway | Finland | 2 |...
I am having an issue with printing with the PrintJob class in Flex 4.
Basically it should print 3 pages, each with a colored square. It works for me in Chrome and Firefox, but if I test it in IE I get the following error:
Error: Error #2057: The page could not be added to the print job.
at Error$/throwError()
at flash.printin...
For diagnostic purposes, I want to print a matrix (an array of arrays). To do this with a loop means executing a trace command multiple times, whichto my understandingprecludes the possibility of printing multiple table cells to a single row.
(When coding trace(x); trace(y);, a line break falls between x and y.)
What can I do?
...
For the downrankers:
I have searched this question in the internet and found countless posts. But neither worked because of a small problem here or there, and when I though of posting my problems in the same thread I realized its a month/year/millennium old. So I'm gonna ask here.
For other people:
How do I switch scenes within a flas...
One of my decoration bitmaps covers up some important elements in my flex application. The problem is these elements become not clickable. How could make the bitmap not clickable or how could I pass the click event along to those children elements below?
...
I'm trying to put my components in a window container that can be closed by "x" moved on the stage, resized and so on. And I wonder which is the best way to do it. I want to use a skin class and the component class. The "solution" that is not working looks like this:
take a look at this and if you have a better idea on how to implement ...
Hi
I want to use compiled clips to speed up compilation.
But I've found following problem:
I've got Foo class, which extends MovieClip and is set as 'Class' to one of library's symbol (this symbol is also called Foo).
This symbol (Foo) has a MovieClip child, whose instance name is FOO_CHILD. I'm referencing this child inside Foo clas...
I have a class named Level which inherits MovieClip. Level has a child in the designer with the name gridView and the gridView is used in Level constructor.
I have also class named Level1 which inherits Level. when I try something like addChild(new Level1()) I get error in Level constructor saying gridView is null. What am I doing wrong?...
If something is visible, does calling
movieclipname.visible = true;
each frame do anything performance wise?
...
The link elements I'm talking about are single words, so they are not wrapped inside the container, which means that they should have a single bounding rectangle. But how do I go about finding this rectangle? I'm familiar with Flex3 but don't know enough about the new Text Layout Engine in Flex4.
Can someone help me please? Thanks!
...
Anyone out there can help me with this?
I am facing some problem on preloading swf in Chrome and IE.
It only works in Firefox.
When i preload flash, Iam getting bytesTotal as 0.
So when i bytesLoaded divide by bytesTotal will cause infinity.
I read this article on GZIP.
http://patrickmcd.com/2009/04/20/flash-preloading-errors-turn-off...
Here's my problem: I have a NetConnection object connected to a server. On top I create a NetStream object and it started to play a file from the server. Classic so far.
What I need now, is to be able to send some (short) messages back to the server, at various moments during playtime but, clearly, using the existing TCP connection.
Fr...
I have two SWFs: main.swf and external.swf. main.swf needs to access some methods in external.swf, so it loads external.swf into itself and uses getDefinitionByName("package.Class") to access the class and one of its methods:
var ExternalClass = getDefinitionByName("package.Class") as Class;
var ClassInstance = new ExternalClass();
var...
Ok, so I swear this question should be all over the place, but its not.
I have a value object, inside are lots of getters/setters. It is not a dynamic class. And I desperately need to search an ArrayCollection filled with them. The search spans all fields, so and there are about 13 different types of VOs I'll be doing this with.
I've t...