unity添加GM命令按钮

using com.game.vo;

using Com.Game.Module.Chat;

using System.Collections;

using System.Collections.Generic;

using UnityEditor;

using UnityEngine;


public class GM : MonoBehaviour {


    //[MenuItem("GM/super_long")]

    //static void ShowWindow()

    //{

    //    ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#super_long");

    //}

    [MenuItem("GM/1")]

    static void ShowWindow1()

    {

        ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#gold 10000000");

        ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#diam 10000000");

        ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#lvl 500");

        for (int i = 1; i <= 10; i++)

        {

            int id = 100009090 + i * 1000000 + MeVo.instance.job * 100000;

            ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#goods " + id);

        }

        ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#tk 100007");

        ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#mv 10000");

        //ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#chapter 6");

        //ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#kick");

}

[MenuItem("GM/2")]

static void ShowWindow2()

{

    ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#sc_start");


    }

[MenuItem("GM/3")]

static void ShowWindow3()

{

ChatMode.Instance.SendPublicMsg((byte)ChatType.World, "#bubble_boss");


}

}

转载于:https://www.jianshu.com/p/80183eb5c5a5

猜你喜欢

转载自blog.csdn.net/weixin_34238642/article/details/91065521
今日推荐