Ejemplo n.º 1
0
    //刀偏设定界面
    void ToolOffSet()
    {
        GUI.Label(new Rect((Main.corner_px + 6.5f) / 1000f * Main.width, (Main.corner_py - 4f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "刀偏", Main.sty_Title);
        GUI.Label(new Rect((Main.corner_px + 30f) / 1000f * Main.width, (Main.corner_py + 23f) / 1000f * Main.height, 40f / 1000f * Main.width, 20f / 1000f * Main.height), "号.", Main.sty_MostWords_ToolOffSet);
        GUI.Label(new Rect((Main.corner_px + 76.5f) / 1000f * Main.width, (Main.corner_py + 23f) / 1000f * Main.height, 100f / 1000f * Main.width, 20f / 1000f * Main.height), "形状(H)", Main.sty_MostWords_ToolOffSet);
        GUI.Label(new Rect((Main.corner_px + 186.5f) / 1000f * Main.width, (Main.corner_py + 23f) / 1000f * Main.height, 100f / 1000f * Main.width, 20f / 1000f * Main.height), "磨损(H)", Main.sty_MostWords_ToolOffSet);
        GUI.Label(new Rect((Main.corner_px + 296.5f) / 1000f * Main.width, (Main.corner_py + 23f) / 1000f * Main.height, 100f / 1000f * Main.width, 20f / 1000f * Main.height), "形状(D)", Main.sty_MostWords_ToolOffSet);
        GUI.Label(new Rect((Main.corner_px + 406.5f) / 1000f * Main.width, (Main.corner_py + 23f) / 1000f * Main.height, 100f / 1000f * Main.width, 20f / 1000f * Main.height), "磨损(D)", Main.sty_MostWords_ToolOffSet);
        Main.number = 8 * Main.ToolOffSetPage_num;

        //编号
        for (int i = 0; i < 8; i++)
        {
            GUI.Label(new Rect((Main.corner_px + 11.5f) / 1000f * Main.width, (tool_corner_y + i * tool_cell_height) / 1000f * Main.height, 40f / 1000f * Main.width, 25f / 1000f * Main.height), Main.Tool_numberGet(Main.number + 1 + i), Main.sty_MostWords_ToolOffSet);
        }

        //背景框
        for (int i = 0; i < 8; i++)
        {
            for (int j = 0; j < 4; j++)
            {
                GUI.Label(new Rect((tool_corner_x + j * tool_cell_width) / 1000f * Main.width, (tool_corner_y + i * tool_cell_height) / 1000f * Main.height, tool_cell_width / 1000f * Main.width, tool_cell_height / 1000f * Main.height), "", Main.sty_OffSet_Coo);
            }
        }

        GUI.Label(new Rect(Main.tool_setting_cursor_w / 1000f * Main.width, Main.tool_setting_cursor_y / 1000f * Main.height, 107f / 1000f * Main.width, 19f / 1000f * Main.height), "", Main.sty_EDITCursor);

        //显示数字
        for (int i = 0; i < 8; i++)
        {
            GUI.Label(new Rect((tool_corner_x + 0 * tool_cell_width) / 1000f * Main.width, (tool_corner_y + i * tool_cell_height) / 1000f * Main.height, 110f / 1000f * Main.width, 25f / 1000f * Main.height), Main.ToolStringGet(CooSystem_script.shape_H[Main.number + i]), Main.sty_SmallNum);
            GUI.Label(new Rect((tool_corner_x + 1 * tool_cell_width) / 1000f * Main.width, (tool_corner_y + i * tool_cell_height) / 1000f * Main.height, 110f / 1000f * Main.width, 25f / 1000f * Main.height), Main.ToolStringGet(CooSystem_script.wear_H[Main.number + i]), Main.sty_SmallNum);
            GUI.Label(new Rect((tool_corner_x + 2 * tool_cell_width) / 1000f * Main.width, (tool_corner_y + i * tool_cell_height) / 1000f * Main.height, 110f / 1000f * Main.width, 25f / 1000f * Main.height), Main.ToolStringGet(CooSystem_script.shape_D[Main.number + i]), Main.sty_SmallNum);
            GUI.Label(new Rect((tool_corner_x + 3 * tool_cell_width) / 1000f * Main.width, (tool_corner_y + i * tool_cell_height) / 1000f * Main.height, 110f / 1000f * Main.width, 25f / 1000f * Main.height), Main.ToolStringGet(CooSystem_script.wear_D[Main.number + i]), Main.sty_SmallNum);
        }

        GUI.Label(new Rect((Main.corner_px + 11.5f) / 1000f * Main.width, (Main.corner_py + 220f) / 1000f * Main.height, 150f / 1000f * Main.width, 25f / 1000f * Main.height), "相 对 坐 标   X", Main.sty_PosSmallWord);
        GUI.Label(new Rect((Main.corner_px + 170f) / 1000f * Main.width, (Main.corner_py + 220f) / 1000f * Main.height, 110f / 1000f * Main.width, 25f / 1000f * Main.height), Main.CooStringFormat(CooSystem_script.relative_pos.x), Main.sty_SmallNum);
        GUI.Label(new Rect((Main.corner_px + 330f) / 1000f * Main.width, (Main.corner_py + 220f) / 1000f * Main.height, 150f / 1000f * Main.width, 25f / 1000f * Main.height), "Y", Main.sty_PosSmallWord);
        GUI.Label(new Rect((Main.corner_px + 365f) / 1000f * Main.width, (Main.corner_py + 220f) / 1000f * Main.height, 110f / 1000f * Main.width, 25f / 1000f * Main.height), Main.CooStringFormat(CooSystem_script.relative_pos.y), Main.sty_SmallNum);
        GUI.Label(new Rect((Main.corner_px + 130f) / 1000f * Main.width, (Main.corner_py + 245f) / 1000f * Main.height, 150f / 1000f * Main.width, 25f / 1000f * Main.height), "Z", Main.sty_PosSmallWord);
        GUI.Label(new Rect((Main.corner_px + 170f) / 1000f * Main.width, (Main.corner_py + 245f) / 1000f * Main.height, 110f / 1000f * Main.width, 25f / 1000f * Main.height), Main.CooStringFormat(CooSystem_script.relative_pos.z), Main.sty_SmallNum);
        if (Main.OffSetOne)
        {
            Main.sty_BottomButton_1.normal.background = Main.t2d_BottomButton_d;
            Main.sty_BottomButton_2.normal.background = Main.t2d_BottomButton_u;
            Main.sty_BottomButton_3.normal.background = Main.t2d_BottomButton_u;
            Main.sty_BottomButton_4.normal.background = Main.t2d_BottomButton_u;
            Main.sty_BottomButton_5.normal.background = Main.t2d_BottomButton_u;
            GUI.Label(new Rect((Main.corner_px + 40f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 70f / 1000f * Main.width, 25f / 1000f * Main.height), "刀 偏", Main.sty_BottomChooseMenu);
            GUI.Label(new Rect((Main.corner_px + 133f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "设 定", Main.sty_BottomChooseMenu);
            GUI.Label(new Rect((Main.corner_px + 216f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "坐标系", Main.sty_BottomChooseMenu);
            GUI.Label(new Rect((Main.corner_px + 385f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "(操 作)", Main.sty_BottomChooseMenu);
            GUI.Label(new Rect((Main.corner_px + 481f) / 1000f * Main.width, (Main.corner_py + 349f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "+", Main.sty_BottomChooseMenu);
        }
        else if (Main.OffSetTwo)
        {
            Main.sty_BottomButton_1.normal.background = Main.t2d_BottomButton_u;
            Main.sty_BottomButton_2.normal.background = Main.t2d_BottomButton_u;
            Main.sty_BottomButton_3.normal.background = Main.t2d_BottomButton_u;
            Main.sty_BottomButton_4.normal.background = Main.t2d_BottomButton_u;
            Main.sty_BottomButton_5.normal.background = Main.t2d_BottomButton_u;
            GUI.Label(new Rect((Main.corner_px + 2f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "<", Main.sty_BottomChooseMenu);
            GUI.Label(new Rect((Main.corner_px + 34f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 70f / 1000f * Main.width, 25f / 1000f * Main.height), "No检索", Main.sty_BottomChooseMenu);
            GUI.Label(new Rect((Main.corner_px + 222f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "C输入", Main.sty_BottomChooseMenu);
            GUI.Label(new Rect((Main.corner_px + 308f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "+输入", Main.sty_BottomChooseMenu);
            GUI.Label(new Rect((Main.corner_px + 408f) / 1000f * Main.width, (Main.corner_py + 348f) / 1000f * Main.height, 500f / 1000f * Main.width, 300f / 1000f * Main.height), "输 入", Main.sty_BottomChooseMenu);
        }
    }