예제 #1
0
    // Use this for initialization
    void Start()
    {
        Block         block         = new Block(blockType, Vector3.zero);
        BlockRenderer blockRenderer = gameObject.GetComponent <BlockRenderer>();

        if (drawCombined)
        {
            blockRenderer.DrawCombined(block, cubeMaterial);
        }
        else
        {
            blockRenderer.Draw(block, cubeMaterial);
        }
    }
예제 #2
0
 private void BattlefieldForm_Paint(object sender, PaintEventArgs e)
 {
     e.Graphics.Clear(Color.LightGray);
     renderer.Draw(e.Graphics);
 }