Game Development Reference
In-Depth Information
6. Place the center point at the botom of the image, between the wheels.
7.
Repeat this process for all of the images that you need to create a
full-circle animaion.
As I menioned, the second method does take some endurance, but it works.
Objective complete - mini debriefing
We now have a kart sprite with a series of costumes that allow the sprite to rotate in
all of the direcions. We will script these costumes in the next project.
Classified intel
You might want to test whether your rotaing animaion looks nice. That's easy to do
and just requires adding the following small script to the sprite:
1. Start with a set size to () % block and fill in 1000 . We will overscale the image
so that you can clearly see all the details.
2. Atach a forever loop.
3.
Inside the loop, place a next costume loop to endlessly cycle through all of the
costumes that we added.
4.
Also add a wait () secs block to slow the animaion down a bit; ill in the value 0.1 .
The following screenshot shows the final script:
Move your sprite to the center of the stage and click on the script we just made to acivate
it. The sprite will scale up and start animaing. Does the sprite move in a luid circle? If
the rotaion is jumpy or seems to move against direcion, you might need to switch a few
costumes around. Does the image seem to wiggle or hop up and down? Then you probably
didn't place the center point correctly. You can tweak and test your animaion cycle unil it
looks just right.
 
Search WWH ::




Custom Search