For this Shockwave project we will discuss the implementation of the following:
The process of adding graphics is easy by creating primitives with code. In this example, theĀ Sound_compass_class uses the Primitive_models_class to create a sphere model with code, which visually represents the sound compass in this project. This is very helpful for testing. (Once the game is ready for a real production release, the sphere is usually set to invisible).
To achieve better graphic precision, you can import graphics from modeling tools such as Autodesk 3ds Max. For this project I've included a bones animated character which is embedded (for simplicity here) in the ShockwaveGameAccessibility.dir file. Here are the steps to examine the animated character:
Note: For the purposes of this project, the 3D world is embedded into the .dir file. Later if you wish to update this sample project and decide to link the avatar_model cast member using the Import dialog box (by selecting File > Import), remember that you'll need to add code to check the properties of the 3D cast member, such as mediaReady, loaded and state when scripting. To simplify things for this sample project I chose to embed the content. Linked media is great for working in groups and for optimizing the downloading and loading process, but it requires some extra scripting in order to work properly in runtime.