- Interactive Components
- Working in Photoshop
- Preparing for Transfer
- Moving Elements into Director
Preparing for Transfer
Once you have all of your elements created in Photoshop, it's time to switch to Director. For the fastest and easiest integration of layers from a Photoshop file is to use a Director Xtra called PhotoCaster by Media Lab. Serious developers should not even consider working in Director without this tool. There are trial versions of this Xtra that are included when you install Director onto your computer. Once installed (the Xtra is placed into the Xtras folder), you will access PhotoCaster from the Insert menu within Director. Until you register the software, red diagonal lines will appear across your images, indicating that you are working with an unregistered version of the software. Otherwise, all features and functions are there for you to experiment with during your trial phase.
Select Media Lab Media from the Insert menu. Select PhotoCaster from the popup menu. The PhotoCaster window should appear. Using the standard file hierarchy, locate the layered Photoshop file you have just created. Select the file, but do not click Open yet.
For first-time users, I recommend setting up a few additional settings first. Select 32-bit (24 + Alpha) in the Color section. This will import layers, preserving any alpha channels you have used or created in Photoshop. I also prefer to keep Select Layers To Import checked in the Advanced Options of the PhotoCaster window. This allows me to select only the layers I want to actually bring into Director. If you're like me, I typically have layers in my Photoshop file that I may not want brought in to Director as they appear in this file (such as the background images that I was using for placement or other test layers that I did not necessarily want to discard as of yet).
Check off the Import to Score and Keep Registration Point options if you are selecting only the normal layers for now. With this feature selected, once you click Open, not only will each layer be created as an independent Cast Member, but those layers will also automatically be added to your Stage and Score. The reason I don't keep this option on is because I wouldn't want my rollover and down state layers to be added to the Stage and Score right now. This will cause only more work deleting those particular (and unwanted) Sprites in my score. One feature that I do always keep selected is the Keep Registration Point. Since I've created my Photoshop canvas as the same size as my Stage, the registration points of my layers in Photoshop will remain the same inside Director, therefore allowing me to accurately line up my layers as they appeared in my Photoshop file. I won't have to waste a great deal of time and effort trying to move my text elements (or any layered object) around on the Stage pixel by pixel trying to line things up.
Depending on how you set up your file, you may need to have the Text as Graphic or Preserve White Pixels options selected. These options convert the text layer into an actual graphic layer inside Director and keep any white pixels you intend to keep visible, giving you the cleanest, desired appearance. Try different combinations to see what works for you and your needs. Once you find the right combinations that work, you can choose to save them as the default so that you do not have to set them every time you import files through PhotoCaster. Simply click Save in the Settings area of the Photocaster window.