Here is the class I use for dynamic instantiation. Note that it throws a
custom exception type, you'll have to create that type yourself or alter
that line of code. I copied the instantiation technique from Drew
Cummins at blog.generalrelativity.org.
class
On 3/24/08, Naveen Bhaskar [EMAIL PROTECTED] wrote:
Hi,
I am a flash designer and I am in intermediate in programming.(AS2).
anybody pls tellme what are the good books I can refer.
And remember, just learning Actionscript in particular will not teach
you programming in general.
, and performing regular checkins to our source control system
for code reviews.
Please respond to [EMAIL PROTECTED] Thank you!
Alan MacDougall
The Phoenix Group
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman
After I create a clip with attachMovieClip, I attempt to write a
DropShadowFilter to it using the following code:
var shadow:DropShadowFilter = new DropShadowFilter(
5,// distance
45,// angle
0x66,// color
Alan MacDougall wrote:
After I create a clip with attachMovieClip, I attempt to write a
DropShadowFilter to it using the following code:
var shadow:DropShadowFilter = new DropShadowFilter(
5,// distance
45,// angle
0x66
Hal Leonard wrote:
Yeah in CS3 that's the case - regardless of whether you are using AS2 or
AS3. But to my knowledge, in Flash 8, it is still 0 to 100.
No, that was the problem: In the Flash 8 authoring environment, you set
a 0-100 percentage. But in Actionscript 2.0, the
Muzak wrote:
AFAIK, both are between 0 and 1.
The default value for strength = 1, meaning 100% strength.
If strength would take a value between 0 and 255 a default of 1 would make no
sense at all (well at least not to me).
Well, the docs are correct: you can set absurd strength values
julian atienza wrote:
To avoid loading twice times the image (first in 100% and second in
thumbnail navigation image) ... how could i copy content of first
movieclip to second one with fixed size
I did something similar to this while trying to implement my own
Bitmap-based magnifying glass
Dave Mennenoh wrote:
To avoid loading twice times the image (first in 100% and second in
thumbnail navigation image) ... how could i copy content of first
movieclip to second one with fixed size?
You can't really, but since the image is cached once it's downloaded
the first time, loading it
julian atienza wrote:
Image is 72Mb.
This is your first problem. I can't think of a single reason you would
have to load a 72 MB image into Flash. Could you tell us a little more
about your application?
___
Flashcoders@chattyfig.figleaf.com
To
julian atienza wrote:
but i'm not sure if it's going ok... at least now i haven't to make
another load but... i think the thumbnail is scaling the portion of
big image i see in screen, not the whole image...
That might be a limitation of Flash. I'm not sure what happens when
MovieClips
Further derail! What are people's thoughts on implicit vs. explicit
accessors? I prefer explicit ones, but I confess that it's almost
entirely because I learned Java before Actionscript. You can't argue
that explicit setters are required for a serious language, because C#
prefers implicit
And another point: Suppose you start out making something as a public
field and then later realize you need to restrict its value in some
way. With properties, this change will make absolutely no difference
to the rest of your code. Without properties, you will have to change
every instance of
Jer Brand wrote:
Coming from someone who's never done this, and doesn't know if it's
possible, but:
Would it be possible to capture your user created design in BitmapData (I
was fairly sure there's a method to extract pixel info from a MovieClip,
correct?) then transmit that back to the server
Start small and work your way up. You don't need classes until the
functions start to get unmanageable. That won't happen until you've
thoroughly covered variables and control structures. By the time classes
are necessary, the students should be relieved to have a way to organize
their forest
I don't think you need to call it procedural. Just call it the basic
building blocks that they will need for OOP (or procedural, for that
matter).
There's not that much difference, really, between OOP and procedural. OOP
just encapsulates chunks of procedural code and its data.
This is the
Jer Brand wrote:
Uncompressed, yeah, that'd be ugly. But how does something like the
following (guesswork code) perform?
foo:BitmapData = new BitmapData() ;
/* put your image data in there, with whatever method */
bar:ByteArray = foo.getPixels(myImageRect) ;
var.compress() ;
Again, mostly
Dave Mennenoh wrote:
Lots of programmers never need design patterns as they don't help much
unless your architecting large apps, and lots of Flash programmers
aren't developing those kinds of apps. Keeping your code organized
however should be taught from day one and certain oop concepts are
bassam mohaisen wrote:
Hi all
I'm trying to do e-tshirt design where the user can desgin his shirt and add
text or images so I need to know how can I save the design as image or swf for
the design how can I take screenshot , if somebody know the concept and the
code .
all the text and photos
Marcelo de Moraes Serpa wrote:
Hello folks,
I'm currently mainly a coder, but I also love graphics design and design in
general. I would love to improve my overall design awareness. Does anyone
have any book (or any other resource such as website, magazine, mailing
list, whatever) to recommend
Ron Wheeler wrote:
One of the best books is Head First Design Patterns.
Really nice code. Well explained and shows how to get a lot of mileage
out of code through thoughtful design.
It will make you a better coder and get you thinking about design in
new ways.
He was talking about graphic
Compare these two situations:
class SuperClass
{
private var list:Array;
public function SuperClass()
{
list = new Array();
}
}
class SubClass extends SuperClass
{
// when instantiated, the list variable is automatically initialized
}
This is as it should be. The
Hans Wichman wrote:
Hi,
when the superclass has a default contructor without parameters, there is no
need to call it explicitly.
I'd like to turn it around though, no matter what or how you have defined
them, always call them explicitly for clarity's sake and self documentation.
So if the
Steven Sacks wrote:
If you do not do anything with an imported class, Flash will not
compile it.
Or, to take it a step further, make a class named ClassRegistry (or some
such), which defines but does not instantiate private static instances
of every class you want to load dynamically. Then
Omar Fouad wrote:
is there a way attach a library item from a loaded swf. I think this would
be the best solution...
This suggestion hits close to the correct answer. Really, if your
library is so big that it's killing your app's startup time, your wisest
option is to load the items on
Volker Scarpatetti - Advertis Interactiva wrote:
Hi !
Is there a way to know how many lines are written in a textArea component
when filling it up dynamically ?
This is not a perfect solution, but if you know the TextField.textHeight
when there is a single line, you should be able to do a
Micky Hulse wrote:
Pedro Taranto wrote:
if you want to return diferent types in one function you dont specify
any return data type
Ah, sounds good to me. I was not sure if it was bad practice to not
specify a type.
Well, if you want to write strictly, and if you're interested in exactly
Omar Fouad wrote:
I am doing some application on flash that uses an XML file to store
data...
This application has a search form. I understand how to get through
the xml
by loops but i can't figure out how to get flash to know if this
word is
included within the xml nodes or not... Any simple
Alan MacDougall wrote:
This looks completely straightforward and identical to Java... but
when I do it, it catches the generic error. Now, obviously an Error
instance is getting caught, which means one is getting thrown, which
means my InvalidPathFormatException IS being recognized
Omar Fouad wrote:
com.xfactorstudio.xml.xpath??? where can i get it???
Well, XPath is just one way of searching through an XML document to get
specific nodes. As you might guess from the package name, this
particular implementation can be found at www.xfactorstudio.com . You
can learn more
Chris W. Paterson wrote:
this.firstChild.childNodes[i].firstChild.childNodes[j].childNodes;--- this is
how I am trying to
access the content of that node.
First off, I'm guessing I should use .nodeValue? Will that give me the entire
node with
![CDATA[]]? Is it even possible to read the html
Okay, here's one for you. I extended Error with a very simple specific
error type, like this:
class com.mycompany.exceptions.InvalidPathFormatException extends Error
{
public function InvalidPathFormatException(message:String)
{
if (message != null)
{
this.message =
Danny Kodicek wrote:
The only method I can think of that might do what you're looking for is to
have some of the actual code work on the server. So for example you'd do
something that has a fundamental effect in the game, but you make its code
run on your server instead of on the client and
There's a constant demand for SWF obfuscation -- any good application,
especially things like standalone games, is a ripe target for theft and
rebranding. *cough ebaumsworld cough* And business clients are often
afraid of plagiarism by real or imagined rivals: if they didn't want to
be the
Van Tuck wrote:
List -
A client is inquiring about a web-based system that would allow the
user to type in a question, have the algorithm compare the input
character-by-character to a predefined list of answers until all but
one answer had been removed and the correct answer returned.
2007/7/16, John laPlante [EMAIL PROTECTED]:
I'm writing a component and have created a MovieClip with
createEmptyMovieClip. When I try to create sub-MovieClip inside the
first MC with createEmptyMovieClip, it is undefined. This must be a
basic Flash thing. I haven't used
Julian Bleecker wrote:
That's great Ian — thanks for the help! Each of those little idioms
makes sense when described — I never would've figured these out just
whacking at various permutations, particularly the very baroque
incantation leveraging the invisible symbol names.
You may find
Karthik wrote:
Mates,
I have a prospective client who wants to have a Flash application
(AMFPHP). This is the first time for me so I need to know how much I
should charge him.
Can we please keep the list on topic? This is a coding-related list.
Topics such as this and Outsourcing etc.
Rich Rodecker wrote:
check out flashkart.
On 2/8/06, stone larsen [EMAIL PROTECTED] wrote:
I am looking to hire someone for a fully functional apparel based flash
cart using paypal as the merchant.
Key needs: XML powered, easily updateable.
If interested please hit me back, I'm not
Kent Humphrey wrote:
I've made a single item work with my initial solution, which was to
have a list for each item that lists which items in the other lists
should highlight. But by the time I've made 25 lists for my 25
(current) items, that seems like a lot of redundant and duplicated
That sounds to me like you want to use events -- the items which
light up should listen to the items that trigger them. When the
triggering item gets moused over, the listening item(s) can decide
whether to react. This might just take your redundancy and put it
somewhere else, but it
What I ask myself on new projects is what parts of this can I reuse?
Can I put this behavior in a class or a component? It's more work up
front to make your classes for your daily tasks (not much more work)
but on project 2 or project 3 your work will pay off.
What's more, OOP design
Ian Thomas wrote:
We've jsut started using AS2API -
http://www.badgers-in-foil.co.uk/projects/as2api/ - which works fine for us
on Windows (but had issues on Linux, sadly, although I think that's because
our Linux box needs a good cleanup).
Perhaps you could share how you got it working? I
Ian Thomas wrote:
Hi Alan,
That one's pretty simple - we didn't even try. I too get the huge barf of
'no definition' output for the MX classes. But I didn't need to document the
MX classes, so didn't bother looking into how to do so - the output from
as2api _without_ those classes is
Chris Kennon wrote:
Hi,
If my understanding of encapsulation is misguided, please correct. In
the following code snippet, should in the interest if encapsulation,
the Good Morning/Afternoon strings be called from another function?
That depends on exactly how you interpret formatTime. The
Martin Weiser wrote:
Hello,
does these tags really work for search bots?
!-- URL's used in the movie--
!-- text used in the movie--
No way. Google is way too smart these days. White text on a white
background, meta tag text, text in comments, text anywhere a user
can't read it -- Google
I'm about to begin on a project for work where a user has the ability
to select
areas on a map by clicking and dragging his mouse over and area. When
the person is finished
they will let go of the mouse button and a nice little square will
appear on the map where they
have selected.
Just
Alan MacDougall wrote:
I'm about to begin on a project for work where a user has the ability
to select
areas on a map by clicking and dragging his mouse over and area. When
the person is finished
they will let go of the mouse button and a nice little square will
appear on the map where
I have two MTASC issues:
First, MTASC cannot compile MM's source for v2 components, because that
source itself does not comply to pure, strict AS 2.0. The workaround is
to use the -mx flag, which causes MTASC to use the precompiled .aso
objects for v2 components.
That's all well and good,
i am not able to catch this error in either the anon function or the
function delegate.
has anybody have any idea of how to handle asynchranous exception handeling
in flash?
I don't think you can do what you're planning, there; it appears that
XML.load() starts a new execution thread, which
franto wrote:
http://www.franto.com/blog2/as3-pathfinder-in-big-mazes
with as2 and as3 sources, in as3 it's 100 times faster :)
Yeah, I'm resigned to having to rework my entire application once
ActionScript 3 hits the general-purpose Flash Player level.
Unfortunately, you can never just
Weyert de Boer wrote:
Hello
I made a simple class to registers a class name and which should be
able to instantiate a instance of a registered class. For example:
TilesRepository = new ObjectRepository();
TilesRepository.registerObject( DefaultTile );
// create instance
tileInstance
of this too, if you'd like.)
Alan MacDougall
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
[EMAIL PROTECTED] wrote:
I wanted to load these cells from the library on the fly, but I get an error.
Here is the code I use:
import colorblock;
c = _root.createClassObject(colorblock, blankClip + i, (i + 1),
{colorParam:hexArray[i]});
Are you able to instantiate a new object of the
Some of this debate may be a matter of preference or perception, too.
It's very true that good code should be self-documenting, but once you
have a class more or less done, you shouldn't have to analyze its code
to figure out what its methods and their signatures are, or how it
interacts with
Anyone know if it's possible to control the framerate of a movie at runtime?
As far as I know, framerate is built into the SWF; it's a base property.
If this has changed in the last one or two versions, I haven't heard
about it. In a frame-by-frame animation, there'd be workarounds -- for
Howard Nager wrote:
Mini update - I've simplified and am loading an image in to a movieclip and
applying the distortion filter to the movieclip. Much easier...anyhow, before
applying the distortion i am creating a button in that movieclip. The problem
now is that the button visually distorts
57 matches
Mail list logo