protected override void SetData(byte[] data) { GrassDataSL.Init(); if (null != data) { GrassDataSL.Import(data); } }
public static bool DeleteAtPos(Vector3 voxelPos) { if (Self == null) { Debug.LogError("The Grass System is not initialized"); return(false); } INTVECTOR3 pos = new INTVECTOR3((int)voxelPos.x, (int)(voxelPos.y + 0.5f), (int)voxelPos.z); if (_self.scene.data.Remove(pos.x, pos.y, pos.z)) { GrassDataSL.AddDeletedGrass(pos); return(true); } return(false); }
public override void New() { base.New(); GrassDataSL.Init(); }
protected override void WriteData(BinaryWriter bw) { GrassDataSL.Export(bw); }