public void set_animation_id(uint animID) { var anim = (DatLoader.FileTypes.Animation)DBObj.Get(new QualifiedDataID(8, animID)); Anim = new Animation(anim); if (Anim == null) { return; } if (HighFrame < 0) { HighFrame = Anim.NumFrames - 1; } if (LowFrame >= Anim.NumFrames) { LowFrame = Anim.NumFrames - 1; } if (HighFrame >= Anim.NumFrames) { HighFrame = Anim.NumFrames - 1; } if (LowFrame > HighFrame) { HighFrame = LowFrame; } }
public static Setup MakeSimpleSetup(uint gfxObjID) { var setup = new Setup(); setup.NumParts = 1; setup.Parts = new List <PhysicsPart>(1); var gfxObj = (Collision.GfxObj)DBObj.Get(new QualifiedDataID(6, gfxObjID)); if (gfxObj != null) { if (gfxObj.PhysicsSphere != null) { setup.SortingSphere = gfxObj.PhysicsSphere; } else { setup.SortingSphere = gfxObj.DrawingSphere; } } var part = new PhysicsPart(); part.GfxObj = gfxObj; setup.Parts.Add(part); var placementType = new PlacementType(); //placementType.AnimFrame.NumParts = 1; setup.PlacementFrames.Add((int)gfxObjID, placementType); return(setup); }
public bool LoadGfxObjArray(uint rootObjectID /*, GfxObjDegradeInfo newDegrades*/) { var gfxObj = (DatLoader.FileTypes.GfxObj)DBObj.Get(new QualifiedDataID(6, rootObjectID)); GfxObj = GfxObjCache.Get(gfxObj); // degrades omitted return(GfxObj != null); }
public static Setup Get(uint setupID) { return((Setup)DBObj.Get(new QualifiedDataID(7, setupID))); }