示例#1
0
文件: Editor.cs 项目: zarac/tgspu
        public Editor(ZoombaSmasher zoomba)
            : base(zoomba)
        {
            this.zoomba = zoomba;
            mapDir = Path.Combine(zoomba.Content.RootDirectory, basePath);
            rows = 30;
            columns = 40;
            squares = new MapSquare[rows,columns];
            windowWidth = zoomba.graphics.PreferredBackBufferWidth;
            windowHeight = zoomba.graphics.PreferredBackBufferHeight;
            squareWidth = windowWidth / columns;
            squareHeight = windowHeight / rows;
            saver = new Saver(this);
            saver.Bounds = new Rectangle(windowWidth / 4, windowHeight / 4,
                windowWidth / 2, windowHeight / 2);
            saver.Text = "";
            cursor = new Cursor(zoomba, windowWidth / 2, windowHeight / 2);
            actions = new Actions();
            loader = new Loader(this);

            SetValidNameCharacters();
        }
示例#2
0
文件: Editor.cs 项目: zarac/tgspu
 public Cursor(ZoombaSmasher p_zoomba, int p_X, int p_Y)
 {
     zoomba = p_zoomba;
     X = p_X;
     Y = p_Y;
     Width = 10;
     Height = 10;
     color = new Color(112, 219, 255);
 }