Ejemplo n.º 1
0
    public void OnPower()
    {
        IsStarting = true;
        TextAsset code = Resources.Load("start") as TextAsset;

        // draw logo
        Texture2D logo    = Resources.Load("logo") as Texture2D;
        int       xcenter = (DisplaySystem.WIDTH - logo.width) / 2;
        int       ycenter = (DisplaySystem.HEIGHT + logo.height) / 2;

        _screen.SetFontColor(Color.white);
        _screen.SetBackColor(Color.black);
        _screen.Clear();
        _screen.DrawImage(xcenter, ycenter, logo.width, logo.height, logo.GetPixels());

        _runner.RunCode(code.text);
    }
Ejemplo n.º 2
0
    void SetBackColor(int r, int g, int b)
    {
        Color c = Utils.ParseColor(r, g, b);

        _console.Invoker.Add(() => _display.SetBackColor(c));
    }