MCPcopy Create free account
hub / github.com/BohemiaInteractive/CWR / OnButtonClicked

Method OnButtonClicked

engine/Poseidon/Game/Chat.cpp:807–829  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

805void SendRadioChatWave(ChatChannel channel, NetworkObject* object, RString wave, AIUnit* sender, RString senderName)
806{
807 if (GetNetworkManager().GetGameState() < NGSPlay)
808 {
809 return;
810 }
811 RefArray<NetworkObject> units;
812 WhatUnits(units, channel, object);
813 if (channel == CCGlobal || units.Size() > 0)
814 {
815 GetNetworkManager().RadioChatWave(channel, units, wave, sender, senderName);
816 }
817}
818
819// Sends a mission radio message (wave) on the given channel.
820void SendRadioChatWave(ChatChannel channel, RString wave, AIUnit* sender, RString senderName)
821{
822 if (GetNetworkManager().GetGameState() < NGSPlay)
823 {
824 return;
825 }
826 RefArray<NetworkObject> units;
827 WhatUnits(sender, units, channel);
828 if (channel == CCGlobal || units.Size() > 0)
829 {
830 GetNetworkManager().RadioChatWave(channel, units, wave, sender, senderName);
831 }
832}

Calls 4

GetCtrlFunction · 0.85
ActualChatChannelFunction · 0.85
SendChatFunction · 0.70
GetTextMethod · 0.45

Tested by

no test coverage detected