diff --git a/VIP_Test/scripting/VIP_Test.sp b/VIP_Test/scripting/VIP_Test.sp index 0fb48ce0..311d6988 100644 --- a/VIP_Test/scripting/VIP_Test.sp +++ b/VIP_Test/scripting/VIP_Test.sp @@ -1,5 +1,6 @@ #pragma semicolon 1 +#include #include #pragma newdecls required @@ -27,7 +28,7 @@ public Plugin myinfo = name = "UNLOZE_VIP_Test", author = "Neon", description = "", - version = "2.0", + version = "2.1", url = "https://steamcommunity.com/id/n3ontm" } @@ -171,17 +172,23 @@ public void OnClientPostAdminFilter(int client) //---------------------------------------------------------------------------------------------------- public Action Command_VIP(int client, int iArgs) { - if (!IsValidClient(client)) - return Plugin_Handled; + if (!IsValidClient(client)) + return Plugin_Handled; - char sSteamID[32]; - GetClientAuthId(client, AuthId_Steam2, sSteamID, sizeof(sSteamID)); + if (!PM_IsPlayerSteam(client)) + { + PrintToChat(client, "Nosteam cant use test vip anymore."); + return Plugin_Handled; + } - char sQuery[255]; - Format(sQuery, sizeof(sQuery), "SELECT * FROM testvip_table WHERE steam_auth = '%s'", sSteamID); - SQL_TQuery(g_hDatabase, TQueryCBCommand, sQuery, GetClientUserId(client)); + char sSteamID[32]; + GetClientAuthId(client, AuthId_Steam2, sSteamID, sizeof(sSteamID)); - return Plugin_Handled; + char sQuery[255]; + Format(sQuery, sizeof(sQuery), "SELECT * FROM testvip_table WHERE steam_auth = '%s'", sSteamID); + SQL_TQuery(g_hDatabase, TQueryCBCommand, sQuery, GetClientUserId(client)); + + return Plugin_Handled; } //---------------------------------------------------------------------------------------------------- @@ -295,4 +302,4 @@ public bool IsVIP(int client) } } return false; -} \ No newline at end of file +}