private void CmdSetSummary(RoundSummary.Summary sum, int posttime) { if (base.isServer) { this.CallRpcSetSummary(sum, posttime); } }
public static void _WriteSummary_RoundSummary(NetworkWriter writer, RoundSummary.Summary value) { writer.WritePackedUInt32((uint)value.classD_escaped); writer.WritePackedUInt32((uint)value.classD_start); writer.WritePackedUInt32((uint)value.scientists_escaped); writer.WritePackedUInt32((uint)value.scientists_start); writer.WritePackedUInt32((uint)value.scp_frags); writer.WritePackedUInt32((uint)value.scp_start); writer.WritePackedUInt32((uint)value.scp_alive); writer.WritePackedUInt32((uint)value.scp_nozombies); writer.Write(value.warheadDetonated); }
public void CallRpcSetSummary(RoundSummary.Summary sum, int posttime) { if (!NetworkServer.active) { Debug.LogError("RPC Function RpcSetSummary called on client."); return; } NetworkWriter networkWriter = new NetworkWriter(); networkWriter.Write(0); networkWriter.Write((short)((ushort)2)); networkWriter.WritePackedUInt32((uint)RoundSummary.kRpcRpcSetSummary); networkWriter.Write(base.GetComponent <NetworkIdentity>().netId); GeneratedNetworkCode._WriteSummary_RoundSummary(networkWriter, sum); networkWriter.WritePackedUInt32((uint)posttime); this.SendRPCInternal(networkWriter, 15, "RpcSetSummary"); }
public void CallCmdSetSummary(RoundSummary.Summary sum, int posttime) { if (!NetworkClient.active) { Debug.LogError("Command function CmdSetSummary called on server."); return; } if (base.isServer) { this.CmdSetSummary(sum, posttime); return; } NetworkWriter networkWriter = new NetworkWriter(); networkWriter.Write(0); networkWriter.Write((short)((ushort)5)); networkWriter.WritePackedUInt32((uint)RoundSummary.kCmdCmdSetSummary); networkWriter.Write(base.GetComponent <NetworkIdentity>().netId); GeneratedNetworkCode._WriteSummary_RoundSummary(networkWriter, sum); networkWriter.WritePackedUInt32((uint)posttime); base.SendCommandInternal(networkWriter, 15, "CmdSetSummary"); }
public void RpcSetSummary(RoundSummary.Summary sum, int posttime) { Radio.roundEnded = true; string text = string.Empty; string text2 = text; text = string.Concat(new object[] { text2, "<color=#ff0000>", sum.classD_escaped, "/", sum.classD_start, "</color> ", TranslationReader.Get("Legancy_Interfaces", 3), "\n" }); text2 = text; text = string.Concat(new object[] { text2, "<color=#ff0000>", sum.scientists_escaped, "/", sum.scientists_start, "</color> ", TranslationReader.Get("Legancy_Interfaces", 4), "\n" }); text2 = text; text = string.Concat(new object[] { text2, "<color=#ff0000>", sum.scp_frags, "</color> ", TranslationReader.Get("Legancy_Interfaces", 5), "\n" }); text2 = text; text = string.Concat(new object[] { text2, "<color=#ff0000>", Mathf.Clamp(sum.scp_start - sum.scp_alive, 0, sum.scp_start), "/", sum.scp_start, "</color> ", TranslationReader.Get("Legancy_Interfaces", 6), "\n" }); text2 = text; text = string.Concat(new string[] { text2, TranslationReader.Get("Legancy_Interfaces", 7), ": <color=#ff0000>", (!sum.warheadDetonated) ? TranslationReader.Get("Legancy_Interfaces", 9) : TranslationReader.Get("Legancy_Interfaces", 8), "</color>\n\n" }); text += TranslationReader.Get("Legancy_Interfaces", 10).Replace("[time]", posttime.ToString()); GameObject gameObject = UserMainInterface.singleton.summary; gameObject.SetActive(true); TextMeshProUGUI component = GameObject.FindGameObjectWithTag("Summary").GetComponent <TextMeshProUGUI>(); component.text = text; }