public void ResetState() { vCount = iCount = 0; spriteIndex = spriteCount = 0; vIndex = new DrawInfoFaceData(); Count = new DrawInfoFaceData(); }
unsafe void AddVertices(byte tile, int count, int face) { int i = atlas.Get1DIndex(info.GetTextureLoc(tile, face)); DrawInfo part = info.IsTranslucent[tile] ? drawInfoTranslucent[i] : drawInfoNormal[i]; part.iCount += 6; DrawInfoFaceData counts = part.Count; *(&counts.left + face) += 6; part.Count = counts; }
unsafe void AddVertices(byte block, int count, int face) { int i = atlas.Get1DIndex(info.GetTextureLoc(block, face)); DrawInfo part = info.IsTranslucent[block] ? translucentParts[i] : normalParts[i]; part.iCount += 6; DrawInfoFaceData counts = part.vCount; *(&counts.left + face) += 6; part.vCount = counts; }