diff options
author | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2022-11-21 00:00:02 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-21 00:00:02 +0000 |
commit | 4730389c3bc0e750eab2ecdc3fd9a781f70e12a3 (patch) | |
tree | a27748f5350aedb41d6402bea250e5d16f717bda /Northstar.CustomServers/mod/scripts/vscripts | |
parent | 3f80f07ac14dc210261601e7c59968b5d2c38e2c (diff) | |
download | NorthstarMods-4730389c3bc0e750eab2ecdc3fd9a781f70e12a3.tar.gz NorthstarMods-4730389c3bc0e750eab2ecdc3fd9a781f70e12a3.zip |
Add entity functions for reading userinfo cvars to CPlayer class (#521)
* add entity functions for reading userinfo cvars to CPlayer class
* fix formatting
* update to use new functions from launcher pr
Diffstat (limited to 'Northstar.CustomServers/mod/scripts/vscripts')
-rw-r--r-- | Northstar.CustomServers/mod/scripts/vscripts/class/cplayer.nut | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/class/cplayer.nut b/Northstar.CustomServers/mod/scripts/vscripts/class/cplayer.nut index b9f8f7eb..19c6b6df 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/class/cplayer.nut +++ b/Northstar.CustomServers/mod/scripts/vscripts/class/cplayer.nut @@ -328,6 +328,26 @@ function CodeCallback_RegisterClass_CPlayer() } } } + + function CPlayer::GetUserInfoString( key, defaultValue = "" ) + { + return GetUserInfoKVString_Internal( this, key, defaultValue ) + } + + function CPlayer::GetUserInfoInt( key, defaultValue = 0 ) + { + return GetUserInfoKVInt_Internal( this, key, defaultValue ) + } + + function CPlayer::GetUserInfoFloat( key, defaultValue = 0 ) + { + return GetUserInfoKVFloat_Internal( this, key, defaultValue ) + } + + function CPlayer::GetUserInfoBool( key, defaultValue = false ) + { + return GetUserInfoKVBool_Internal( this, key, defaultValue ) + } } void function PlayerDropsScriptedItems( entity player ) |