Game Development Reference
In-Depth Information
Listing 3.19 Creating Class Structures for Storing Values
class spriteDetails
{
var pixelWidth: int;
var pixelHeight: int;
}
class animFrame
{
var startFrame: int;
var numberOfFrames: int;
}
var singleSpriteDimensions: spriteDetails;
var idle: animFrame;
var walkleft: animFrame;
var walkright: animFrame;
var walkforward: animFrame;
var walkback: animFrame;
FIG 3.17 Variables contained in class structures displayed in the Inspector.
Search Nedrilad ::




Custom Search