예제 #1
0
 //助手设置
 void OnSetBtn()
 {
     if (mLbSet.text == "Set")
     {
         ServerAdministrator.RequestAddAssistants(_mUserAdmin.Id);
     }
     else
     {
         ServerAdministrator.RequestDeleteAssistants(_mUserAdmin.Id);
     }
 }
예제 #2
0
    void OnAssistantSelected(bool selected)
    {
        if (null == PlayerNetwork.mainPlayer)
        {
            return;
        }

        if (ServerAdministrator.IsAssistant(mRoleId) == selected)
        {
            return;
        }

        if (selected)
        {
            ServerAdministrator.RequestAddAssistants(mRoleId);
        }
        else
        {
            ServerAdministrator.RequestDeleteAssistants(mRoleId);
        }
    }