Re: [Flashcoders] View images in local folder

2007-07-25 Thread Weldon MacDonald

Flash doesn't have access to the local file system. If teh pictures were on
a server you could do something with a PHP script to get the file names, but
on the client, not. Unless you want to get into the new Adobe Air API, but
that's a whole other ball of wax, not to mention a bit of a learning curve

On 7/25/07, Norman Cousineau [EMAIL PROTECTED] wrote:


Is it possible to use Flash to make an image browser...without an XML
file.
In other words, just view the images in any given local folder.

Regards,
Norm C
___
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@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] Backend compiled Java or scripted PHP?

2007-07-20 Thread Weldon MacDonald

Wow, this seems to be one of those topics where everyone has strong but
differing opinions,

Atila java over PHP. Just few points why:  
Nice comparative overview

 HermitIt seems to depend on what you will be using it for ultimately.
BINGO, we have a winner folks...

Ron,   Eclipse, Spring, Hibernate, AXIS and Java is a pretty nice
toolkit.
I agree wholeheartedly, but is it the most productive way to handle the
small stuff. I don't have the luxury of having server drones (apologies to
the server drones) taming the backend, so quick and dirty  is a
development paradigm for me.

 Muzak  Flash/Flex + Coldfusion + Flash/Flex Remoting.
I've seen the big increase in traffic on all things Coldfusion, but I seemed
to have missed the reason why (been under a rock). I usually try to avoid
proprietory stuff when I can and have always ignored Coldfusion for it's
limited hosting etc... I'll have to research what all the recent traffic is
about and if there's a need to revise this opinion.

Flashcoders has once again provided an interesting, informative, and
balanced overview.

What I get from it is, in general (with untold exceptions),
- professional programmers in general prefer the structure of Java. The
majority here. I've had enough formal training to appreciate this.

- PHP seems to be preferred by the home grown just get it done programmers
who are, like me, spawned by opportunities inherent on the internet.  As a
one man operation I sympathize

- the dividing line seems to be scale. (How big is the project, how much
traffic will it generate, how computationally expensive and or complex).
There are many situations that don't affect the scalability or
maintainability of a site, scripting is too useful a tool not to have
available. That being said, while more complex things can and are built with
PHP, there's a point at which the advantages of Java overcome it's
disadvantages (taming tomcat, longer development times, etc...).  The big
question is where do  you draw the line?

Weldon

Best is good. Better is best. Lisa Grunwald
___
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] Backend compiled Java or scripted PHP?

2007-07-19 Thread Weldon MacDonald

I've been using ActionScript for a while now, but my next project will
require a lot more server side work. In the past I've used PHP, but
only in a pidgin kind of way. alternatively, I have some Java skills,
though not specifically for the web. Either way I have to spend some
time developing an appropriate skill level, the question becomes,
which skills.

The times I've used PHP, it seemed straight forward enough, and from
what I've read Java is a little trickier to implement on the web
(correct?). On the other hand, PHP is a pretty specific niche whereas
Java has a much wider usefulness (correct?)

There are a lot of strong opinions out there.

Andreessen: PHP succeeding where Java isn't
http://news.com.com/2100-1012-5903187.html?tag=tb

and  in response,

How they can compare PHP with Java at all? (most people who are
praising PHP are either bad programmers or they are not programmers at
all)
http://news.com.com/5208-1012_3-0.html?forumID=1threadID=10712messageID=78718start=0

PHP is faster to develop, java is faster to run, or is that runs faster?
PHP is harder to maintain, and Java has more tools ...etc...

What's a guy to beloieve? Any opin... any more opinions?
___
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] Re: Flashcoders Digest, Vol 19, Issue 46

2006-08-16 Thread Weldon MacDonald

Does Red5 and/or electroserver support Flex2 applications? ie AS3

Weldon

Red5. http://osflash.org/red5

Red5 is a server that not only streams content to the Flash plugin, but it
can push calls and information to the Flash client! It can also receive
video/audio/data from a flash client and either save or rebroadcast that
content.

-Andy


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Weldon
MacDonald
Sent: Tuesday, August 15, 2006 2:27 PM
To: Flashcoders mailing list
Subject: [Flashcoders] WhiteBoard app

I have to do an application that requires a shareable interface, like
a smartboard. There are may options to do this in Falsh, but this app
practically begs to be written in Flex2. My problem is what do I have
to have to write it? My clients dont expect thousands or even hundreds
of users and they can't afford the full blown FDS. The free version
may be adequate, but if it's not, they don't have scalability without
paying a high price. Are there any alternatives to using FDS?
I have to talk price with these people soon and this is the only point
I don't have a handle on. I talked them into publishing to Fash 9, but
if I can't solve this issue they may want to stick to Flash 8 so I can
use AS2 alternatives.

Weldon MacDonald
___
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




--

Message: 14
Date: Tue, 15 Aug 2006 14:38:28 -0400
From: Jayson K Hanes [EMAIL PROTECTED]
Subject: RE: [Flashcoders] WhiteBoard app
To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Message-ID: [EMAIL PROTECTED]
Content-Type: text/plain;   charset=us-ascii

http://www.electro-server.com/Examples/whiteboard/whiteboard.html

20 User trial of the server is at no cost with no limitations.
___
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] WhiteBoard app

2006-08-15 Thread Weldon MacDonald

I have to do an application that requires a shareable interface, like
a smartboard. There are may options to do this in Falsh, but this app
practically begs to be written in Flex2. My problem is what do I have
to have to write it? My clients dont expect thousands or even hundreds
of users and they can't afford the full blown FDS. The free version
may be adequate, but if it's not, they don't have scalability without
paying a high price. Are there any alternatives to using FDS?
I have to talk price with these people soon and this is the only point
I don't have a handle on. I talked them into publishing to Fash 9, but
if I can't solve this issue they may want to stick to Flash 8 so I can
use AS2 alternatives.

Weldon MacDonald
___
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] Array Empowerment

2006-07-27 Thread Weldon MacDonald

That's the real source of sloppiness, Java has eliminitaed these
discussions by the simple expeditent of requiring that the conditional
resolves to a boolean, nothing wlse will do. THe real question to me
is does AS3 change this behavior?

On 7/27/06, ryanm [EMAIL PROTECTED] wrote:

 To me it has always seemed more logical to use if this.length == 0 for the
 very reason of explicitness that you stated; and thus, using the
 alternative !this.length was less enticing. I speculated (wrongly) after
 reading your post that there might be some sort of speed optimization
 inherent to checking if something is false than actually checking for a
 specific length defined explicitly in your code. I don't know why I
 thought that, and obviously I am wrong for the various reasons stated
 earlier.

Further, !this.length is very likely slower. Conditions are meant to
resolve to a boolean, but the implicit cast is to a string, which means
walking the prototype to find the property, and if it exists (!=undefined),
casting it to a string, and then recasting it to a boolean. Meanwhile,
this.length==0 resolves directly to a boolean, and, as such, should be a bit
faster. It wouldn't be a noticable difference in speed in a single
condition, but in a recursive loop where it might be evaluated thousands of
times, it could make a significant difference.

ryanm

___
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




--
Weldon MacDonald
___
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] Led into temptation with promises of preformance

2006-07-08 Thread Weldon MacDonald

I've been steadfastly ignoring all the talk about AS3 since I don't
like to publish in a flash player until it's been around for 8 to 10
months. Now though I have an app to write and all the talk about the
preformance increase has got me wondering if I don't have to make the
move to AS3. The app isn't scheduled to launch until the end of the
year, so I have time to climb the learning curve, but I'd like to know
what the feeling is on publishing AS3 to Flash 9 that early.
Does it make sense, or am I asking for a world of trouble with my
client over lack of exposure of Flash 9

Weldon MacDonald
___
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] Flash for forums

2006-06-26 Thread Weldon MacDonald

I'll have to take your word for it, I never use the things.  I've decided to
go with an existing forum, p2pbb or vbulletin, customized with a flash
header.
Thanks

On 6/26/06, Mick G [EMAIL PROTECTED] wrote:


The highly important and common feature for Forums is the ability
to  paste
HTML, perform clean and efficient searches, insert images from other
sites/URLs, embed flash animations, right-click to open links posted links
in new tabs/windows, paste code, harcore forum users even cherish their
custom footers. Most of these functions wouldn't be as effective in a
flash
front-end.

On 6/25/06, Count Schemula [EMAIL PROTECTED] wrote:

 I'm on a few vBulletin powered forums and they work very well.

 Bulletin boards are far superior to e-mail lists in almost everyway.
 I've been on e-mail lists since before there was a web, and, really,
 there is no comparison to how much more useful 100,000 threaded
 conversations are in a bulletin board compared to an e-mail list.

 On 6/24/06, Josh Santangelo [EMAIL PROTECTED] wrote:
  vBulletin's current version has many AJAXy features which enable
  interactions similar to what you describe. It's not free, but it's
  not expensive either.
 
  http://vbulletin.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@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





--
Weldon MacDonald
___
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] Flash for forums

2006-06-24 Thread Weldon MacDonald

I've never liked forums, mostly because the I find navigating around in most
forums is pretty clunky,  give me an email list every time, but, as so often
happens, the universe has decided to get a little revenge. I have a client
who wants a forum. I've just spent the morning researching forum software
and there are many good products out there, but none that give the
navigational convenience I would like. I can see a forum with a flash front
end that would be a dream to use, let'
s say, a tree of threads with subjects; hover over one and see a preview;
click and see a list of responses; click on a response and get a preview,
all in one window without a page change. Posts are written in a new window
and don't require 3 or 4 pages generations per response.
That's a little simplistic, but I hope you get the idea. What ever I use it
has to be customized to the look and feel of the site.  Has anyone seen such
a forum?  Or, a forum with documentation that would allow the relatively
easy implementation of a flash front end.

Weldon MacDonald
___
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] cake decorating app

2006-06-21 Thread Weldon MacDonald

A cake decorater is asking about a web based app for designing cakes. It's a
drawing app with a twist. He's found a desktop app in C# that he wants to
port to Java for the web. I'm trying to convince him that Java for this is
overkill and he should Actionscript. Am I right, or would it be relatively
easy to port C# to Java. Are there any examples of this type of drawing app
he could look over?

Weldon MacDonald
___
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] Simple Eclipse setup question

2006-06-08 Thread Weldon MacDonald

I probably got it from you, lol. I've read things by so many people
it's hard to keep track!

On 6/8/06, erixtekila [EMAIL PROTECTED] wrote:

 As for the ctrl+Enter, I managed to set this up in ANT. My build
 file has an exec tag to open the stand alone player, or you could use
 your default browser, and I set up the hotkey in
 WindowprefGeneralKey and in the dialog...  set the Catagory to
 Run/Debug and the Name to Run Ant Build, then set the keystroke and
 your good to go

I use exactly the same.
Souvenirs nostalgiques…

Cheers.
---
erixtekila
http://blog.v-i-a.net/
___
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




--
Weldon MacDonald
___
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] Simple Eclipse setup question

2006-06-08 Thread Weldon MacDonald

Welcome to open source. I'm in the same process and it's a bit of a
struggle. If you find a step by step anything, please send it along to
me. As for the ctrl+Enter, I managed to set this up in ANT. My build
file has an exec tag to open the stand alone player, or you could use
your default browser, and I set up the hotkey in
WindowprefGeneralKey and in the dialog...  set the Catagory to
Run/Debug and the Name to Run Ant Build, then set the keystroke and
your good to go

I don't know of a way to direct it to the swfviewer in ASDT.

the target in Ant is

target name=display description=displays swf in flashplayer
exec executable=${flashplayer}
spawn=true
arg value=${build.dir}/${targetswf}/
/exec
/target
Where ${flashplayer} is the path to the FlashPlayer of  your chioce.
${build.dir}/${targetswf} are the path adn file name of the swf.

Good Luck.

On 6/8/06, iestyn lloyd [EMAIL PROTECTED] wrote:

Hey List,

I've been using SEPY + Flash for a long time, and it's extremely
useful to be able to press CTRL+Enter to export the movie.

I've now installed Eclipse and ASDT, and it would be great if I can do
this..is it possible? I've been having a look around, and i dont see
an easy way of doing it..
Can someone offer me advice on this?
In fact, are there any step-by-step guides to setting up Eclipse to
work with AS2?  I wont be using MTASC yet[1], just Flash for the
moment! :)

Cheers,

Iestyn

[1] I will soon, as it looks like it's the way forward..
___
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




--
Weldon MacDonald
___
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] XML Parsing

2006-06-05 Thread Weldon MacDonald

If your data is that consistent and all you need is to transfer it to
arrays, then why do you need xpath, you could write your own parser,
using while loops, to do this in very little time.
I'm not an experrt, but it seems to me that xpath is more useful for
dynamic access to the xml. Is that not correct?
If I am correct, an interesting question is; what is more efficient,
transferring to arrays and using the arrays, or dynamically accessing
the xml directly?

On 6/5/06, Sajid Saiyed [EMAIL PROTECTED] wrote:

Hi,
I have an XML like this:

root
totalLayers
number5/number
/totalLayers
LayerOne
asset
 namesomename0.bmp/name
width20/width
height10/height
xPos50/xPos
yPos30/yPos
/asset
asset
 namesomename1.bmp/name
width20/width
height10/height
xPos50/xPos
yPos30/yPos
/asset
/LayerOne
Layertwo
asset
 namesomename2.bmp/name
width20/width
height10/height
xPos50/xPos
yPos30/yPos
/asset
/LayerTwo
/root

I want to use XPATH or something similar to create dynamic
arrays/string and store values respectivele like this:

String:
totalLayers = 5;

LayerOne and LayerTwo will be a multidimentional array

LayerOne[[asset[name,width,height,xpos,ypos]][asset[name,width,height,xpos,ypos]]...]
LayerTwo[[asset[name,width,height,xpos,ypos]][asset[name,width,height,xpos,ypos]]...]
etc...

Any hint or suggestion...?
___
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




--
Weldon MacDonald
___
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] Flash/Eclipse Workflow

2006-06-04 Thread Weldon MacDonald

If I'm understandung this...
You add the IDE generated swf (IDE.swf) to the project. You then
create an external class that has a 'main' entry point  and it loads
the IDE.swf. (with a preloader of course).
Do I have this right? Sounds good, though the test will be can I
impliment it myself. You could also break IDE.swf into several
library1.swf, library2.swf and load them seperately, to spread out the
load, couldn't you?

this sounds similar to the Natural Entry Point method. Do you
instanciate the entry point class? If it extends MovieClip, then it
could also serve as _root, couldn't it? I'm searching for examples as
we speak...write?... Im close, thankis for the help

On 6/3/06, Scott Hyndman [EMAIL PROTECTED] wrote:

What I usually do is load in the assets swf through the MTASC
generated swf and use it as the root in the movieclip hierarchy. By
this I mean all movieclips created by my MTASC generated swf are
descendants of the asset swf. By doing so you can access all symbols
in the asset swf through attachMovieClip and you don't have to mess
around with injection. An added benefit is that you can display a
preloader on the asset swf which is quite likely large.

Hope that helps,
Scott

On 6/3/06, Weldon MacDonald [EMAIL PROTECTED] wrote:
 Ok, I installed Eclipse, spent a better part of a day downloading
 plugins and configuring everything. I'm using Ant tasks to compile
 with MTASC and send it to the standalone player.
 I don't see the need for swfmill, since I own Flash. My plan was to
 create vector graphics and any timeline stuff in flash (mostly done by
 my wife) and then move to Eclipse to write the code.
 But now I'm not at all sure how to structure a project. I read about
 several methods, but am at a loss as to how to proceed. What's best
 practise?
 Can I use one swf as a symbol library and compile it with the class
 files and a 'main' entrypoint? Do I inject all the code into the
 library swf?
 I've been experimenting with a class that's tied to a symbol in an
 .fla and would like to switch over to the new workflow, if I can
 figure out what that is. The symbol is a movieclip with nested
 movieclips. The class extends MovieClip and uses an init function
 rather than a constructor. The code I've been using to test is in the
 .fla  but the class file is external. How can I restructure this to
 include Eclipse in the workflow?


 Weldon MacDonald
 ___
 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@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




--
Weldon MacDonald
___
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] Flash/Eclipse Workflow

2006-06-04 Thread Weldon MacDonald

thanks, there's nothing left but to actaiully try it.

On 6/4/06, Scott Hyndman [EMAIL PROTECTED] wrote:

 If I'm understandung this...
 You add the IDE generated swf (IDE.swf) to the project. You then
 create an external class that has a 'main' entry point  and it loads
 the IDE.swf. (with a preloader of course).

Correct

 Do I have this right? Sounds good, though the test will be can I
 impliment it myself. You could also break IDE.swf into several
 library1.swf, library2.swf and load them seperately, to spread out the
 load, couldn't you?

No, unfortunately not. Assets are only available to use from the
closest loaded parent. Let me explain with a little picture.

shell.swf (where all your classes most likely reside)
|
|-assets.swf (loaded by shell.swf)
   |
   |---movieclips that can access assets.swf library
   |
   |---assets2.swf
|
|movieclips that can access
assets2.swf (but not assets.swf)

It's limited by this parent cut-off idea, but it is still very useful
for getting IDE generated assets into my MTASC generated projects.

You can split this up a bit further even by including your classes in
a separate swf. The limitations shown above do not apply to loaded
classes. As soon as they are loaded, they are available.

Hope this helps,
Scott

 this sounds similar to the Natural Entry Point method. Do you
 instanciate the entry point class? If it extends MovieClip, then it
 could also serve as _root, couldn't it? I'm searching for examples as
 we speak...write?... Im close, thankis for the help

 On 6/3/06, Scott Hyndman [EMAIL PROTECTED] wrote:
  What I usually do is load in the assets swf through the MTASC
  generated swf and use it as the root in the movieclip hierarchy. By
  this I mean all movieclips created by my MTASC generated swf are
  descendants of the asset swf. By doing so you can access all symbols
  in the asset swf through attachMovieClip and you don't have to mess
  around with injection. An added benefit is that you can display a
  preloader on the asset swf which is quite likely large.
 
  Hope that helps,
  Scott
 
  On 6/3/06, Weldon MacDonald [EMAIL PROTECTED] wrote:
   Ok, I installed Eclipse, spent a better part of a day downloading
   plugins and configuring everything. I'm using Ant tasks to compile
   with MTASC and send it to the standalone player.
   I don't see the need for swfmill, since I own Flash. My plan was to
   create vector graphics and any timeline stuff in flash (mostly done by
   my wife) and then move to Eclipse to write the code.
   But now I'm not at all sure how to structure a project. I read about
   several methods, but am at a loss as to how to proceed. What's best
   practise?
   Can I use one swf as a symbol library and compile it with the class
   files and a 'main' entrypoint? Do I inject all the code into the
   library swf?
   I've been experimenting with a class that's tied to a symbol in an
   .fla and would like to switch over to the new workflow, if I can
   figure out what that is. The symbol is a movieclip with nested
   movieclips. The class extends MovieClip and uses an init function
   rather than a constructor. The code I've been using to test is in the
   .fla  but the class file is external. How can I restructure this to
   include Eclipse in the workflow?
  
  
   Weldon MacDonald
   ___
   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@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
 


 --
 Weldon MacDonald
 ___
 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@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




--
Weldon MacDonald
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search

[Flashcoders] Flash/Eclipse Workflow

2006-06-03 Thread Weldon MacDonald

Ok, I installed Eclipse, spent a better part of a day downloading
plugins and configuring everything. I'm using Ant tasks to compile
with MTASC and send it to the standalone player.
I don't see the need for swfmill, since I own Flash. My plan was to
create vector graphics and any timeline stuff in flash (mostly done by
my wife) and then move to Eclipse to write the code.
But now I'm not at all sure how to structure a project. I read about
several methods, but am at a loss as to how to proceed. What's best
practise?
Can I use one swf as a symbol library and compile it with the class
files and a 'main' entrypoint? Do I inject all the code into the
library swf?
I've been experimenting with a class that's tied to a symbol in an
.fla and would like to switch over to the new workflow, if I can
figure out what that is. The symbol is a movieclip with nested
movieclips. The class extends MovieClip and uses an init function
rather than a constructor. The code I've been using to test is in the
.fla  but the class file is external. How can I restructure this to
include Eclipse in the workflow?


Weldon MacDonald
___
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] Re: Biased Random Particle Distribution

2006-05-27 Thread Weldon MacDonald

from a practical standpoint, something like this should work, it's
difficult to be sure at 5:30 in the AM.

get a random number from 1 - 10
var ranNum:Number = random(10)+1;
now if ranNum is less than 4 pick a random position within x of the origin
if ranNum is 6-8 select a random point within x + delta x
If ranNum is 9 - 10 select a random point from the entire range.
By playing with the ranges I used here you will get more or less
intensity near the origin. If this is too coarse, make ranNum a bigger
range and add more regions.
You could set this up in one tidy finction, it's less interesting than
the math, but it should get the job done.

On 5/27/06, clark slater [EMAIL PROTECTED] wrote:

Hi Ron,

Thanks for jumping into this thread amongst the tumbleweeds. Yes, I suspect
something logarithmic could work but don't know where to start. I am trying
to distribute 1000 particles randomly in a rectangular distribution area,
with a bias towards one side of the rectangle.

Clark


On 5/26/06, Ron Wheeler [EMAIL PROTECTED] wrote:

 Would a formula based on logarithms give you what you want as well?
 You were not very specific about what you wanted the distribution to
 look like.

 Ron
 clark slater wrote:
  Here I go answering my own question.
 
  To make it more dense toward the origin, use {x,y} = {random[]^2,
  random[]^2}--squaring the independently generated numbers
  (random[]*random[]
  won't work). The result is a distribution with a sharp cusp at the
  origin--the probability is a maximum there, and has a discontinuous
  derivative. You can use higher powers for narrower (and sharper)
  distributions.
 
  Damn useful I say!
  ___
  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@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@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




--
Weldon MacDonald
___
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] Problems with Tween Class

2006-05-25 Thread Weldon MacDonald

It's early in the morning, but it seems to me your not finishing the
tween in your test. Try calling the stop() method before you unload.
There may be a call to setInterval that doesn't get cleared if you
don't.
That begs the question of why  you want to unload and reload it. there
must be a way for you to save the extra load. What about setting
visible to false or moving it off stage?

On 5/25/06, Nik Derewianka [EMAIL PROTECTED] wrote:

Hi all,

Basically i attachMovie my character (which is an AS2.0 class extended
MovieClip) to _root, then move it back and forwards across the screen
using the Tween class, unloadMovie my character, go to a different
frame, attachMovie my character back again, but this time it seems as
though there are two or more Tween objects trying to control my
character.  If i reattachMovie using a different instance name, then
it will work fine.

So how do i completely unload my MC and my Tween so that there are no
references hanging around ??  How can i find out how many references
there are for a given object (similar to the ref count in lingo
objects in Director) ??  And is this only happening because of AS 2.0
?

Heres my stripped down test movie:

mc with ID of idRedbelly1, AS2.0 class of code.Crawlie2 which contains:
--
import mx.transitions.Tween;
import mx.transitions.easing.*;

class code.Crawlie2 extends MovieClip {

private var Walker:Tween;

public function StartWalking(){
Walker = new Tween(this, _x,None.easeNone,this._x,this._x + 
200,1,true);
Walker.onMotionFinished = function(){this.yoyo();};
};
};
--

frame 1, symbol named btn on the stage, the following as a frame script:

--
btn.onPress = function() {
   _root.test.removeMovieClip();
_root.test.unloadMovie();
_root.gotoAndPlay(part2);
}

_root.attachMovie(idRedbelly1,test,_root.getNextHighestDepth(),{_x:50,_y:50});
_root.test.StartWalking();
stop();
--

frame 10 with marker name of part2, following frame script:

--
_root.attachMovie(idRedbelly1,test,_root.getNextHighestDepth(),{_x:50,_y:25});
_root.test.StartWalking();
stop();
--


I also tried a version that set Walker to null before i unloaded the
MC but that didn't work either.

Any help is greatly appreciated,
--
:: Nik Derewianka ::
:: freelance director programmer ::
___
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




--
Weldon MacDonald
___
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] OOP 101: Is import really necessary?

2006-05-25 Thread Weldon MacDonald

The import statements tell the compiler where to find the classes your
going to use, it compiles into the byte code only the classes you use.
You could also do it by giving the full package.class of the class
too. Import statements aren't strictly necessary, but they save a lot
of typing if your using the library a lot.

On 5/25/06, Derek Vadneau [EMAIL PROTECTED] wrote:

The import statement embeds, but so does this:
var a:mx.controls.Button;

import also allows you to use a shortcut as has been mentioned already.

From the docs:
Lets you access classes without specifying their fully qualified names.
..
You must issue the import statement before you try to access the imported
class without fully specifying its name.

If you import a class but don't use it in your script, the class isn't
exported as part of the SWF file. This means you can import large packages
without being concerned about the size of the SWF file; the bytecode
associated with a class is included in a SWF file only if that class is
actually used.

If you import but don't use it it's not included ... however, in practice
you can definitely see that the SWF file size has changed.

I took a blank FLA and published for a SWF size of 43 bytes.


I then used this code:

import mx.controls.Button;
import mx.controls.List;
import mx.controls.Tree;
import mx.controls.DataGrid;
import mx.containers.Accordion;

File size: 42.5 KB


I then used this code:

var b:mx.controls.Button;
var l:mx.controls.List;
var t:mx.controls.Tree;
var d:mx.controls.DataGrid;
var a:mx.containers.Accordion;

FileSize: 48.3 KB


I then used this code:

import mx.controls.Button;
import mx.controls.List;
import mx.controls.Tree;
import mx.controls.DataGrid;
import mx.containers.Accordion;

var b:Button;
var l:List;
var t:Tree;
var d:DataGrid;
var a:Accordion;

FileSize: 48.3 KB

So the classes seem to be included in the SWF with just the import
statements. Of course there is no difference if you import and use them
compared to using them with explicit reference to the classes.

Now the docs say that import by itself doesn't include the classes, but I
used this code:

import mx.controls.Button;
import mx.controls.List;
import mx.controls.Tree;
import mx.controls.DataGrid;
import mx.containers.Accordion;

trace(_global['mx']['controls']['Button']);

The output panel displays [type Function] telling me that the class was
indeed included. The compiler doesn't understand the [] notation as a
reference to the class during compile-time, so I don't think that's why it
worked. I think the classes are indeed included. However, someone could
prove me wrong.

Incidentally, the file size was 42.5 KB ... so, trim the fat and use []
notation!


Derek Vadneau

- Original Message -
From: Merrill, Jason [EMAIL PROTECTED]
To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Thursday, May 25, 2006 1:24 PM
Subject: RE: [Flashcoders] OOP 101: Is import really necessary?


The 'import' statement doesn't actually embed a class into the .swf.
All it does is tell the compiler that when you type (for example)
MyClass, you are actually referring to com.fred.MyClass.

Err...that has not been my understanding at all.  If that is the case,
then why do you NOT need to include your class files on the server with
the .swf?  Since reality is you don't, all that code has to be in the
swf upon compiling, otherwise, the .swf wouldn't know what to do with

Myvar:MyCoolClass = new MyCoolClass();

If it's not included with the .swf, how would the .swf know what
MyCoolClass is otherwise?


Jason Merrill
Bank of America
Learning Technology Solutions


___
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




--
Weldon MacDonald
___
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] HashMap?

2006-05-17 Thread Weldon MacDonald

If memory serves...  There's a HashMap class in Java that hides the
implimentation. You can declare it with or without a size (I don't
rememv[ber the default) and optionally it will accept a load value
which is the percentage of capacity at which to increase the size of
the map. Growing the array, increasing the hash, etc... is all handled
by the class.
Since you probably have an installation you can find the source in the
utils package, I think.

On 5/17/06, Ron Wheeler [EMAIL PROTECTED] wrote:



Bernard Poulin wrote:
 Funny, I was actually thinking of an implementation which would use a
 Java-style String objects. In java, all string objects have an int hash
 data member (computed the first time it is needed).

 In that scenario, only a portion of the hash value is used to make the
 hash
 lookup. The complete hash stays around since it is part of the String
 object
 and so can still be used to quickly distinguish strings.  Also when
 rehashing you do not need to really compute new hashes - you just
 need
 to re-distribute them based on more bits of the complete hash.

That only works if the hash primary table has a length that is a power
of 2. If your original has maps from 1-5,000 and your increase the size
of the primary storage area to 15,000, you will need more than more
bits, you will need a completely different set of hash values.
Not sure what Java does with its hash. Do you have to declare the
maximum array size when you declare the array?

Ron
 And yes, this
 is still heavier than re-balancing a tree.

 regards,
 B.


 Binary searches may involves a lot more string comparison. In a binary
  search comparing the string hash value is of no use to know if the
  value
  is greater or lower (to decide for the next search direction). In
  hashmaps, the lookup in the chain after the hash jump can, most
 of the
  time, skip a string entry without even looking at the characters by
  comparing the 32bit integer hashes.
 String hashes are only useful for looking up a specific value. It is
 unlikely that the hashes are even stored since once you store the
 key/value you no longer have any need for the hash since the position in
 the main table is known and you can follow the links in the overflow
 back to the main table(usually).

 If you are hashed into the overflow, you have to examine each key since
 the hashes are identical for everyone in the list (otherwise they would
 not be in the list - they would be in another list of collided hashes).

 ___
 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@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




--
Weldon MacDonald
___
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] sprouts data structure

2006-05-16 Thread Weldon MacDonald

I have been in contact with the authoir of Aunt beast. While he isn't
offering source code, he has given methe resources he maintains are
everything needed to  write the game.

A paper discussing a previous ly written computer opponent
http://citeseer.ist.psu.edu/applegate91computer.html
and a paper on a linear programming approach to graph printing
http://i11www.ira.uka.de/research/geonet/publications/pdf/n-admm-05d.pdf

Unfortunately, I won't get to reading these for a couple of weeks. The
end of the semester crush is upon me.

On 5/15/06, Bernard Poulin [EMAIL PROTECTED] wrote:

more googling...
This one seems to link to a word document with some high-level explanation.
http://www.pa.uky.edu/~sorokin/stuff/cs650/sprout/sprout.html

B.

2006/5/15, Bernard Poulin [EMAIL PROTECTED]:

  http://mathforum.org/kb/message.jspa?messageID=1091009tstart=0

 http://www.pa.uky.edu/~sorokin/stuff/cs650/sprout/SPROUT.CC

 Somebody did a program called auntbeast which seems to be quite good. I
 can't find a copy of it nor their source. Might be worth sending an email to
 them.

  http://www.geocities.com/chessdp/   *World* *Game* *Of* *Sprouts* *
 Association*


 2006/5/11, Weldon MacDonald [EMAIL PROTECTED]:

  I have a request for a game called sprouts. The game starts with a few
  randomly distributed dots. There is one move and 2 restrictions.
  Move:   draw a line for a dot to itself (a loop) or to another dot.
  Any line drawn has a new dot on it.
  Restriction 1: no more than 3 lines from any dot.
  Restriction 2: no lines can cross.
 
  Simple game, but the data structure to keep track of the game and in
  particular to handle restriction 2 is a bear. How do you tell when a
  dot has been encircled by a line?
 
  The game is, of course based on graph theory, and you can represent a
  graph in several ways, but how to determine that it remains planar?
 
  I haen't begun to think about the visual part of this, if I don't have
  a reasonable data structure I can't teach a computer to play the game.
 
  Any ideas? Hints? Wildly improbable ideas?
 
  --
  Weldon MacDonald
  ___
  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@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




--
Weldon MacDonald
___
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: FW: [Flashcoders] sprouts data structure

2006-05-13 Thread Weldon MacDonald

Yes, and the idea isn't difficult, but can be computationally
expensive. Generate a tree of possible moves and number them
recursively, starting with 0 at the leaves of the tree (note the
leaves are winning positions as there are no further moves). Then work
back up the tree  numbering each level with the lowest interger, which
is not the number of the next lower level. This means winning
positions are 0's, the level above is non-0, the level above that must
be 0 again  Once you have all the positions labeled, the winning
strategy is simple. Move to a 0 position. Once on a 0 position you can
leap frog through the game from 0 position to 0 position until you
win. this is a class of games called Impersonal, 2 person games, or
I2p.
Mathematicians love these things. Since this recursive numbering grows
by a power function, on the number of possible moves, it's often only
feasible to run smaller, simplier cases, and then try to find winning
strategies that can be extended to more general cases. The goal is of
course a proof which may teach him something about graph theory.


On 5/13/06, Bernard Poulin [EMAIL PROTECTED] wrote:

 oh my apologies, I really did not realize that you had to implement an
actual player and thus do all the AI. Actually had no clue about what this
game really looked like. I understand it a bit better now: The game plays
with 2 players, lines are not straight, new dots can be placed anywhere on
the line, one wins when its opponent cannot do a move.

Interestingly enough, the outcome is somehow deterministic: from Wikipedia:
http://en.wikipedia.org/wiki/Sprouts_(game)

[]By enumerating all possible moves, one can show that the first player is
guaranteed a win in games involving three, four, or five spots. The second
player can always win a game started with one, two, or six spots.

At Bell Labs http://en.wikipedia.org/wiki/Bell_Labs in
1990http://en.wikipedia.org/wiki/1990,
David 
Applegatehttp://en.wikipedia.org/w/index.php?title=David_Applegateaction=edit,
Guy 
Jacobsonhttp://en.wikipedia.org/w/index.php?title=Guy_Jacobsonaction=edit,
and Daniel Sleator http://en.wikipedia.org/wiki/Daniel_Sleator used a lot
of computer http://en.wikipedia.org/wiki/Computer power to push the
analysis out to eleven spots. They found that the first player has a winning
strategy when the number of spots divided by six leaves a remainder of
three, four, or five, and conjectured that this pattern continues beyond
eleven spots.[]
Regards,
B.

2006/5/12, Weldon MacDonald [EMAIL PROTECTED]:

 The reqiurement is that the software be able to play the game, so I
 need a data structure to store the game position for analysis. The
 intersection check is moot until I can store the current state of the
 game, update it, and analyze the potential moves.
 If moves are made that create a cycle, then the possibility of a
 vertex, or even a subgraph, being contained by that cycle exists,
 which removes the possibility of edges to a vertex outside the cycle,
 but not to the vertexes in the cycle. That would have to be
 incorperated into the data structure.
 I think the adjacency list might store the position, but then the AI
 for the game will be very tough to do.
 As for the intersection check this will work to prevent an illegal
 move, but the tougher part will be making the computer move if the
 best move is a line that loops around other vertices. Or maybe I
 should forget programming and try my hand at cartooning!

 On 5/12/06, Bernard Poulin [EMAIL PROTECTED] wrote:
  (I am re-sending this message - somehow, I got a disk full error
 message
  from the flashcoders server)
  --
 
  Not sure what you mean by:   How do you tell when a dot has been
 encircled
  by a line?  I do not understand why we need to keep track of
 cycles?  What
  is the relation with your game constraints?  I am assuming these are
  straight lines, right?  ...or can they be of any shape?
 
  Essentially what you (seem to) want is simply checking if any line
 crosses
  when the user interacts with a dot or a line. In other words, block the
 user
  from drawing a line that will cross another one.  Just for that, you do
 not
  need to keep track of all the possibilities in advance...
 
  A straight array of dots and lines should be enough for this. ...or I
 must
  be missing something.
 
  I know that doing an intersection check on a complete graph can be a
 lengthy
  task but:
 
  Since this an interactive, human-driven game - you can reduce the
  verification processing by just checking one move at a time. The
 processing
  time will be at least linear (e.g. not exponential). So it should not be
 too
  too bad - especially if the number of segments should fit on a screen in
 a
  human-readable form ( 200 ?).
 
  my 0,02$
  B.
 
 
  2006/5/12, Weldon MacDonald [EMAIL PROTECTED]:
  
   My first thought was an adjacency list with something to indicate
   forbidden edges (for a dot  inside a cycle), so it might help. The
   problem isn't

[Flashcoders] Fwd: sprouts data structure

2006-05-13 Thread Weldon MacDonald

Good news, I just found some code on the U of Utah site. I';ts in
java, but it should allow me work out my own implimentation in action
script

-- Forwarded message --
From: Weldon MacDonald [EMAIL PROTECTED]
Date: May 11, 2006 8:48 AM
Subject: sprouts data structure
To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com


I have a request for a game called sprouts. The game starts with a few
randomly distributed dots. There is one move and 2 restrictions.
Move:   draw a line for a dot to itself (a loop) or to another dot.
Any line drawn has a new dot on it.
Restriction 1: no more than 3 lines from any dot.
Restriction 2: no lines can cross.

Simple game, but the data structure to keep track of the game and in
particular to handle restriction 2 is a bear. How do you tell when a
dot has been encircled by a line?

The game is, of course based on graph theory, and you can represent a
graph in several ways, but how to determine that it remains planar?

I haen't begun to think about the visual part of this, if I don't have
a reasonable data structure I can't teach a computer to play the game.

Any ideas? Hints? Wildly improbable ideas?

--
Weldon MacDonald


--
Weldon MacDonald
___
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] Fwd: sprouts data structure

2006-05-13 Thread Weldon MacDonald

unfortunately he only has the byte code for download. I'm trying a few
sources for some clue

On 5/13/06, David Rorex [EMAIL PROTECTED] wrote:

Do you mean this site? http://www.math.utah.edu/~alfeld/Sprouts/
It appears to not have any AI, however it does appear to check the rules, so
it may be a good starting point.

This is an interesting topic to me, please be sure to keep us updated if you
have any success!

-David R

On 5/13/06, Weldon MacDonald [EMAIL PROTECTED] wrote:

 Good news, I just found some code on the U of Utah site. I';ts in
 java, but it should allow me work out my own implimentation in action
 script

 -- Forwarded message --
 From: Weldon MacDonald [EMAIL PROTECTED]
 Date: May 11, 2006 8:48 AM
 Subject: sprouts data structure
 To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com


 I have a request for a game called sprouts. The game starts with a few
 randomly distributed dots. There is one move and 2 restrictions.
 Move:   draw a line for a dot to itself (a loop) or to another dot.
 Any line drawn has a new dot on it.
 Restriction 1: no more than 3 lines from any dot.
 Restriction 2: no lines can cross.

 Simple game, but the data structure to keep track of the game and in
 particular to handle restriction 2 is a bear. How do you tell when a
 dot has been encircled by a line?

 The game is, of course based on graph theory, and you can represent a
 graph in several ways, but how to determine that it remains planar?

 I haen't begun to think about the visual part of this, if I don't have
 a reasonable data structure I can't teach a computer to play the game.

 Any ideas? Hints? Wildly improbable ideas?

 --
 Weldon MacDonald


 --
 Weldon MacDonald
 ___
 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@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




--
Weldon MacDonald
___
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: FW: [Flashcoders] sprouts data structure

2006-05-12 Thread Weldon MacDonald

My first thought was an adjacency list with something to indicate
forbidden edges (for a dot  inside a cycle), so it might help. The
problem isn't that simple though, as more and more moves are made
whose in what cycle and can make waht move is a good deal less than
clear.

On 5/12/06, André Goliath [EMAIL PROTECTED] wrote:

FWIW if have written some AS2 classes some time ago that implement a graph
by using adjacenty lists.
If it would help you let me know

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Weldon
MacDonald
Sent: Thursday, May 11, 2006 2:49 PM
To: Flashcoders mailing list
Subject: [Flashcoders] sprouts data structure

I have a request for a game called sprouts. The game starts with a few
randomly distributed dots. There is one move and 2 restrictions.
Move:   draw a line for a dot to itself (a loop) or to another dot.
Any line drawn has a new dot on it.
Restriction 1: no more than 3 lines from any dot.
Restriction 2: no lines can cross.

Simple game, but the data structure to keep track of the game and in
particular to handle restriction 2 is a bear. How do you tell when a
dot has been encircled by a line?

The game is, of course based on graph theory, and you can represent a
graph in several ways, but how to determine that it remains planar?

I haen't begun to think about the visual part of this, if I don't have
a reasonable data structure I can't teach a computer to play the game.

Any ideas? Hints? Wildly improbable ideas?

--
Weldon MacDonald
___
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@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




--
Weldon MacDonald
___
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: FW: [Flashcoders] sprouts data structure

2006-05-12 Thread Weldon MacDonald

The reqiurement is that the software be able to play the game, so I
need a data structure to store the game position for analysis. The
intersection check is moot until I can store the current state of the
game, update it, and analyze the potential moves.
If moves are made that create a cycle, then the possibility of a
vertex, or even a subgraph, being contained by that cycle exists,
which removes the possibility of edges to a vertex outside the cycle,
but not to the vertexes in the cycle. That would have to be
incorperated into the data structure.
I think the adjacency list might store the position, but then the AI
for the game will be very tough to do.
As for the intersection check this will work to prevent an illegal
move, but the tougher part will be making the computer move if the
best move is a line that loops around other vertices. Or maybe I
should forget programming and try my hand at cartooning!

On 5/12/06, Bernard Poulin [EMAIL PROTECTED] wrote:

(I am re-sending this message - somehow, I got a disk full error message
from the flashcoders server)
--

Not sure what you mean by:   How do you tell when a dot has been encircled
by a line?  I do not understand why we need to keep track of cycles?  What
is the relation with your game constraints?  I am assuming these are
straight lines, right?  ...or can they be of any shape?

Essentially what you (seem to) want is simply checking if any line crosses
when the user interacts with a dot or a line. In other words, block the user
from drawing a line that will cross another one.  Just for that, you do not
need to keep track of all the possibilities in advance...

A straight array of dots and lines should be enough for this. ...or I must
be missing something.

I know that doing an intersection check on a complete graph can be a lengthy
task but:

Since this an interactive, human-driven game - you can reduce the
verification processing by just checking one move at a time. The processing
time will be at least linear (e.g. not exponential). So it should not be too
too bad - especially if the number of segments should fit on a screen in a
human-readable form ( 200 ?).

my 0,02$
B.


2006/5/12, Weldon MacDonald [EMAIL PROTECTED]:

 My first thought was an adjacency list with something to indicate
 forbidden edges (for a dot  inside a cycle), so it might help. The
 problem isn't that simple though, as more and more moves are made
 whose in what cycle and can make waht move is a good deal less than
 clear.

 On 5/12/06, André Goliath [EMAIL PROTECTED] wrote:
  FWIW if have written some AS2 classes some time ago that implement a
 graph
  by using adjacenty lists.
  If it would help you let me know
 
  -Original Message-
  From: [EMAIL PROTECTED]
  [mailto:[EMAIL PROTECTED] On Behalf Of Weldon
  MacDonald
  Sent: Thursday, May 11, 2006 2:49 PM
  To: Flashcoders mailing list
  Subject: [Flashcoders] sprouts data structure
 
  I have a request for a game called sprouts. The game starts with a few
  randomly distributed dots. There is one move and 2 restrictions.
  Move:   draw a line for a dot to itself (a loop) or to another dot.
  Any line drawn has a new dot on it.
  Restriction 1: no more than 3 lines from any dot.
  Restriction 2: no lines can cross.
 
  Simple game, but the data structure to keep track of the game and in
  particular to handle restriction 2 is a bear. How do you tell when a
  dot has been encircled by a line?
 
  The game is, of course based on graph theory, and you can represent a
  graph in several ways, but how to determine that it remains planar?
 
  I haen't begun to think about the visual part of this, if I don't have
  a reasonable data structure I can't teach a computer to play the game.
 
  Any ideas? Hints? Wildly improbable ideas?
 
  --
  Weldon MacDonald
  ___
  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@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
 


 --
 Weldon MacDonald
 ___
 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@chattyfig.figleaf.com
To change your

[Flashcoders] sprouts data structure

2006-05-11 Thread Weldon MacDonald

I have a request for a game called sprouts. The game starts with a few
randomly distributed dots. There is one move and 2 restrictions.
Move:   draw a line for a dot to itself (a loop) or to another dot.
Any line drawn has a new dot on it.
Restriction 1: no more than 3 lines from any dot.
Restriction 2: no lines can cross.

Simple game, but the data structure to keep track of the game and in
particular to handle restriction 2 is a bear. How do you tell when a
dot has been encircled by a line?

The game is, of course based on graph theory, and you can represent a
graph in several ways, but how to determine that it remains planar?

I haen't begun to think about the visual part of this, if I don't have
a reasonable data structure I can't teach a computer to play the game.

Any ideas? Hints? Wildly improbable ideas?

--
Weldon MacDonald
___
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] Talking to Flash from JavaScript

2006-04-17 Thread Weldon MacDonald
works fine for me, in FF 1.5

Weldon MacDonald
___
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] Active X and Microsoft IE ...

2006-04-11 Thread Weldon MacDonald
Does anyone know how long it takes for this kind of update to filter
through? I, for instance NEVER accept anything from Microsoft on the
first pass. Do I have to impliment several alternatives? What happens
to a current browser if you make the switch?
Weldon
On 4/10/06, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
 |-+-
 | |   John Dowdell  |
___
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] createEmptyMovieClip path

2006-04-08 Thread Weldon MacDonald
Ahhh the programmers life for me... :)

On 4/8/06, Boon Chew [EMAIL PROTECTED] wrote:
 Does the code I attached work for you?  Or you can send me what you got, I 
 can have a look.  It's Friday evening after all, and I am playing with code 
 anyways. :)

 - boon

 hbruyere [EMAIL PROTECTED] wrote: Ok

 I mc instance on the stage (scene) is correctly named.

 I'm compiling the movie in Flash7 AS2.0 .. but I just tried in Flash8 AS2.0
 and this is still not working.

 Hum... what's going on. I never had this king of problem before.
 I'm going to check everything... but it doesn't make sense...
 I'm sure that I'm going to be mad at myself when I'm going to solve this.

 I will let you know.

 Thanks again, in the meantime if you any other idea...

 Hugues.

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On Behalf Of Boon Chew
 Sent: Saturday, April 08, 2006 12:17 AM
 To: Flashcoders mailing list
 Subject: RE: [Flashcoders] createEmptyMovieClip path

 Did a quick test, works fine.  Maybe compare the solution and figure out
 where your problem is?

 (I have an empty movieclip instance on stage called mcEmpty, did you name
 your movie instance in your Properties window?)

 Below code tested on Flash 8:

 var url = [ http://www.adobe.com/imageshome/flash_icon3.jpg;,
http://www.adobe.com/imageshome/pdfprintengine_icon.gif; ];

 for (var i = 0; i  url.length; i++)
 {
 // you can just create one MovieClipLoader to load all clips, but this
 is ok too
 var mcLoader:MovieClipLoader = new MovieClipLoader();

 var mcHolder = mcEmpty.createEmptyMovieClip(mcHolder + i,
 mcEmpty.getNextHighestDepth());
 mcHolder._x = 40 * i;
 mcLoader.loadClip(url[i], mcHolder);
 }

 hbruyere  wrote: No didn't solve my problem.
 But thanks.

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On Behalf Of Boon Chew
 Sent: Friday, April 07, 2006 11:38 PM
 To: Flashcoders mailing list
 Subject: Re: [Flashcoders] createEmptyMovieClip path


 At a glance, I caught at least one problem, not sure if they are others that
 could cause your problem.


 var NewMC_mc:MovieClip =
 ContentContainer_mc.createEmptyMovieClip(container+i,
 getNextHighestDepth());
 You need to call getNextHighestDepth() on your ContentContainer_mc, like so:

 var NewMC_mc:MovieClip =
 ContentContainer_mc.createEmptyMovieClip(container+i,
 ContentContainer_mc.getNextHighestDepth());

 - boon

  hbruyere  wrote: Hi,



 I don't understand what I get when running this:



 
 



 for (var i = 0; i  NumPages_v; i ++)

 {

 var NewMC_mc:MovieClip =
 ContentContainer_mc.createEmptyMovieClip(container+i,
 getNextHighestDepth());

 NewMC_mc._x = ScreenWidth_c * i;

 NewMC_mc._y = 0;

 var mcLoader:MovieClipLoader = new
 MovieClipLoader();

 mcLoader.addListener(this);

 mcLoader.loadClip(WebsiteMap_a[i].File_tx,
 NewMC_mc);



 function onLoadInit(mc:MovieClip) {

 trace(onLoadInit:  + mc);

 }





 }

 
 



 I get NOTHING ! My external movieClips are not load or at least displayed.



 But if If replace:

 var NewMC_mc:MovieClip =
 ContentContainer_mc.createEmptyMovieClip(container+i,
 getNextHighestDepth());



 by



 var NewMC_mc:MovieClip = createEmptyMovieClip(container+i,
 getNextHighestDepth());



 it works.



 But I want to load my external into the movie clip named
 ContentContainer_mc present on the main scene on the root of my main
 Movie.



 What am I missing here ?

 Must be stupid.



 Any advice are welcome,



 Thanks,



 Hugues.



 ___
 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



 -
 New Yahoo! Messenger with Voice. Call regular phones from your PC and save
 big.

 -
 New Yahoo! Messenger with Voice. Call regular phones from your PC and save
 big.

 -
 Yahoo! Messenger with Voice. Make PC-to-Phone Calls to the US (and 30+
 countries) for 2�/min or less.
 ___
 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
 

Re: [Flashcoders] There is no method with the name 'Math'.

2006-04-06 Thread Weldon MacDonald
it works for me. the only thing I can think of is it's not finding the
class. Does syntax coloring recognise it? Did you modify class path?

On 4/6/06, Mike Mountain [EMAIL PROTECTED] wrote:
 Why on earth would the compiler be telling me

 There is no method with the name 'Math'.
 iNumber = Math.floor(iNumber/2);

 ?

 M

 ___
 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



--
Weldon Mac Donald
___
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 2 - suitable for designers?

2006-03-27 Thread Weldon MacDonald
I prefer to do most everything in code, but like you the sights I've
done aren't RIAs or even close. For that reason I stuck with  AS1,
until recently. When I look back at the sites and how they were
constructed, I'm astounded at how much cleaner my sites would be, how
much time, effort, and debugging could have been saved, by using AS2
features. Once you know how to write classes for the things you do
often and how to use the classes developed by others, you'll find that
even if  you don't need the all of the oop features (inheritance,
interfaces, polymorphism, etc...), using classes is worth the trip to
AS2.

On 3/27/06, Kevin Cannon [EMAIL PROTECTED] wrote:
 Hi,

 I hope this isn't off-topic but I've been struggling to find the answer, and
 this list has been a great help to me over the years.

 I'm a designer, but often code in Flash. I'm not building huge RIAs, usually
 just adding small little bits of interactivity to sites, and building some
 multimedia interfaces and gathering data from XML etc...  Nothing hardcore,
 but a bit more that just tinkering with AS.

 Up until now I've always used AS1, and though I've bought Colin Moock's AS2
 book, it seems like a bit leap to make, and from what I've read it seems like
 many of the advantages of AS2 are in having proper OO, and more manageable
 code for large projects.

 I'm wondering if AS2 offers any advantages to me, or if sticking with AS1
 would be better. Is AS2 (and now 3) the natural progression of Flash coding,
 is there even a future for AS1, all the useful libraries seem to be AS2 only
 these days too, perhaps that alone is a reason to switch. I'm unsure as to
 what path I'm supposed to be on.

 Any advice you could give me would be appreciated,

 - Kevin
 ___
 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



--
Weldon Mac Donald
___
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] Private Static -static

2006-03-27 Thread Weldon MacDonald
Your trying to access the properties width and heigh from a static
function getArea. The problem is a static function is designed to
handle class wide properties and width and height are local to each
insttance of the class. The compiler won't allow it. Remove the static
from the function definition, I don't see why they would be needed
there anyway.

On 3/27/06, CK [EMAIL PROTECTED] wrote:
 Hi,

 In the following code: I'm getting the following static from the
 ouput window:
 **Error** /Users/user/Desktop/code/oop_review/BOX/Box.as: Line 34:
 Instance variables cannot be accessed in static functions.
 return width*height;

 Total ActionScript Errors: 1 Reported Errors: 1

 How could I access these instance variables from within this private
 static method? Is it advisable using Private Static? Would I have to
 create an instance of the class then access the properties?



 //AS
 class Box {
 //accessing a static property through a method.
 //The box class, with methods to set and retreive the
 //value of the class property, numSides.
 //
 //The class property numSides
 private static var numSides:Number = 4;
 //
 private var width:Number;
 private var height:Number;
 private var area:Number;
 //
 //all CAPS denotes constants, values that never change.
 private static var DEFAULT_WIDTH:Number = 30;
 private static var DEFAULT_HEIGHT:Number = 20;
 //
 public static var maxWidth = 250;
 public static var maxHeight = 250;
 //
 //The constructor function.
 public function Box(w:Number, h:Number) {
 if (w == undefined) {
 w = DEFAULT_WIDTH;
 }
 if (h == undefined) {
 h = DEFAULT_HEIGHT;
 }
 width = w;
 height = h;
 //initialize area. This is perfectly legal within a 
 constructor
 //area = width*height;
 }
 private static function getArea():Number {
 return width*height;
 }
 //Method for setting numSides.
 public function setNumSides(newNumSides:Number):Void {
 numSides = newNumSides;
 }
 //Method for getting numSides.
 public function getNumSides():Number {
 return numSides;
 }
 //Accessor to retreive width
 public function getWidth():Number {
 return width;
 }
 //Accessor to assign width
 public function setWidth(w:Number):Void {
 width = w;
 }
 //Accessor to retreive height
 public function getHeight():Number {
 return height;
 }
 //Accessor to set height
 public function setHeight(h:Number):Void {
 height = h;
 }
 //reset the dimensions
 public function resetDimensions():Void {
 height = 1;
 width = 1;
 trace(Dimensions reset !);
 }
 public function onMouseDown():Void {
 resetDimensions();
 }
 public function enableReset():Void {
 Mouse.addListener(this);
 }
 public function disableReset():Void {
 Mouse.removeListener(this);
 }
 //this gurantees a safe means of deleting its instances.
 public function die():Void {
 disableReset();
 //Unregister the object so the Mouse class
 //deletes the reference to it.
 }
 }
 //End AS
 ___
 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



--
Weldon Mac Donald
___
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] CSS with input text

2006-03-20 Thread Weldon MacDonald
Wouldn't having full www support for html in Flash mean building in a
browser. Not too likely I think.
What about a component in Flash that allows the display of a web
browser window in a flash document, using the browsers functionality.
I wouldn't know where to start, but it would be cool.

On 3/20/06, Danny Kodicek [EMAIL PROTECTED] wrote:
  Coming from the Director world you know there are basic issues with some
  of
  the more basic elements, such as HTML text, in Director. In the meantime
  bigger and badder items have been added to Director giving it more *WOW*
  while basic issues were not addressed. (And, no, Xtra is not a solution
  to
  what should be a basic implementation.)

 Absolutely (although don't forget that many Xtras are actually part of the
 standard Director package: text support itself is wrapped in a standard
 Xtra). Having said that, Director hasn't had much in the way of significant
 improvements anywhere since D8.5 introduced 3D. We had Imaging Lingo (the
 equivalent of BitmapData) since D7, about 6 years ago, but it has hardly
 changed since then. Mostly, subsequent releases have been designed to bring
 us up to speed with current developments in Flash.

  I'm saying this, because it makes me wonder if the same is happening (will
  happen) with Flash!

 Already is. Many features of Flash have that sense of being half-done (XML
 object, Text support and  Sound spring to mind fairly quickly)

 Danny

 ___
 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



--
Weldon Mac Donald
___
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] Alpha-blending two MC's with bitmaps?

2006-03-20 Thread Weldon MacDonald
I've done it with dynamically loaded images and createEmptyMovieClip.
There shouldn't be a problem, but then _visible won't hide them.
Good luck

On 3/20/06, Sascha Balkau [EMAIL PROTECTED] wrote:
 Weldon, thanks for trying to help!
 Yes the images are all definately available when the blend happens. Maybe it
 has something to do with the fact that the images are loaded dynamically
 from external files into movieclips.
 Either way I will see if I can locate the source of the problem!

 Sascha



 - Original Message -
 From: Weldon MacDonald [EMAIL PROTECTED]
 To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
 Sent: Sunday, March 19, 2006 10:12 PM
 Subject: Re: [Flashcoders] Alpha-blending two MC's with bitmaps?


 I experimented and with the images as mc's, attached from library, and
 your function on frame one, not as a class, the function works as you
 wanted it too.
 Are you sure the images are really where you expect them to be?
 ie. is the image loaded when the call is made?
 Maybe something about your class setup?

 On 3/19/06, Sascha Balkau [EMAIL PROTECTED] wrote:
  Weldon, here's the method I've wrote to handle the blending. It's very
  simple and I cannot detect any bug in there ...

  The blending works but strangely the fromImage is not shown, instead the
  toImage fades in from the white background of my Flash movie. As I
  mentioned
  before there are other image mc's in the holder movieclip but they are on
  depths 0 to 20 and are invisible so I doubt they have any influence on
  this.
 
  Sascha

 Weldon Mac Donald

 ___
 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



--
Weldon Mac Donald
___
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] Alpha-blending two MC's with bitmaps?

2006-03-19 Thread Weldon MacDonald
I experimented and with the images as mc's, attached from library, and
your function on frame one, not as a class, the function works as you
wanted it too.
Are you sure the images are really where you expect them to be?
ie. is the image loaded when the call is made?
Maybe something about your class setup?

On 3/19/06, Sascha Balkau [EMAIL PROTECTED] wrote:
 Weldon, here's the method I've wrote to handle the blending. It's very
 simple and I cannot detect any bug in there ...

 The blending works but strangely the fromImage is not shown, instead the
 toImage fades in from the white background of my Flash movie. As I mentioned
 before there are other image mc's in the holder movieclip but they are on
 depths 0 to 20 and are invisible so I doubt they have any influence on this.

 Sascha

Weldon Mac Donald
___
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] Alpha-blending two MC's with bitmaps?

2006-03-18 Thread Weldon MacDonald
I've done what you seem to be discribing and it works. You probably
have a small bug in your code. Without seeing the code it's hard to
say what it is, but you could look for a depth duplication problem.
Have you made certain the lower one is loading at all or has been made
visible...etc... Your idea will work, you just need to do some
debugging

On 3/18/06, Sascha Balkau [EMAIL PROTECTED] wrote:
 Hi Michael,

 there are several mc's in one container mc but all are set to invisible
 except for two at a time. And I want to fade between these two but I haven't
 managed to do so. The top most mc always fades in from the white background
 as if the bottom mc would be invisible. But it isn't. Flash 8 is no choice
 as my client wants it in Flash 7.

 Thanks,
 Sascha


 - Original Message -
 From: Michael Bedar [EMAIL PROTECTED]
 To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
 Sent: Sunday, March 19, 2006 12:32 AM
 Subject: Re: [Flashcoders] Alpha-blending two MC's with bitmaps?


  There is a limit to how many alpha'd movieclips you can have  overlapping
  before Flash runs into display errors. If a movieclip is  supposed to be
  completely invisible, set _visible=false instead of  _alpha=0, so that
  Flash does not need to display it.
 
  If for some reason you really need to display many images overlapped  with
   0 alpha, look into drawing them into the same bitmap in Flash 8.
 
 
 
  On Mar 18, 2006, at 7:05 AM, Sascha Balkau wrote:
 
  Hi list,
 
  I got a number of movieclips created with createEmptyMovieClip,  into
  every MC I load a JPG image dynamically and then it's set it  invisible.
  Then I change the depth of two of these mc's, say one to depth  2000, the
  other to 2001, make them visible and then I try to blend  over these two
  images with an alpha transparency by setting the  _alpha of the upper
  image to 0 and increase it up to 100 in an  onEnterFrame.
  However it doesn't work, the upper image always fades in from 100%  white
  and not the underlying image.
  Did I missed something? Is that not possible with _alpha in Flash?
 
  Thanks for any hints!
  Sascha
 
  ___
  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@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@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



--
Weldon Mac Donald
___
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] targeting specific content in HTML file

2006-03-08 Thread Weldon MacDonald
If different pieces of the file go to different text boxes, then it sounds
like a job for xml. If you want to parse the html file and distribute it,
then you'd have to write a parser to do it for you. A specific answer would
require more details on what you want to do.

On 3/8/06, Jeanna Lievsasy [EMAIL PROTECTED] wrote:

 Question.  I'm working in Flash 8 and loading a CSS  HTML file into a
 dynamically created text box.  Is there a way to populate multiple dynamic
 text fields with specific content from the HTML file?  I dont want the
 entire HTML file to load into each box, but i do want all my content in
 one
 file.
 ___
 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




--
Weldon Mac Donald
___
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


FW: [Flashcoders] Ajax and Flash

2005-11-08 Thread Weldon MacDonald
 
I'm skeptical of abstract technology discussions, unattached to a real
world need. Amen, but you have to keep up with the abstract discussions in
order to best deal with the real world problems. If you keep forcing new
solutions out of the same mould, your probably not creating the best
solutions.
In many ways Flash and Ajax compete, but Flash can also be an integral part
of Ajax. While Flash has many advantages, handling text rich content isn't
one of them. If your developing something that needs asynchrony for some
elements, but also includes a lot of text, you may have to mix things up. As
you say it depends on the problem.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of John Dowdell
Sent: Monday, November 07, 2005 11:17 AM
To: Flashcoders mailing list
Subject: Re: [Flashcoders] Ajax and Flash

Weldon MacDonald wrote:
 Where does Flash fit in with the Ajax paradigm?

A lot depends on what the Ajax paradigm might be ;-)

I know that Flash and JavaScript have coexisted for about a decade now, and
that both are necessary clientside technologies. Both will also improve and
evolve, at their different rates of adoption and predictability.

In such discussions I usually look for the particular job under
consideration -- the tasks that must be done, the audience that must be
engaged, the client who knows the message they're trying to convey. The
technologies must serve these realworld needs to be useful, so I'm skeptical
of abstract technology discussions, unattached to a realworld need.

jd






--
John Dowdell . Macromedia Developer Support . San Francisco CA USA
Weblog: http://www.macromedia.com/go/blog_jd
Aggregator: http://www.macromedia.com/go/weblogs
Technotes: http://www.macromedia.com/support/
Spam killed my private email -- public record is best, thanks.
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] Ajax and Flash

2005-11-07 Thread Weldon MacDonald

Where does Flash fit in with the Ajax paradigm? As a competitor, or as an
integrated part. The answer seems to be both, but I'm interested in how
working developers see it.




___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


RE: [Flashcoders] How to make a doughnut?

2005-10-29 Thread Weldon MacDonald
 cut the ring with a 1 pixel line, then it's like a c with a pixel opening.
You could do this with the drawing api, but if the split shows too badly you
might need to patch it

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Navneet
Behal
Sent: Saturday, October 29, 2005 9:54 AM
To: Flashcoders mailing list
Subject: [Flashcoders] How to make a doughnut?

After putting a couple of hours on the problem, I am still in a daze on how
would one go about making a doughnut shape (circle with cut-out in the
center) using the drawing API.

I'm not talking about drawing a circle using:

lineStyle(BIGNUMBERHERE, color, alpha);

I'd like to put in a gradient fill into a doughnut shape. And it has to be a
doughnut, not a simulation of it (ie. not by drawing 2 circles over each
other and keeping the center cirlce the same as the background color). Real
dunkin' doughnut!

Any ideas?

Thanks for your time.

Regards,
Navneet 

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] Flashout

2005-10-08 Thread Weldon MacDonald
I just installed eclipse 3.1.1 on my laptop, but I'm getting an error when I
try to create a .flashout file. I unzipped the download in to the plug-in
folder as per the instructions I could find, did I miss something? Where can
I ask about this error?


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders