public BombFactory(SpriteBatchName sbName, PCSTree tree) { this.pSpriteBatch = SpriteBatchManager.Find(sbName); Debug.Assert(this.pSpriteBatch != null); this.pTree = tree; Debug.Assert(this.pTree != null); }
public AlienFactory(SpriteBatchName sbName, PCSTree tree) { this.pSpriteBatch = SpriteBatchManager.Find(sbName); this.pSpriteBoxBatch = SpriteBatchManager.Find(SpriteBatchName.Boxes); Debug.Assert(this.pSpriteBatch != null); this.pTree = tree; }
public static SpriteBatch Add(SpriteBatchName spriteBatchName) { SpriteBatchManager spBatchMan = SpriteBatchManager.GetInstance(); SpriteBatch spBatch = (SpriteBatch)spBatchMan.BaseAdd(); spBatch.name = spriteBatchName; return(spBatch); }
public AlienFactory(SpriteBatchName sbName, PCSTree tree, Random random) { this.pSpriteBatch = SpriteBatchManager.Find(sbName); Debug.Assert(this.pSpriteBatch != null); this.pTree = tree; Debug.Assert(this.pTree != null); this.pRandom = random; }
public static SpriteBatch Find(SpriteBatchName spriteBatchName) { SpriteBatchManager spMan = SpriteBatchManager.GetInstance(); SpriteBatch spBatch = (SpriteBatch)spMan.BaseFind(new SpriteBatch { name = spriteBatchName }); return(spBatch); }
public ShieldFactory(SpriteBatchName sbName, SpriteBatchName collisionSBName, PCSTree pTree) { this.pSpriteBatch = SpriteBatchManager.Find(sbName); Debug.Assert(this.pSpriteBatch != null); this.pCollisionSpriteBatch = SpriteBatchManager.Find(collisionSBName); Debug.Assert(this.pCollisionSpriteBatch != null); Debug.Assert(pTree != null); this.pTree = pTree; }
public DrawBatch(SpriteBatch inspriteBatch, GraphicsDevice ingraphicDevice, SpriteSortMode inSort, BlendState inBlend, SpriteBatchName inName, int buffersize = 10, int delta = 3) { GameSprites = new LinkedList(buffersize, delta, NodeType.GameSpr); DeltaGrow = delta; spriteBatch = inspriteBatch; graphicDevices = ingraphicDevice; sortMode = inSort; blendState = inBlend; Name = inName; _isActive = true; }
public void Kill(ColObj inObj) { SpriteBatchName inSpName = SpriteBatchName.Collisions; GameSprite _gameSprite = inObj.getColSprite(); SpriteBatchManager.getInstance().Kill(_gameSprite, inSpName); ListNode KillNode = Find(inObj); if (KillNode != null) { List.Remove(KillNode); } }
public DrawBatch Find(SpriteBatchName inName) { int index = 0; DrawBatch Obj = (DrawBatch)List.getDatabyIndex(index); while (Obj != null) { if (Obj.getName() == inName) { return(Obj); } index++; Obj = (DrawBatch)List.getDatabyIndex(index); } return(null); }
public void KillObject(GameObj inObj, SpriteBatchName inSpName) { GameSprite _gameSprite = inObj.getGameSprite(); if (_gameSprite != null) { SpriteBatchManager.getInstance().Kill(_gameSprite, inSpName); } ColObj _colObj = inObj.getColObj(); if (_colObj != null) { ColObjManager.getInstance().Kill(_colObj); } ColGroup _ColGroup = ColGroupManager.getInstance().find(inObj.TempColGroupName); _ColGroup.Kill(inObj); Kill(inObj); }
public void Set(SpriteBatchName name, int reserveSize, int reserveIncrement) { this.name = name; this.FillReserve(reserveSize); }
public void Kill(GameSprite inGSprite, SpriteBatchName inSpName) { DrawBatch DB = this.Find(inSpName); DB.Kill(inGSprite); }