public void CmdReportUnlock(UnlockableIndex unlockIndex) { Debug.LogFormat("NetworkUser.CmdReportUnlock({0})", new object[] { unlockIndex }); UnlockableDef unlockableDef = UnlockableCatalog.GetUnlockableDef(unlockIndex); if (unlockableDef != null) { this.ServerHandleUnlock(unlockableDef); } }
public void SendServerUnlockables() { if (!NetworkClient.active) { Debug.LogWarning("[Client] function 'System.Void RoR2.NetworkUser::SendServerUnlockables()' called on server"); return; } if (this.localUser != null) { int unlockableCount = this.localUser.userProfile.statSheet.GetUnlockableCount(); UnlockableIndex[] array = new UnlockableIndex[unlockableCount]; for (int i = 0; i < unlockableCount; i++) { array[i] = this.localUser.userProfile.statSheet.GetUnlockableIndex(i); } this.CallCmdSendNewUnlockables(array); } }
// Token: 0x0600127F RID: 4735 RVA: 0x0005A9C8 File Offset: 0x00058BC8 public void CallCmdReportUnlock(UnlockableIndex unlockIndex) { if (!NetworkClient.active) { Debug.LogError("Command function CmdReportUnlock called on server."); return; } if (base.isServer) { this.CmdReportUnlock(unlockIndex); return; } NetworkWriter networkWriter = new NetworkWriter(); networkWriter.Write(0); networkWriter.Write((short)((ushort)5)); networkWriter.WritePackedUInt32((uint)NetworkUser.kCmdCmdReportUnlock); networkWriter.Write(base.GetComponent <NetworkIdentity>().netId); GeneratedNetworkCode._WriteUnlockableIndex_None(networkWriter, unlockIndex); base.SendCommandInternal(networkWriter, 0, "CmdReportUnlock"); }
// Token: 0x060009BD RID: 2493 RVA: 0x00030D1C File Offset: 0x0002EF1C public static void Write(this NetworkWriter writer, UnlockableIndex index) { writer.Write((byte)index.internalValue); }
// Token: 0x06001B2B RID: 6955 RVA: 0x00072CF8 File Offset: 0x00070EF8 public static UnlockableDef GetUnlockableDef(UnlockableIndex index) { return(UnlockableCatalog.indexToDefTable[index.value]); }