public void CheckVerticalBorders(float current, float spacing, SpaceMeshCreator spaceMeshCreator) { if (current <= objectBorderInUnits.left && objectBorderInUnits.left <= current + spacing) { // left border shall be added?? spaceMeshCreator.AddWholeColumn(new Vector3(objectBorderInUnits.left, 0, 0)); } if (objectBorderInUnits.right > current && objectBorderInUnits.right <= current + spacing) { spaceMeshCreator.AddWholeColumn(new Vector3(objectBorderInUnits.right, 0, 0)); } }
public void BuildMesh(KeyboardCreator creator, Sprite spaceSprite) { if (meshCreator == null) { meshCreator = new SpaceMeshCreator(creator); } if (quadFront == null) { quadFront = transform.Find(QUAD_FRONT).GetComponent <Renderer>(); } meshCreator.BuildFace(quadFront, true); }