Monthly Archive for August, 2008

Papervision Collada – Spongebob SquarePants

Spongebob SquarePants

View Collada Spongebob in Papervision

I had some time on my hands this weekend and decided to mess around with loading Collada models with Papervision. I snagged a few models from Google Sketchup and went to town. Also tried to work in some OOP instead of just having one huge papervision file. I really need to clean up the source but rest assured the full source will be posted soon.

Basic lesson is that you can load a Collada file with just actionscript (packaged as a zip or just the dae file)

Actionscript:
  1. //Load zipped dae file
  2. protected function loadKMZ():void
  3. {
  4.     kmz = new KMZ();
  5.     kmz.load("model/spongebob_squarepants.zip");
  6.     kmz.addEventListener(FileLoadEvent.LOAD_ERROR, onKmzError);
  7.     kmz.addEventListener(FileLoadEvent.LOAD_COMPLETE, onKmzLoaded);
  8.    
  9.     //Scale if needed
  10.     kmz.scale = 20;
  11.     container.addChild(kmz);
  12. }
  13.  
  14. //load the dae file
  15. protected function loadDAE():void
  16. {
  17.     dae = new DAE();
  18.     dae.load("model/spongebob_squarepants.dae");
  19.     dae.addEventListener(FileLoadEvent.LOAD_ERROR, onDaeError);
  20.     dae.addEventListener(FileLoadEvent.LOAD_COMPLETE, onDaeLoaded);
  21.     container.addChild(dae);
  22. }

Adobe Flash CS3 Shortcuts – Publish with no preview – Macbook (pro) Mac but Vista / XP users

Keyboard Mac

I realize this is no great secret in the flash world (changing your keyboard shortcuts). The default setting is (SHIFT F12). Like most Flash Developers / Designers we adapt to our surroundings. If that be using a PC / Mac / someone else's fla / code / etc.  Over the past few months I was presented with several projects where I had to compile multiple fla files. This is not too bad until you do cntrl+enter wait for the preview - close it - ctrl+enter review the changes and start the process over again. So I finally started to use (SHIFT F12) but depending on when I rebooted or changed my apple prefs I kept adjusting my volume and long story short it was getting to be a pain.

I personally like using CTRL and Backspace (DELETE on mac keyboard). The only drawback is that you may accidentally delete something. :/ But 99.9% of the time its uber quick.

To get to the menu just go to "Edit" > "Keyboard Shortcuts..."   - Duplicate the current set. The "Publish" option that does not also generate a preview is under "File" and about 1/2 ways down.

Keyboard shortcuts

Hope this helps.


Follow papervision2 on Twitter

RSS Feed