Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // CVARINFO START
- user string pro_authkey = "none";
- // CVARINFO END
- bool playerLoggedIn[64];
- str playerAuthKey[64];
- // ACS START
- SCRIPT "Player Enter Auth" ENTER
- {
- str authKey = GetUserCVarString(PlayerNumber(), "pro_authkey");
- if(!StrIcmp(authKey, "none"))
- {
- // Generate Auth Key and register player
- str generatedAuthKey;
- SetUserCVarString(PlayerNumber(), "pro_authkey", generatedAuthKey);
- authKey = generatedAuthKey;
- }
- // Log player in here checking if the auth key matches, if it does store it
- playerLoggedIn[64] = true;
- playerAuthKey[PlayerNumber()] = authKey;
- // Use those arrays from now on to query stuff to prevent players from modifying pro_authkey CVar and fucking shit up
- }
- // ACS END
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement