public string getStringVariable(ushort clientID, ClientProperties property) { IntPtr valuePtr = IntPtr.Zero; uint result = Error.ok; if ((result = GetClientVariableAsString(_serverID, clientID, property, out valuePtr)) != Error.ok) { notifyError(string.Format("Error getting variable: {0}", property.ToString())); return(string.Empty); } return(getStringFromPointer(valuePtr)); }
public string getStringVariable(ushort clientID, ClientProperties property) { IntPtr valuePtr = IntPtr.Zero; uint result = Error.ok; if ((result = GetClientVariableAsString(_serverID, clientID, property, out valuePtr)) != Error.ok) { notifyError(string.Format("Error getting variable: {0}", property.ToString())); return string.Empty; } return getStringFromPointer(valuePtr); }
public int getIntVariable(ClientProperties property) { int value = 0; if (GetClientSelfVariableAsInt(_connectedServerID, property, out value) != Error.ok) { notifyError(string.Format("Error getting variable: {0}", property.ToString())); return 0; } return value; }
public bool setIntVariable(ulong serverID, ulong channelID, ClientProperties property, int value) { if (SetClientSelfVariableAsInt(_connectedServerID, property, value) != Error.ok) { notifyError(string.Format("Error setting variable: {0}", property.ToString())); return false; } return true; }