COMMAND:ouninvite(playerid, params[]) { if(PlayerInfo[playerid][ranklvl] != 0) return SendClientError(playerid, CANT_USE_CMD); if(PlayerInfo[playerid][playerteam] == CIV) return SendClientError(playerid, CANT_USE_CMD); new iPlayer[ MAX_PLAYER_NAME ]; if( sscanf ( params, "s", iPlayer)) return SCP(playerid, "[Exact_Name]"); if(GetPlayerId(iPlayer) != INVALID_PLAYER_ID) return SendClientError(playerid, "That player is connected! Use /uninvite!"); if(!AccountExist(iPlayer)) return SendClientError(playerid, "Account is not registered!"); new iQuery[128]; mysql_format(MySQLPipeline, iQuery, sizeof(iQuery), "SELECT `FactionID` FROM `PlayerInfo` WHERE `PlayerName` = '%e'", iPlayer); mysql_tquery(MySQLPipeline, iQuery, "OfflineUninviteResponse", "ds", playerid, iPlayer); SendClientMessage(playerid,COLOR_WHITE,iQuery); return 1; }
forward OfflineUninviteResponse(playerid, iPlayer); public OfflineUninviteResponse(playerid, iPlayer) { new rows, fields; cache_get_data(rows, fields, MySQLPipeline); if(!rows) return SendClientError(playerid, "Player not found in the database!"); else { new iQuery[228], playerFaction; playerFaction = cache_get_field_content_int(0, "FactionID", MySQLPipeline); if(playerFaction != PlayerInfo[playerid][playerteam]) return SendClientError(playerid, "That player is not in your faction!"); mysql_format(MySQLPipeline, iQuery, sizeof(iQuery), "UPDATE `PlayerInfo` SET `Tier` = -1, `RankName` = 'CIV', `FactionID` = 255, `FactionPay` = 0 WHERE `PlayerName` = '%e'", iPlayer); mysql_tquery(MySQLPipeline, iQuery); SendClientMessage(playerid,COLOR_WHITE,iQuery); format(iStr, sizeof(iStr), "# [%s] %s has offline-uninvited %s.", GetPlayerFactionName(playerid), RPName(playerid), iPlayer); SendClientMessageToTeam(PlayerInfo[playerid][playerteam],iStr,COLOR_PLAYER_VLIGHTBLUE); format(iStr, sizeof(iStr),"10[O-UNINVITE] %s has been offline-kicked from %s.", iPlayer, GetPlayerFactionName(playerid)); iEcho(iStr); } return 1; }
if( sscanf ( params, "s[24]", iPlayer)) return SCP(playerid, "[Exact_Name]");
Could you be more specific @Vince show me the line of the "i" cuz i cant really get you kinda bad with my english.
|