NSClient: add void SetInfoKeyFloat(string, float)
and float GetInfoKeyFloat(string)
methods
This commit is contained in:
parent
4a8f4a6082
commit
08cac51d5f
2 changed files with 17 additions and 0 deletions
|
@ -71,6 +71,11 @@ public:
|
|||
/** Get the string value of an InfoKey. */
|
||||
nonvirtual string GetInfoKey(string);
|
||||
|
||||
/** Floating point based version of SetInfoKey(). */
|
||||
nonvirtual void SetInfoKeyFloat(string, float);
|
||||
/** Floating point based version of GetInfoKey(). */
|
||||
nonvirtual float GetInfoKeyFloat(string);
|
||||
|
||||
/* overrides */
|
||||
virtual void Save(float);
|
||||
virtual void Restore(string,string);
|
||||
|
|
|
@ -75,6 +75,18 @@ NSClient::GetInfoKey(string strKey)
|
|||
return infokey(this, strKey);
|
||||
}
|
||||
|
||||
void
|
||||
NSClient::SetInfoKeyFloat(string strKey, float floatValue)
|
||||
{
|
||||
forceinfokey(this, strKey, ftos(floatValue));
|
||||
}
|
||||
|
||||
float
|
||||
NSClient::GetInfoKeyFloat(string strKey)
|
||||
{
|
||||
return infokeyf(this, strKey);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
void
|
||||
|
|
Loading…
Reference in a new issue