void AddSpriteVertices(BlockID block) { int i = atlas.Get1DIndex(BlockInfo.GetTextureLoc(block, Side.Left)); DrawInfo part = normalParts[i]; part.spriteCount += 4 * 4; }
void AddSpriteVertices(byte tile, int count) { int i = atlas.Get1DIndex(info.GetTextureLoc(tile, TileSide.Left)); DrawInfo part = drawInfoNormal[i]; part.spriteCount += 6 + 6 * count; part.iCount += 6 + 6 * count; }
void AddSpriteVertices(byte block) { int i = atlas.Get1DIndex(info.GetTextureLoc(block, Side.Left)); DrawInfo part = drawInfoNormal[i]; part.spriteCount += 6 * 4; part.iCount += 6 * 4; }
void AddVertices(BlockID block, int face) { int i = TerrainAtlas1D.Get1DIndex(BlockInfo.GetTextureLoc(block, face)); bool isLava = IsBlockLiquid(block); bool isTranslucent = BlockInfo.Draw[block] == DrawType.Translucent; DrawInfo part; //DrawInfo part = BlockInfo.Draw[block] == DrawType.Translucent ? translucentParts[i] : normalParts[i]; if (isLava && !isTranslucent) { part = liquidParts[i]; } else { part = isTranslucent ? translucentParts[i] : normalParts[i]; } #if ALPHA if (block == Block.Fence) { part.vCount[face] += 4 * 9; } else { part.vCount[face] += 4; } #else part.vCount[face] += 4; #endif }
void AddVertices(BlockID block, int face) { int i = TerrainAtlas1D.Get1DIndex(BlockInfo.GetTextureLoc(block, face)); DrawInfo part = BlockInfo.Draw[block] == DrawType.Translucent ? translucentParts[i] : normalParts[i]; part.vCount[face] += 4; }