| 1935 | SendMsg(&msg, NMFGuaranteed); |
| 1936 | } |
| 1937 | |
| 1938 | void NetworkClient::PublicVariable(RString name) |
| 1939 | { |
| 1940 | GameState* gstate = GWorld->GetGameState(); |
| 1941 | GameValuePar var = gstate->VarGet(name); |
| 1942 | if (var.GetNil()) |
| 1943 | { |
| 1944 | return; |
| 1945 | } |
| 1946 | |
| 1947 | QOStream out; |
| 1948 | if (!Poseidon::SerializeScriptValue(out, var)) |
| 1949 | { |
| 1950 | Fail("publicVariable: unsupported type"); |
| 1951 | return; |
| 1952 | } |
| 1953 | |
| 1954 | PublicVariableMessage msg; |
| 1955 | msg._name = name; |
| 1956 | int size = out.pcount(); |
| 1957 | msg._value.Resize(size); |
| 1958 | memcpy(msg._value.Data(), out.str(), size); |
| 1959 | SendMsg(&msg, NMFGuaranteed); |
| 1960 | } |
| 1961 | |
| 1962 | void NetworkClient::GroupSynchronization(AIGroup* grp, int synchronization, bool active) |
nothing calls this directly
no test coverage detected