Sep 21

[kml_flashembed movie="/labs/swf/reveal.swf" height="150" width="450" /]

I was talking the other day with a friend about a small challenge, having 2 images on stage with 2 ideas. 1- have the experience being user driven (in this case the mouse reveals one image while hiding the other) 2- Use XML for easy update. So we fired flash and the above is the visual and the code below… Read the rest of this entry »

Aug 15

[kml_flashembed movie="/labs/swf/phpwritetodb.swf" height="150" width="450" /]

I have written a small script that will assist you into using communication between Flash and PHP to write to a mySQL database. The task is simple, verify the contents of the fields in flash and then send the information to PHP who then writes the information into the database. Read the rest of this entry »

Jul 31

[kml_flashembed movie="/labs/swf/iHold.swf" height="150" width="450" quality="best" fvars="fs=/imgs/adobe/adobeAir.jpg" /]
For all Developers out there it is nice to hear that Adobe is running a contest where you could win as much as US$100,000 to be used for the travel of your choice among other goodies such as a Mac Pro 8Core 2×750GB storage, 2×27″ WS Monitors and more… Read the rest of this entry »

Jul 25

[kml_flashembed movie="/labs/swf/volumeExperiment.swf" height="150" width="450" /]

I had a good friend ask me if I knew of a resource for a volume controler, and I didn’t know of any tutorial or code of the top of my head so I went ahead and wrote it for AS2 so I hope this can help some others out there. Read the rest of this entry »

Mar 7
Actionscript:
  1. var totalArgs = arguments.length;
  2. trace("Number of Arguments passed = " + totalArgs);
  3. for (var i:Number = 0; i <totalArgs; i++) {
  4.     trace ("Argument "+i + ": " + arguments[i]);
  5. }

Mar 7
Actionscript:
  1. function formatDecimals2 (num, digits) {
  2.  
  3. if (num <0 ) {
  4. num = 0;
  5. }
  6.  
  7. if (digits <= 0) {
  8. return Math.round(num);
  9. }
  10.  
  11. var tenToPower = Math.pow(10, digits);
  12. var cropped = String(Math.round(num * tenToPower) / tenToPower);
  13.  
  14. trace("digits:" + digits + " - " + cropped);
  15.  
  16. }
  17.  
  18. formatDecimals2( 35435.234234, 2);
  19. formatDecimals2( 35435.234234, 3);
  20. formatDecimals2( 35435.234234, 4);

Jan 29

Thats it! I am tired of getting the "Enhanced fill not supported in current player version" problem when I import fills from AI/FH/FW and you need to export to V7 or under, so once and for all I am putting a stop to it.

Here are 3 simple steps to get rid of this problem (of course this will be applied after you have imported a vector image with gradients to your stage).

1. Change your export settings to V8.
2. Pull the "Color Mixer" Palette.
3. Under Overflow select "Extend", take off the check mark from Linear RGB

That is it now you can change your export settings back to V7 or V6 or under and you should be fine. That is all you have to do and all your problems should go away, no more warnings no more asking you to fix your gradients.

Ah! but sometimes the gradient or Flash will be stubborn and still make fuss about the Fills. Well these are some things you can do..

If under the "Color Mixer" Palette your Overflow was selected as "Extend" and the Linear RGB was unselected, well just select Overflow again and check and uncheck the Linear RGB option. That will fix the stubbornness 99.9999999% of the time.

If you still have troubles after you have completed the steps above feel free to ask.

Dec 1
Actionscript:
  1. stageListener = new Object();
  2. stageListener.onResize = function() {
  3. // enter what you want to do on resize, for example:
  4. contentHolder_mc._y = Stage.height - contentHolder_mc._height;
  5. contentHolder_mc._width = Stage.width;
  6. }
  7. Stage.addListener(stageListener);
  8. stageListener.onResize();

Nov 9

a = b ? true : false;

a == b ? (true1, true2) : false

Nov 3

If you are exporting any artwork from Illustrator to SWF and when working in Flash and player 7(or less) you might get the following error "Enhanced stroke is not supported in this player".

One way to fix this issue is by setting "Perserve Editability Where Possible" under the Method section.
Now this might not work with all the artwork where you want to be able to do heavy edits within flash but its worth a shoot.

« Previous Entries