找传奇、传世资源到传世资源站!

棋牌教程 网狐房卡麻将源码修改默认选择游戏玩法

2021.5.16 技术教程 1245 编辑

该如何修改默认选中抓鸟个数呢,今天我教大家怎么修改。此次修改需要修改源码文件HNPrivateScenceHN.cpp

    WidgetManager::addButtonCB("Button_GameRule0",this,button_selector(HNPrivateScenceHN::ButtonGameRule));

    WidgetManager::addButtonCB("Button_GameRule1",this,button_selector(HNPrivateScenceHN::ButtonGameRule));

    WidgetManager::addButtonCB("Button_GameRule2",this,button_selector(HNPrivateScenceHN::ButtonGameRule));

    WidgetManager::addButtonCB("Button_GameRule3",this,button_selector(HNPrivateScenceHN::ButtonGameRule));

    WidgetManager::addButtonCB("Button_GameRule4",this,button_selector(HNPrivateScenceHN::ButtonGameRule));

    WidgetManager::addButtonCB("Button_GameRule5",this,button_selector(HNPrivateScenceHN::ButtonGameRule));

    WidgetManager::addButtonCB("Button_GameRule6",this,button_selector(HNPrivateScenceHN::ButtonGameRule));

    WidgetFun::setChecked(this,"PlaneCreate_CS:Button_GameRule6",true);

    WidgetManager::addButtonCB("Button_GameRule8",this,button_selector(HNPrivateScenceHN::ButtonGameRule));

    WidgetManager::addButtonCB("Button_GameType0",this,button_selector(HNPrivateScenceHN::Button_GameType));

    WidgetManager::addButtonCB("Button_GameType1",this,button_selector(HNPrivateScenceHN::Button_GameType));

    setPlayerCoutIdex(0); //这里是改默认局数

    setGameRuleIdex(GAME_TYPE_ZZ_QIANGGANGHU);   

    setGameRuleIdex(GAME_TYPE_ZZ_HONGZHONG);

    setGameRuleIdex(GAME_TYPE_ZZ_ZIMOHU);

    setGameRuleIdex(GAME_TYPE_ZZ_ZHANIAO4);

       return true;

        //就是在这个位置改默认的勾选中

        //你这里已经改掉了把 默认就是转转  抢杠胡  红中  自摸胡  4鸟

修改完之后重新编译就可以了。

评论

发表评论必须先登陆, 您可以 登陆 或者 注册新账号 !


在线咨询: 问题反馈
客服QQ:174666394

有问题请留言,看到后及时答复