Facebook
From mieszi, 5 Years ago, written in PHP.
Embed
Download Paste or View Raw
Hits: 364
  1. #include <sourcemod>
  2. #include <sdktools>
  3. #include <sdktools_sound>
  4. #include <cstrike>
  5. #include <clientprefs>
  6. #include <smlib>
  7. #include <sdkhooks>
  8. #include <csgocolors>
  9.  
  10. #pragma semicolon 1
  11.  
  12. new bool:g_Ivisivel[MAXPLAYERS+1] = {false, ...};
  13. new bool:g_Godmode[MAXPLAYERS+1] = {false, ...};
  14. new bool:poison[MAXPLAYERS+1] = {false, ...};
  15. new bool:vampire[MAXPLAYERS+1] = {false, ...};
  16. new bool:super_faca[MAXPLAYERS+1] = {false, ...};
  17. new bool:view[MAXPLAYERS+1] = {false, ...};
  18. new bool:fogo[MAXPLAYERS+1] = {false, ...};
  19. new bool:AWP[MAXPLAYERS+1] = {true,...};
  20. new bool:EAGLE[MAXPLAYERS+1] = {true, ...};
  21. new bool:bhop[MAXPLAYERS+1] = {false, ...};
  22.  
  23. #define VERSION "Private version"
  24.  
  25. new g_iCreditos[MAXPLAYERS+1];
  26.  
  27. new iEnt;
  28. new String:EntityList[][] = {
  29.        
  30.         "func_door",
  31.         "func_rotating",
  32.         "func_walltoggle",
  33.     "func_breakable",
  34.         "func_door_rotating",
  35.         "func_movelinear",
  36.         "prop_door",
  37.         "prop_door_rotating",
  38.         "func_tracktrain",
  39.         "func_elevator",
  40.         "\0"
  41. };
  42.  
  43.  
  44. new Handle:cvarCreditosMax = INVALID_HANDLE;
  45. new Handle:cvarCreditosKill_CT = INVALID_HANDLE;
  46. new Handle:cvarCreditosKill_T = INVALID_HANDLE;
  47. new Handle:cvarCreditos_LR = INVALID_HANDLE;
  48. new Handle:cvarCreditosKill_CT_VIP = INVALID_HANDLE;
  49. new Handle:cvarCreditosKill_T_VIP = INVALID_HANDLE;
  50. new Handle:cvarCreditos_LR_VIP = INVALID_HANDLE;
  51. new Handle:cvarCreditosSave = INVALID_HANDLE;
  52. new Handle:cvarTronly = INVALID_HANDLE;
  53. new Handle:cvarEnableRevive = INVALID_HANDLE;
  54. new Handle:cvarSpawnMsg = INVALID_HANDLE;
  55. new Handle:cvarCreditsOnWarmup = INVALID_HANDLE;
  56. new Handle:cvarMinPlayersToGetCredits = INVALID_HANDLE;
  57. new Handle:cvar_1;
  58. new Handle:cvar_2;
  59. new Handle:cvar_3;
  60. new Handle:cvar_4;
  61. new Handle:cvar_5;
  62. new Handle:cvar_6;
  63. new Handle:cvar_7;
  64. new Handle:cvar_8;
  65. new Handle:cvar_9;
  66. new Handle:cvar_10;
  67. new Handle:cvar_11;
  68. new Handle:cvar_12;
  69. new Handle:cvar_14;
  70. new Handle:cvar_15;
  71. new Handle:cvar_16;
  72. new Handle:cvar_17;
  73. new Handle:cvar_18;
  74.  
  75.  
  76. //new Handle:cvarRoundCreditos = INVALID_HANDLE;
  77. //new Handle:cvarCrInterval = INVALID_HANDLE;
  78.  
  79. new Handle:c_GameCreditos = INVALID_HANDLE;
  80.  
  81. new g_sprite;
  82. new g_HaloSprite;
  83.  
  84.  
  85. public Plugin:myinfo =
  86. {
  87.     name = "Shop Jail",
  88.     author = "Dk--",
  89.     description = "Comprar itens no shop jailbreak",
  90.     version = VERSION,
  91. };
  92.  
  93. public OnPluginStart()
  94. {
  95.  
  96.         LoadTranslations("common.phrases");
  97.         LoadTranslations("jail_shop.phrases");
  98.         c_GameCreditos = RegClientCookie("Creditos", "Creditos", CookieAccess_Private);
  99.  
  100.         // ======================================================================
  101.  
  102.         HookEvent("player_spawn", PlayerSpawn);
  103.         HookEvent("player_death", PlayerDeath);
  104.         HookEvent("smokegrenade_detonate", Event_SmokeGrenadeDetonate, EventHookMode_Post);
  105.         HookEvent("smokegrenade_detonate", Event_SmokeGrenadeDetonate2, EventHookMode_Post);
  106.         HookEvent("player_hurt",EventPlayerHurt, EventHookMode_Pre);
  107.         HookEvent("round_end", Event_OnRoundEnd);
  108.        
  109.         // ======================================================================
  110.  
  111.         RegConsoleCmd("sm_shop", SHOPMENU);
  112.         RegConsoleCmd("sm_credits", Creditos);
  113.         RegConsoleCmd("sm_gift", Command_SendCredits);
  114.         RegConsoleCmd("sm_reviver", Reviver);
  115.         RegConsoleCmd("sm_vercreditos", Command_ShowCredits);
  116.        
  117.         RegAdminCmd("sm_give", SetCreditos, ADMFLAG_ROOT);
  118.         RegAdminCmd("sm_set", SetCreditos2, ADMFLAG_ROOT);
  119.         // ======================================================================
  120.  
  121.         // ======================================================================
  122.  
  123.         cvarCreditosMax = CreateConVar("shop_creditos_maximo", "500000", "Maxim of credits for player");
  124.         cvarCreditosKill_T = CreateConVar("shop_creditos_por_kill_t", "150", "Amount of credits for kill ( prisioner )");
  125.         cvarCreditosKill_CT = CreateConVar("shop_creditos_por_kill_ct", "15", "Amount of credits for kill ( guard )");
  126.         cvarCreditos_LR = CreateConVar("shop_creditos_por_kill_lr", "300", "Amount of credits for the last player");
  127.         cvarCreditosKill_T_VIP = CreateConVar("shop_creditos_por_kill_t_vip", "150", "Amount of credits for kill ( prisioner ) for VIP (flag a)");
  128.         cvarCreditosKill_CT_VIP = CreateConVar("shop_creditos_por_kill_ct_vip", "15", "Amount of credits for kill ( guard ) for VIP (flag a)");
  129.         cvarCreditos_LR_VIP = CreateConVar("shop_creditos_por_kill_lr_vip", "300", "Amount of credits for the last player for VIP (flag a)");
  130.         cvarSpawnMsg = CreateConVar("shop_spawnmessages", "1", "Messages on spawn", FCVAR_NONE, true, 0.0, true, 1.0);
  131.         cvarCreditosSave = CreateConVar("shop_creditos_save", "1", "Save or not credits on player disconnect", FCVAR_NONE, true, 0.0, true, 1.0);
  132.         cvarTronly = CreateConVar("shop_terrorist_only", "1", "Menu for only prisioners", FCVAR_NONE, true, 0.0, true, 1.0);
  133.         cvarEnableRevive = CreateConVar("shop_ativar_revive", "1", "Enable/Disble revive", FCVAR_NONE, true, 0.0, true, 1.0);
  134.         cvarCreditsOnWarmup = CreateConVar("shop_warmupcredits", "0", "Should players get credits on warmup?");
  135.         cvarMinPlayersToGetCredits = CreateConVar("shop_minplayers", "4", "Minimum players to get credits");
  136.                
  137.         cvar_1 = CreateConVar("preco_01", "7000", "Price of item (invisible)");
  138.         cvar_2 = CreateConVar("preco_02", "2000", "Price of item (awp)");
  139.         cvar_3 = CreateConVar("preco_03", "7000", "Price of item (imortal)");
  140.         cvar_4 = CreateConVar("preco_04", "800", "Price of item (open jails)");
  141.         cvar_5 = CreateConVar("preco_05", "4000", "Price of item (more fast)");
  142.         cvar_6 = CreateConVar("preco_06", "3500", "Price of item (hp)");
  143.         cvar_7 = CreateConVar("preco_07", "2000", "Price of item (eagle)");
  144.         cvar_8 = CreateConVar("preco_08", "1500", "Price of item (super knife)");
  145.         cvar_9 = CreateConVar("preco_09", "50", "Price of item (healing)");
  146.         cvar_10 = CreateConVar("preco_10", "650", "Price of item (molotov)");
  147.         cvar_11 = CreateConVar("preco_11", "7000", "Price of item (skin)");
  148.         cvar_12 = CreateConVar("preco_12", "1000", "Price of item (poison smoke)");
  149.         cvar_14 = CreateConVar("preco_14", "8000", "Price of item (smoke teleport)");
  150.         cvar_15 = CreateConVar("preco_15", "8000", "Price of item (respawn)");
  151.         cvar_16 = CreateConVar("preco_16", "2000", "Price of item (he with fire)");
  152.         cvar_17 = CreateConVar("preco_17", "5000", "Price of item (bhop)");
  153.         cvar_18 = CreateConVar("preco_18", "2500", "Price of item (low gravity)");
  154.        
  155.        
  156.         if(GetConVarBool(cvarCreditosSave))
  157.         {
  158.                 for(new client = 1; client <= MaxClients; client++)
  159.                 {
  160.                         if(IsClientInGame(client))
  161.                         {
  162.                                 if(AreClientCookiesCached(client))
  163.                                 {
  164.                                         OnClientCookiesCached(client);
  165.                                 }
  166.                         }
  167.                 }
  168.         }
  169.        
  170.         AutoExecConfig(true, "sm_shopjail");
  171.        
  172. }
  173.  
  174.  
  175. public OnPluginEnd()
  176. {
  177.         if(!GetConVarBool(cvarCreditosSave))
  178.                 return;
  179.  
  180.         for(new client = 1; client <= MaxClients; client++)
  181.         {
  182.                 if(IsClientInGame(client))
  183.                 {
  184.                         OnClientDisconnect(client);
  185.                 }
  186.         }
  187. }
  188.  
  189.  
  190. public OnClientCookiesCached(client)
  191. {
  192.         if(!GetConVarBool(cvarCreditosSave))
  193.                 return;
  194.  
  195.         new String:CreditosString[12];
  196.         GetClientCookie(client, c_GameCreditos, CreditosString, sizeof(CreditosString));
  197.         g_iCreditos[client]  = StringToInt(CreditosString);
  198. }  
  199.  
  200. public OnClientDisconnect(client)
  201. {      
  202.         if(!GetConVarBool(cvarCreditosSave))
  203.         {
  204.                 g_iCreditos[client] = 0;
  205.                 return;
  206.         }
  207.        
  208.         if(AreClientCookiesCached(client))
  209.         {
  210.                 new String:CreditosString[12];
  211.                 Format(CreditosString, sizeof(CreditosString), "%i", g_iCreditos[client]);
  212.                 SetClientCookie(client, c_GameCreditos, CreditosString);
  213.         }
  214.        
  215. }
  216.  
  217.  
  218. public OnMapStart()
  219. {
  220.         g_sprite = PrecacheModel("materials/sprites/laserbeam.vmt", true);
  221.         g_HaloSprite = PrecacheModel("materials/sprites/halo.vmt", true);
  222. }
  223.  
  224.  
  225. public Action:MensajesSpawn(Handle:timer, any:client)
  226. {
  227.         if(GetConVarBool(cvarSpawnMsg) && IsClientInGame(client))
  228.         {
  229.                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Kill");
  230.                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Type");
  231.         }
  232. }
  233.  
  234. public Action:PlayerDeath(Handle:event, const String:name[], bool:dontBroadcast)
  235. {
  236.         new attacker = GetClientOfUserId(GetEventInt(event, "attacker"));
  237.         new client = GetClientOfUserId(GetEventInt(event, "userid"));
  238.  
  239.         CreateTimer(2.0, MensajesMuerte, client);
  240.        
  241.        
  242.         if (!attacker)
  243.                 return;
  244.  
  245.         if (attacker == client)
  246.                 return;
  247.  
  248.         if(!GetConVarBool(cvarCreditosKill_CT))
  249.                 return;
  250.        
  251.         if(!GetConVarBool(cvarCreditosKill_T))
  252.                 return;
  253.        
  254.         if(GetAllPlayersCount() >= GetConVarInt(cvarMinPlayersToGetCredits) && (GetConVarInt(cvarCreditsOnWarmup) != 0 || GameRules_GetProp("m_bWarmupPeriod") != 1) )
  255.         {
  256.                 if(GetClientTeam(attacker) == CS_TEAM_CT)
  257.                 {
  258.                         if (IsPlayerReservationAdmin(attacker))
  259.                                 g_iCreditos[attacker] += GetConVarInt(cvarCreditosKill_CT_VIP);
  260.                         else
  261.                                 g_iCreditos[attacker] += GetConVarInt(cvarCreditosKill_CT);
  262.                 }
  263.                
  264.                 if(GetClientTeam(attacker) == CS_TEAM_T)
  265.                 {
  266.                         if (IsPlayerReservationAdmin(attacker))
  267.                                 g_iCreditos[attacker] += GetConVarInt(cvarCreditosKill_T_VIP);
  268.                         else
  269.                                 g_iCreditos[attacker] += GetConVarInt(cvarCreditosKill_T);
  270.                 }
  271.         }
  272.         if(GetAllPlayersCount() >= GetConVarInt(cvarMinPlayersToGetCredits) && (GetConVarInt(cvarCreditsOnWarmup) != 0 || GameRules_GetProp("m_bWarmupPeriod") != 1) )
  273.         {
  274.                 if (g_iCreditos[attacker] < GetConVarInt(cvarCreditosMax))
  275.                 {
  276.                         if(GetClientTeam(attacker) == CS_TEAM_CT)
  277.                         {
  278.                                 if (IsPlayerReservationAdmin(attacker))
  279.                                         CPrintToChat(attacker, "\x0E[ SHOP ] \x04%t","KillCT", g_iCreditos[attacker],GetConVarInt(cvarCreditosKill_CT_VIP));
  280.                                 else
  281.                                         CPrintToChat(attacker, "\x0E[ SHOP ] \x04%t","KillCT", g_iCreditos[attacker],GetConVarInt(cvarCreditosKill_CT));
  282.                         }
  283.                
  284.                         if(GetClientTeam(attacker) == CS_TEAM_T)
  285.                         {
  286.                                 if (IsPlayerReservationAdmin(attacker))
  287.                                         CPrintToChat(attacker, "\x0E[ SHOP ] \x04%t","KillT", g_iCreditos[attacker],GetConVarInt(cvarCreditosKill_T_VIP));
  288.                                 else
  289.                                         CPrintToChat(attacker, "\x0E[ SHOP ] \x04%t","KillT", g_iCreditos[attacker],GetConVarInt(cvarCreditosKill_T));
  290.                         }
  291.                        
  292.                        
  293.                 }
  294.                 else
  295.                 {
  296.                         CPrintToChat(attacker, "\x0E[ SHOP ] \x04%t","Maximo", g_iCreditos[attacker]);
  297.                         g_iCreditos[attacker] = GetConVarInt(cvarCreditosMax);
  298.                 }
  299.         }
  300. }
  301.  
  302. public Action:MensajesMuerte(Handle:timer, any:client)
  303. {
  304.  if (IsClientInGame(client))
  305.  {
  306.         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Reviver4",GetConVarInt(cvar_15));
  307.  }
  308. }
  309.  
  310. public Action:Creditos(client, args)
  311. {
  312.         if(client == 0)
  313.         {
  314.                 PrintToServer("%t","Command is in-game only");
  315.                 return;
  316.         }
  317.         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Creditos", g_iCreditos[client]);
  318. }
  319.  
  320. public Action:SHOPMENU(client,args)
  321. {
  322.         if(GetConVarBool(cvarTronly))
  323.         {
  324.                 if(GetClientTeam(client) != 2)
  325.                 {
  326.                          CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Prisioneiros");
  327.                          return;
  328.                 }
  329.                 else
  330.                 {
  331.                         DID(client);
  332.                 }
  333.         }
  334.         else
  335.         {
  336.                 DID(client);
  337.         }
  338. }
  339.  
  340. public Action:Reviver(client,args)
  341. {
  342.         if(client == 0)
  343.         {
  344.                 PrintToServer("%t","Command is in-game only");
  345.                 return;
  346.         }
  347.        
  348.         if(GetConVarBool(cvarEnableRevive))
  349.         {
  350.                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Ativado");
  351.                 return;
  352.         }
  353.        
  354.         if(GetConVarBool(cvarTronly))
  355.         {
  356.                 if(GetClientTeam(client) != 2)
  357.                 {
  358.                          CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Prisioneiros2");
  359.                          return;
  360.                 }
  361.                 else
  362.                 {
  363.                         if (IsClientInGame(client) && !IsPlayerAlive(client))
  364.                         {
  365.                                 if (g_iCreditos[client] >= GetConVarInt(cvar_15))
  366.                                 {
  367.  
  368.                                         CS_RespawnPlayer(client);
  369.  
  370.                                         g_iCreditos[client] -= GetConVarInt(cvar_15);
  371.  
  372.                                         decl String:nome[32];
  373.                                         GetClientName(client, nome, sizeof(nome));
  374.                                        
  375.                                         CPrintToChatAll("\x0E[ SHOP ] \x04The player\x03 %s \x04has respawned!", nome);
  376.  
  377.                                 }
  378.                                 else
  379.                                 {
  380.                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item reviver", g_iCreditos[client],GetConVarInt(cvar_15));
  381.                                 }
  382.                         }
  383.                         else
  384.                         {
  385.                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Morto");
  386.                         }
  387.                 }
  388.         }
  389.         else
  390.         {
  391.                 if (!IsPlayerAlive(client))
  392.                 {
  393.                         if (g_iCreditos[client] >= GetConVarInt(cvar_15))
  394.                         {
  395.  
  396.                                 CS_RespawnPlayer(client);
  397.  
  398.                                 g_iCreditos[client] -= GetConVarInt(cvar_15);
  399.  
  400.                                 decl String:nome[32];
  401.                                 GetClientName(client, nome, sizeof(nome));
  402.                                
  403.                                
  404.                                 CPrintToChatAll("\x0E[ SHOP ] \x04The player\x03 %s \x04has respawned!", nome);
  405.  
  406.                         }
  407.                         else
  408.                         {
  409.                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item reviver", g_iCreditos[client],GetConVarInt(cvar_15));
  410.                         }
  411.                 }
  412.                 else
  413.                 {
  414.                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Morto");
  415.                 }
  416.         }
  417. }
  418.  
  419.  
  420. public Action:EventPlayerHurt(Handle:event, const String:name[], bool:dontBroadcast)
  421. // ----------------------------------------------------------------------------
  422. {
  423.         new victim = GetClientOfUserId(GetEventInt(event,"userid"));
  424.         new attacker = GetClientOfUserId(GetEventInt(event, "attacker"));
  425.         if(attacker == 0 || !fogo[attacker])
  426.                 return;
  427.  
  428.         if(victim != attacker && attacker !=0 && attacker <MAXPLAYERS){
  429.                 new String:sWeaponUsed[50];
  430.                 GetEventString(event,"weapon",sWeaponUsed,sizeof(sWeaponUsed));
  431.                 if(StrEqual(sWeaponUsed,"hegrenade"))
  432.                 {
  433.                         IgniteEntity(victim, 15.0);
  434.                 }
  435.                
  436.         }
  437. }
  438.  
  439. public Action:Event_SmokeGrenadeDetonate2(Handle:event, const String:name[], bool:dontBroadcast)
  440. {
  441.         new client = GetClientOfUserId(GetEventInt(event, "userid"));
  442.         if(view[client] == true)
  443.         {
  444.                 view[client] = false;
  445.                 if(IsClientInGame(client))
  446.                 SetClientViewEntity(client, client);
  447.                 new Float:origin[3];
  448.  
  449.                 // Dest. location
  450.                 origin[0] = float(GetEventInt(event, "x"));
  451.                 origin[1] = float(GetEventInt(event, "y"));
  452.                 origin[2] = float(GetEventInt(event, "z"));
  453.                
  454.                 //TELEPORT TO PLACE WHERE THE GRENADE WILL EXPLODE!
  455.                 TeleportEntity(client, origin, NULL_VECTOR, NULL_VECTOR);
  456.         }
  457. }
  458.  
  459. public Action:Event_SmokeGrenadeDetonate(Handle:event, const String:name[], bool:dontBroadcast)
  460. {
  461.         new Float:DetonateOrigin[3];
  462.         DetonateOrigin[0] = GetEventFloat(event, "x");
  463.         DetonateOrigin[1] = GetEventFloat(event, "y");
  464.         DetonateOrigin[2] = GetEventFloat(event, "z");
  465.  
  466.         new client = GetClientOfUserId(GetEventInt(event, "userid"));
  467.         if(!poison[client])
  468.                 return;
  469.  
  470.         new iEntity = CreateEntityByName("light_dynamic");
  471.  
  472.         if (iEntity == -1)
  473.         {
  474.                 return;
  475.         }
  476.         DispatchKeyValue(iEntity, "inner_cone", "0");
  477.         DispatchKeyValue(iEntity, "cone", "80");
  478.         DispatchKeyValue(iEntity, "brightness", "5");
  479.         DispatchKeyValueFloat(iEntity, "spotlight_radius", 96.0);
  480.         DispatchKeyValue(iEntity, "pitch", "90");
  481.         DispatchKeyValue(iEntity, "style", "6");
  482.         DispatchKeyValue(iEntity, "_light", "0 255 0");
  483.         DispatchKeyValueFloat(iEntity, "distance", 256.0);
  484.         SetEntPropEnt(iEntity, Prop_Send, "m_hOwnerEntity", client);
  485.         CreateTimer(20.0, Delete, iEntity, TIMER_FLAG_NO_MAPCHANGE);
  486.  
  487.         TE_SetupBeamRingPoint(DetonateOrigin, 99.0, 100.0, g_sprite, g_HaloSprite, 0, 15, 20.0, 10.0, 220.0, {50, 255, 50, 255}, 10, 0);
  488.         TE_SendToAll();
  489.  
  490.         TE_SetupBeamRingPoint(DetonateOrigin, 99.0, 100.0, g_sprite, g_HaloSprite, 0, 15, 20.0, 10.0, 220.0, {50, 50, 255, 255}, 10, 0);
  491.         TE_SendToAll();
  492.  
  493.         DispatchSpawn(iEntity);
  494.         TeleportEntity(iEntity, DetonateOrigin, NULL_VECTOR, NULL_VECTOR);
  495.         AcceptEntityInput(iEntity, "TurnOn");
  496.  
  497.         CreateTimer(1.0, Timer_CheckDamage, iEntity, TIMER_FLAG_NO_MAPCHANGE|TIMER_REPEAT);
  498.                
  499.         poison[client] = false;
  500. }
  501.  
  502. public OnEntityCreated(iEntity, const String:classname[])
  503. {
  504.         if(StrEqual(classname, "smokegrenade_projectile"))
  505.                 SDKHook(iEntity, SDKHook_SpawnPost, OnEntitySpawned);
  506. }
  507.  
  508. public OnEntitySpawned(iGrenade)
  509. {
  510.         new client = GetEntPropEnt(iGrenade, Prop_Send, "m_hOwnerEntity");
  511.         if(view[client] && IsClientInGame(client))
  512.         {
  513.                 SetClientViewEntity(client, iGrenade);
  514.         }
  515. }
  516.  
  517. public Action:Delete(Handle:timer, any:entity)
  518. {
  519.         if(IsValidEdict(entity))
  520.                 AcceptEntityInput(entity, "kill");
  521. }
  522.  
  523. public Action:Delete2(Handle:timer, any:entity)
  524. {
  525.         if(IsValidEdict(entity))
  526.                 AcceptEntityInput(entity, "kill");
  527. }
  528.  
  529. public Action:Timer_CheckDamage(Handle:timer, any:iEntity)
  530. {
  531.  
  532.         if(!IsValidEdict(iEntity))
  533.                 return Plugin_Stop;
  534.  
  535.         new client = GetEntPropEnt(iEntity, Prop_Send, "m_hOwnerEntity");
  536.  
  537.  
  538.         if (!IsClientInGame(client) || !IsPlayerAlive(client))
  539.                 return Plugin_Stop;
  540.  
  541.  
  542.         new Float:fSmokeOrigin[3], Float:fOrigin[3];
  543.         GetEntPropVector(iEntity, Prop_Send, "m_vecOrigin", fSmokeOrigin);
  544.  
  545.         for(new i=1;i<=MaxClients;i++)
  546.         {
  547.                 if(IsClientInGame(i) && IsPlayerAlive(i) && GetClientTeam(i) != GetClientTeam(client))
  548.                 {
  549.                         GetClientAbsOrigin(i, fOrigin);
  550.                         if(GetVectorDistance(fSmokeOrigin, fOrigin) <= 220)
  551.                                 //SDKHooks_TakeDamage(i, iGrenade, client, GetConVarFloat(g_hCVDamage), DMG_POISON, -1, NULL_VECTOR, fSmokeOrigin);
  552.                                 DealDamage(i,75,client,DMG_POISON,"weapon_smokegrenade");
  553.                 }
  554.         }
  555.         return Plugin_Continue;
  556. }
  557.  
  558. stock DealDamage(nClientVictim, nDamage, nClientAttacker = 0, nDamageType = DMG_GENERIC, String:sWeapon[] = "")
  559. // ----------------------------------------------------------------------------
  560. {
  561.         // taken from: http://forums.alliedmods.net/showthread.php?t=111684
  562.         // thanks to the authors!
  563.         if(     nClientVictim > 0 &&
  564.                         IsValidEdict(nClientVictim) &&
  565.                         IsClientInGame(nClientVictim) &&
  566.                         IsPlayerAlive(nClientVictim) &&
  567.                         nDamage > 0)
  568.         {
  569.                 new EntityPointHurt = CreateEntityByName("point_hurt");
  570.                 if(EntityPointHurt != 0)
  571.                 {
  572.                         new String:sDamage[16];
  573.                         IntToString(nDamage, sDamage, sizeof(sDamage));
  574.  
  575.                         new String:sDamageType[32];
  576.                         IntToString(nDamageType, sDamageType, sizeof(sDamageType));
  577.  
  578.                         DispatchKeyValue(nClientVictim,                 "targetname",           "war3_hurtme");
  579.                         DispatchKeyValue(EntityPointHurt,               "DamageTarget", "war3_hurtme");
  580.                         DispatchKeyValue(EntityPointHurt,               "Damage",                               sDamage);
  581.                         DispatchKeyValue(EntityPointHurt,               "DamageType",           sDamageType);
  582.                         if(!StrEqual(sWeapon, ""))
  583.                                 DispatchKeyValue(EntityPointHurt,       "classname",            sWeapon);
  584.                         DispatchSpawn(EntityPointHurt);
  585.                         AcceptEntityInput(EntityPointHurt,      "Hurt",                                 (nClientAttacker != 0) ? nClientAttacker : -1);
  586.                         DispatchKeyValue(EntityPointHurt,               "classname",            "point_hurt");
  587.                         DispatchKeyValue(nClientVictim,                 "targetname",           "war3_donthurtme");
  588.  
  589.                         RemoveEdict(EntityPointHurt);
  590.                 }
  591.         }
  592. }
  593.  
  594.  
  595. public Action:DID(clientId)
  596. {
  597.         new Handle:menu = CreateMenu(DIDMenuHandler);
  598.         SetMenuTitle(menu, "%t","Shop", g_iCreditos[clientId]);
  599.         decl String:opcionmenu[124];
  600.        
  601.         Format(opcionmenu, 124, "%T","Invisivel", clientId,GetConVarInt(cvar_1));
  602.         AddMenuItem(menu, "option5", opcionmenu);      
  603.        
  604.         Format(opcionmenu, 124, "%T","AWP", clientId,GetConVarInt(cvar_2));
  605.         AddMenuItem(menu, "option6", opcionmenu);
  606.                
  607.         Format(opcionmenu, 124, "%T","Imortal", clientId,GetConVarInt(cvar_3));
  608.         AddMenuItem(menu, "option8", opcionmenu);
  609.                
  610.         Format(opcionmenu, 124, "%T","Jail", clientId,GetConVarInt(cvar_4));
  611.         AddMenuItem(menu, "option9", opcionmenu);
  612.                
  613.         Format(opcionmenu, 124, "%T","Rapido", clientId,GetConVarInt(cvar_5));
  614.         AddMenuItem(menu, "option10", opcionmenu);
  615.                
  616.         Format(opcionmenu, 124, "%T","HP", clientId,GetConVarInt(cvar_6));
  617.         AddMenuItem(menu, "option12", opcionmenu);
  618.                
  619.         Format(opcionmenu, 124, "%T","Eagle", clientId,GetConVarInt(cvar_7));
  620.         AddMenuItem(menu, "option13", opcionmenu);
  621.                
  622.         Format(opcionmenu, 124, "%T","Super", clientId,GetConVarInt(cvar_8));
  623.         AddMenuItem(menu, "option14", opcionmenu);
  624.                
  625.         Format(opcionmenu, 124, "%T","Cura", clientId,GetConVarInt(cvar_9));
  626.         AddMenuItem(menu, "option15", opcionmenu);
  627.                
  628.         decl String:sGame[64];
  629.         GetGameFolderName(sGame, sizeof(sGame));
  630.         if (StrEqual(sGame, "cstrike"))
  631.         {
  632.                 Format(opcionmenu, 124, "%T","2flash", clientId,GetConVarInt(cvar_10));
  633.                 AddMenuItem(menu, "option16", opcionmenu);
  634.         }
  635.         else if (StrEqual(sGame, "csgo"))
  636.         {
  637.                 Format(opcionmenu, 124, "%T","Molotov", clientId,GetConVarInt(cvar_10));
  638.                 AddMenuItem(menu, "option16", opcionmenu);
  639.         }
  640.        
  641.         Format(opcionmenu, 124, "%T","Skin", clientId,GetConVarInt(cvar_11));
  642.         AddMenuItem(menu, "option17", opcionmenu);
  643.                
  644.         Format(opcionmenu, 124, "%T","Smoke", clientId,GetConVarInt(cvar_12));
  645.         AddMenuItem(menu, "option18", opcionmenu);
  646.        
  647.         Format(opcionmenu, 124, "%T","Teletransportadora3", clientId,GetConVarInt(cvar_14));
  648.         AddMenuItem(menu, "option20", opcionmenu);
  649.        
  650.         Format(opcionmenu, 124, "%T","HE", clientId,GetConVarInt(cvar_16));
  651.         AddMenuItem(menu, "option21", opcionmenu);
  652.        
  653.         Format(opcionmenu, 124, "%T","Bhop", clientId,GetConVarInt(cvar_17));
  654.         AddMenuItem(menu, "option22", opcionmenu);
  655.        
  656.         Format(opcionmenu, 124, "%T","Gravity", clientId,GetConVarInt(cvar_18));
  657.         AddMenuItem(menu, "option23", opcionmenu);
  658.        
  659.         SetMenuExitButton(menu, true);
  660.         DisplayMenu(menu, clientId, MENU_TIME_FOREVER);
  661.  
  662.         return Plugin_Handled;
  663. }
  664.  
  665.  
  666. public DIDMenuHandler(Handle:menu, MenuAction:action, client, itemNum)
  667. {
  668.         if ( action == MenuAction_Select )
  669.         {
  670.                 new String:info[32];
  671.  
  672.                 GetMenuItem(menu, itemNum, info, sizeof(info));
  673.  
  674.                 if ( strcmp(info,"option1") == 0 )
  675.                 {
  676.                         {
  677.                                 DID(client);
  678.                                 CPrintToChat(client,"\x0E[ SHOP ] \x04make by dk.");
  679.                         }
  680.                 }
  681.  
  682.  
  683.  
  684.                         else if ( strcmp(info,"option5") == 0 )
  685.                         {
  686.                                 {
  687.                                         DID(client);
  688.                                        
  689.                                                        
  690.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_1))
  691.                                         {
  692.                                                 if (IsPlayerAlive(client))
  693.                                                 {
  694.                                                         decl String:sGame[255];
  695.                                                         GetGameFolderName(sGame, sizeof(sGame));
  696.                                                         if (StrEqual(sGame, "cstrike") || StrEqual(sGame, "cstrike_beta"))
  697.                                                         {
  698.                                                                 SetEntityRenderMode(client, RENDER_TRANSCOLOR);
  699.                                                                 SetEntityRenderColor(client, 255, 255, 255, 0);
  700.                                                                 g_Ivisivel[client] = true;             
  701.                                                                 CreateTimer(10.0, Invisible2, client);
  702.                                                         }
  703.                                                         else if (StrEqual(sGame, "csgo"))
  704.                                                         {
  705.                                                                 SDKHook(client, SDKHook_SetTransmit, Hook_SetTransmit);
  706.                                                                 g_Ivisivel[client] = true;             
  707.                                                                 CreateTimer(10.0, Invisible, client);
  708.                                                         }
  709.  
  710.                                                         new wepIdx;
  711.  
  712.                                                         // strip all weapons
  713.                                                         for (new s = 0; s < 4; s++)
  714.                                                         {
  715.                                                                 if ((wepIdx = GetPlayerWeaponSlot(client, s)) != -1)
  716.                                                                 {
  717.                                                                         RemovePlayerItem(client, wepIdx);
  718.                                                                         RemoveEdict(wepIdx);
  719.                                                                 }
  720.                                                         }
  721.  
  722.                                                         GivePlayerItem(client, "weapon_knife");
  723.                                                        
  724.  
  725.                                                         g_iCreditos[client] -= GetConVarInt(cvar_1);
  726.                                                        
  727.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Invisivel2", g_iCreditos[client],GetConVarInt(cvar_2));
  728.                                                 }
  729.                                                 else
  730.                                                 {
  731.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  732.                                                 }
  733.                                         }
  734.                                         else
  735.                                         {
  736.                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item invisivel", g_iCreditos[client],GetConVarInt(cvar_1));
  737.                                         }
  738.                                 }
  739.                        
  740.                         }
  741.  
  742.                         else if ( strcmp(info,"option6") == 0 )
  743.                         {
  744.                                 {
  745.                                         DID(client);
  746.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_2))
  747.                                         {
  748.                                                 if(!AWP[client])
  749.                                                 {      
  750.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","MaximoAWP");
  751.                                                 }
  752.                                                 else if(AWP[client] && IsPlayerAlive(client))
  753.                                                 {      
  754.                                                         GivePlayerItem(client, "weapon_awp");
  755.                                                         AWP[client] = false;
  756.                                                         Client_GiveWeaponAndAmmo(client, "weapon_awp", _, 0, _, 1);
  757.                                                         g_iCreditos[client] -= GetConVarInt(cvar_2);
  758.                                                        
  759.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","AWP2", g_iCreditos[client],GetConVarInt(cvar_2));
  760.                                                 }
  761.                                                 else
  762.                                                 {
  763.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  764.                                                 }
  765.                                         }
  766.                                         else
  767.                                         {
  768.                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item awp", g_iCreditos[client],GetConVarInt(cvar_2));
  769.                                         }
  770.                                 }
  771.                         }
  772.                        
  773.  
  774.                         else if ( strcmp(info,"option8") == 0 )
  775.                         {
  776.                                 {
  777.                                         DID(client);
  778.                                        
  779.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_3))
  780.                                         {
  781.                                                 if (IsPlayerAlive(client))
  782.                                                 {
  783.  
  784.                                                         g_Godmode[client] = true;
  785.                                                         CreateTimer(20.0, OpcionNumero16b, client);
  786.  
  787.                                                         g_iCreditos[client] -= GetConVarInt(cvar_3);
  788.                                                        
  789.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Imortal2", g_iCreditos[client],GetConVarInt(cvar_3));
  790.                                                 }
  791.                                                 else
  792.                                                 {
  793.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  794.                                                 }
  795.                                         }
  796.                                         else
  797.                                         {
  798.                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item imortal", g_iCreditos[client],GetConVarInt(cvar_3));
  799.                                         }
  800.                                 }
  801.  
  802.                         }
  803.  
  804.                         else if ( strcmp(info,"option9") == 0 )
  805.                         {
  806.                                 {
  807.                                         DID(client);
  808.                                        
  809.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_4))
  810.                                         {
  811.                                                 if (IsPlayerAlive(client))
  812.                                                 {
  813.  
  814.                                                         abrir();
  815.  
  816.                                                         g_iCreditos[client] -= GetConVarInt(cvar_4);
  817.                                                        
  818.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Jails2", g_iCreditos[client],GetConVarInt(cvar_4));
  819.                                                         decl String:nome[32];
  820.                                                         GetClientName(client, nome, sizeof(nome));
  821.  
  822.                                                         CPrintToChatAll("\x0E[ SHOP ] \x04O jogador\x03 %s \x04abriu as jails pelo shop!", nome);
  823.                                                 }
  824.                                                 else
  825.                                                 {
  826.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  827.                                                 }
  828.                                         }
  829.                                         else
  830.                                         {
  831.                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item jails", g_iCreditos[client],GetConVarInt(cvar_4));
  832.                                         }
  833.                                 }
  834.  
  835.                         }
  836.  
  837.                         else if ( strcmp(info,"option10") == 0 )
  838.                         {
  839.                                 {
  840.                                         DID(client);
  841.                                        
  842.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_5))
  843.                                         {
  844.                                                 if (IsPlayerAlive(client))
  845.                                                 {
  846.  
  847.                                                         SetEntPropFloat(client, Prop_Data, "m_flLaggedMovementValue", 1.5);
  848.  
  849.                                                         g_iCreditos[client] -= GetConVarInt(cvar_5);
  850.                                                         vampire[client] = true;
  851.                                                        
  852.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Rapido2", g_iCreditos[client],GetConVarInt(cvar_5));
  853.                                                 }
  854.                                                 else
  855.                                                 {
  856.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  857.                                                 }
  858.                                         }
  859.                                         else
  860.                                         {
  861.                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item rapido", g_iCreditos[client],GetConVarInt(cvar_5));
  862.                                         }
  863.                                 }
  864.  
  865.                         }
  866.  
  867.  
  868.                         else if ( strcmp(info,"option12") == 0 )
  869.                         {
  870.                                 {
  871.                                         DID(client);
  872.                                        
  873.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_6))
  874.                                         {
  875.                                                 if (IsPlayerAlive(client))
  876.                                                 {
  877.                                                        
  878.                                                         g_iCreditos[client] -= GetConVarInt(cvar_6);
  879.                                                        
  880.                                                         new vida = (GetClientHealth(client) + 150);
  881.  
  882.                                                         SetEntityHealth(client, vida);
  883.                                                         GivePlayerItem( client, "item_assaultsuit"); // Give Kevlar Suit and a Helmet
  884.                                                         SetEntProp( client, Prop_Send, "m_ArmorValue", 100, 1 ); // Set kevlar armour
  885.                                                        
  886.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","HP2", g_iCreditos[client],GetConVarInt(cvar_6));
  887.                                                 }
  888.                                                         else
  889.                                                         {
  890.                                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  891.                                                         }
  892.                                         }
  893.                                                         else
  894.                                                         {
  895.                                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da vida", g_iCreditos[client],GetConVarInt(cvar_6));
  896.                                                         }
  897.                                 }
  898.  
  899.                         }
  900.  
  901.  
  902.                         else if ( strcmp(info,"option13") == 0 )
  903.                         {
  904.                                 {
  905.                                         DID(client);
  906.                                        
  907.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_7))
  908.                                         {
  909.                                                 if(!EAGLE[client])
  910.                                                 {      
  911.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","MaximoEAGLE");
  912.                                                 }
  913.                                                
  914.                                                 else if(EAGLE[client] && IsPlayerAlive(client))
  915.                                                 {
  916.                                                         GivePlayerItem(client, "weapon_deagle");
  917.                                                         EAGLE[client] = false;
  918.                                                         Client_GiveWeaponAndAmmo(client, "weapon_deagle", _, 0, _, 7);
  919.                                                        
  920.                                                         g_iCreditos[client] -= GetConVarInt(cvar_7);
  921.                                                        
  922.  
  923.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Eagle2", g_iCreditos[client],GetConVarInt(cvar_7));
  924.                                                 }
  925.                                                 else
  926.                                                 {
  927.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  928.                                                 }
  929.  
  930.                                         }
  931.                                                 else
  932.                                                 {
  933.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da eagle", g_iCreditos[client],GetConVarInt(cvar_7));
  934.                                                 }
  935.                                 }
  936.                         }
  937.  
  938.                         else if ( strcmp(info,"option14") == 0 )
  939.                         {
  940.                                 {
  941.                                         DID(client);
  942.                                        
  943.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_8))
  944.                                         {
  945.                                                 if (IsPlayerAlive(client))
  946.                                                 {
  947.                                                         decl String:sGame[255];
  948.                                                         GetGameFolderName(sGame, sizeof(sGame));
  949.                                                         if (StrEqual(sGame, "cstrike") || StrEqual(sGame, "cstrike_beta"))
  950.                                                         {
  951.                                                                 new currentknife = GetPlayerWeaponSlot(client, 2);
  952.                                                                 if(IsValidEntity(currentknife) && currentknife != INVALID_ENT_REFERENCE)
  953.                                                                 {
  954.                                                                         RemovePlayerItem(client, currentknife);
  955.                                                                         RemoveEdict(currentknife);
  956.                                                                 }
  957.                                                                
  958.                                                                 new knife = GivePlayerItem(client, "weapon_knife");    
  959.                                                                 EquipPlayerWeapon(client, knife);
  960.                                                                
  961.                                                                 super_faca[client] = true;
  962.                                                         }
  963.                                                        
  964.                                                         else if (StrEqual(sGame, "csgo"))
  965.                                                         {
  966.                                                                 new currentknife = GetPlayerWeaponSlot(client, 2);
  967.                                                                 if(IsValidEntity(currentknife) && currentknife != INVALID_ENT_REFERENCE)
  968.                                                                 {
  969.                                                                         RemovePlayerItem(client, currentknife);
  970.                                                                         RemoveEdict(currentknife);
  971.                                                                 }
  972.                                                                
  973.                                                                 new knife = GivePlayerItem(client, "weapon_knifegg");  
  974.                                                                 EquipPlayerWeapon(client, knife);
  975.                                                                
  976.                                                                 super_faca[client] = true;
  977.                                                         }
  978.                                                        
  979.                                                
  980.                                                         g_iCreditos[client] -= GetConVarInt(cvar_8);
  981.                                                        
  982.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Super2", g_iCreditos[client],GetConVarInt(cvar_8));
  983.                                                 }
  984.                                                 else
  985.                                                 {
  986.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  987.                                                 }
  988.  
  989.                                         }
  990.                                                 else
  991.                                                 {
  992.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da super faca", g_iCreditos[client],GetConVarInt(cvar_8));
  993.                                                 }
  994.                                 }
  995.  
  996.                         }
  997.  
  998.                         else if ( strcmp(info,"option15") == 0 )
  999.                         {
  1000.                                 {
  1001.                                         DID(client);
  1002.                                        
  1003.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_9))
  1004.                                         {
  1005.                                                 if (IsPlayerAlive(client))
  1006.                                                 {
  1007.                                                         new health = GetEntProp(client, Prop_Send, "m_iHealth");  
  1008.                                                        
  1009.                                                         if(health >= 100)
  1010.                                                         {
  1011.                                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04 Your life already is full '-'");
  1012.                                                         }
  1013.                                                         else
  1014.                                                         {
  1015.                                                                 SetEntityHealth(client, 100);
  1016.                                                                 g_iCreditos[client] -= GetConVarInt(cvar_9);
  1017.                                                                
  1018.                                                                 EmitSoundToAll("medicsound/medic.wav");
  1019.                                                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Curar2", g_iCreditos[client],GetConVarInt(cvar_9));
  1020.                                                         }
  1021.  
  1022.  
  1023.                                                 }
  1024.                                                 else
  1025.                                                 {
  1026.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  1027.                                                 }
  1028.  
  1029.                                         }
  1030.                                                 else
  1031.                                                 {
  1032.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item de curar", g_iCreditos[client],GetConVarInt(cvar_9));
  1033.                                                 }
  1034.                                 }
  1035.  
  1036.                         }
  1037.  
  1038.                         else if ( strcmp(info,"option16") == 0 )
  1039.                         {
  1040.                                 {
  1041.                                         DID(client);
  1042.                                        
  1043.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_10))
  1044.                                         {
  1045.                                                 if (IsPlayerAlive(client))
  1046.                                                 {
  1047.  
  1048.                                                         GivePlayerItem(client, "weapon_molotov");
  1049.                                                         GivePlayerItem(client, "weapon_flashbang");
  1050.                                                         GivePlayerItem(client, "weapon_flashbang");
  1051.  
  1052.                                                         g_iCreditos[client] -= GetConVarInt(cvar_10);
  1053.                                                        
  1054.  
  1055.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Molotov2", g_iCreditos[client],GetConVarInt(cvar_10));
  1056.                                                 }
  1057.                                                 else
  1058.                                                 {
  1059.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  1060.                                                 }
  1061.  
  1062.                                         }
  1063.                                                 else
  1064.                                                 {
  1065.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da molotov", g_iCreditos[client],GetConVarInt(cvar_10));
  1066.                                                 }
  1067.                                 }
  1068.                         }
  1069.                                
  1070.                        
  1071.                        
  1072.                         else if ( strcmp(info,"option17") == 0 )
  1073.                         {
  1074.                                 {
  1075.                                         DID(client);
  1076.                                        
  1077.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_11))
  1078.                                         {
  1079.                                                 if (IsPlayerAlive(client))
  1080.                                                 {
  1081.                                                         g_iCreditos[client] -= GetConVarInt(cvar_11);
  1082.                                                         SetEntityModel(client, "models/player/ctm_gign_variantc.mdl");
  1083.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Skin2", g_iCreditos[client],GetConVarInt(cvar_11));
  1084.                                                 }
  1085.                                                 else
  1086.                                                 {
  1087.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  1088.                                                 }
  1089.                                                        
  1090.  
  1091.                                         }
  1092.                                                 else
  1093.                                                 {
  1094.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da skin", g_iCreditos[client],GetConVarInt(cvar_11));
  1095.                                                 }
  1096.                                 }
  1097.  
  1098.                         }
  1099.                        
  1100.                         else if ( strcmp(info,"option18") == 0 )
  1101.                         {
  1102.                                 {
  1103.                                         DID(client);
  1104.                                        
  1105.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_12))
  1106.                                         {
  1107.                                                 if (IsPlayerAlive(client))
  1108.                                                 {
  1109.  
  1110.                                                         GivePlayerItem(client, "weapon_smokegrenade");
  1111.                                                        
  1112.                                                        
  1113.                                                         g_iCreditos[client] -= GetConVarInt(cvar_12);
  1114.                                                        
  1115.                                                        
  1116.                                                         poison[client] = true;
  1117.                                                        
  1118.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Smoke2", g_iCreditos[client],GetConVarInt(cvar_12));
  1119.                                                 }
  1120.                                                 else
  1121.                                                 {
  1122.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  1123.                                                 }
  1124.  
  1125.                                         }
  1126.                                                 else
  1127.                                                 {
  1128.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da smoke", g_iCreditos[client],GetConVarInt(cvar_12));
  1129.                                                 }
  1130.                                 }
  1131.  
  1132.                         }
  1133.                        
  1134.                        
  1135.                                                
  1136.                         else if ( strcmp(info,"option20") == 0 )
  1137.                         {
  1138.                                 {
  1139.                                         DID(client);
  1140.                                        
  1141.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_14))
  1142.                                         {
  1143.                                                 if (IsPlayerAlive(client))
  1144.                                                 {
  1145.  
  1146.                                                         GivePlayerItem(client, "weapon_smokegrenade");
  1147.                                                        
  1148.                                                        
  1149.                                                         g_iCreditos[client] -= GetConVarInt(cvar_14);
  1150.                                                        
  1151.                                                        
  1152.                                                         view[client] = true;
  1153.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Teletransportadora", g_iCreditos[client],GetConVarInt(cvar_14));
  1154.                                                 }
  1155.                                                 else
  1156.                                                 {
  1157.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  1158.                                                 }
  1159.  
  1160.                                         }
  1161.                                                 else
  1162.                                                 {
  1163.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da teletransportadora", g_iCreditos[client],GetConVarInt(cvar_14));
  1164.                                                 }
  1165.                                 }
  1166.  
  1167.                         }
  1168.                        
  1169.                         else if ( strcmp(info,"option21") == 0 )
  1170.                         {
  1171.                                 {
  1172.                                         DID(client);
  1173.                                        
  1174.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_16))
  1175.                                         {
  1176.                                                 if (IsPlayerAlive(client))
  1177.                                                 {
  1178.  
  1179.                                                         GivePlayerItem(client, "weapon_hegrenade");
  1180.                                                        
  1181.                                                        
  1182.                                                         g_iCreditos[client] -= GetConVarInt(cvar_16);
  1183.                                                        
  1184.                                                        
  1185.                                                         fogo[client] = true;
  1186.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","HE2", g_iCreditos[client],GetConVarInt(cvar_16));
  1187.                                                 }
  1188.                                                 else
  1189.                                                 {
  1190.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  1191.                                                 }
  1192.  
  1193.                                         }
  1194.                                                 else
  1195.                                                 {
  1196.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da he2", g_iCreditos[client],GetConVarInt(cvar_16));
  1197.                                                 }
  1198.                                 }
  1199.                                
  1200.                         }
  1201.                        
  1202.                         else if ( strcmp(info,"option22") == 0 )
  1203.                         {
  1204.                                 {
  1205.                                         DID(client);
  1206.                                        
  1207.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_17))
  1208.                                         {
  1209.                                                 if (IsPlayerAlive(client))
  1210.                                                 {
  1211.  
  1212.                                                         g_iCreditos[client] -= GetConVarInt(cvar_17);
  1213.                                                        
  1214.                                                        
  1215.                                                         bhop[client] = true;
  1216.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Bhop2", g_iCreditos[client],GetConVarInt(cvar_17));
  1217.                                                 }
  1218.                                                 else
  1219.                                                 {
  1220.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  1221.                                                 }
  1222.  
  1223.                                         }
  1224.                                                 else
  1225.                                                 {
  1226.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item do bhop", g_iCreditos[client],GetConVarInt(cvar_17));
  1227.                                                 }
  1228.                                 }
  1229.                                
  1230.                         }
  1231.                        
  1232.                         else if ( strcmp(info,"option23") == 0 )
  1233.                         {
  1234.                                 {
  1235.                                         DID(client);
  1236.                                        
  1237.                                         if (g_iCreditos[client] >= GetConVarInt(cvar_18))
  1238.                                         {
  1239.                                                 if (IsPlayerAlive(client))
  1240.                                                 {
  1241.  
  1242.                                                         g_iCreditos[client] -= GetConVarInt(cvar_18);
  1243.                                                        
  1244.                                                        
  1245.                                                         SetEntityGravity(client, 0.6);
  1246.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Gravity2", g_iCreditos[client],GetConVarInt(cvar_18));
  1247.                                                 }
  1248.                                                 else
  1249.                                                 {
  1250.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Vivo");
  1251.                                                 }
  1252.  
  1253.                                         }
  1254.                                                 else
  1255.                                                 {
  1256.                                                         CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Item da gravidade", g_iCreditos[client],GetConVarInt(cvar_18));
  1257.                                                 }
  1258.                                 }
  1259.                                
  1260.                         }
  1261.         }
  1262. }
  1263.  
  1264.  
  1265. public Action:SetCreditos2(client, args)
  1266. {
  1267.     if(client == 0)
  1268.     {
  1269.                 PrintToServer("%t","Command is in-game only");
  1270.                 return Plugin_Handled;
  1271.     }
  1272.  
  1273.     if(args < 2)
  1274.     {
  1275.         ReplyToCommand(client, "[SM] Use: sm_set <#userid|name> [amount]");
  1276.         return Plugin_Handled;
  1277.     }
  1278.  
  1279.     decl String:arg2[10];
  1280.    
  1281.     GetCmdArg(2, arg2, sizeof(arg2));
  1282.  
  1283.     new amount = StringToInt(arg2);
  1284.  
  1285.     decl String:strTarget[32]; GetCmdArg(1, strTarget, sizeof(strTarget));
  1286.  
  1287.    
  1288.     decl String:strTargetName[MAX_TARGET_LENGTH];
  1289.     decl TargetList[MAXPLAYERS], TargetCount;
  1290.     decl bool:TargetTranslate;
  1291.  
  1292.     if ((TargetCount = ProcessTargetString(strTarget, client, TargetList, MAXPLAYERS, COMMAND_FILTER_CONNECTED,
  1293.                                            strTargetName, sizeof(strTargetName), TargetTranslate)) <= 0)
  1294.     {
  1295.           ReplyToTargetError(client, TargetCount);
  1296.           return Plugin_Handled;
  1297.     }
  1298.  
  1299.    
  1300.     for (new i = 0; i < TargetCount; i++)
  1301.     {
  1302.         new iClient = TargetList[i];
  1303.         if (IsClientInGame(iClient))
  1304.         {
  1305.               g_iCreditos[iClient] = amount;
  1306.  
  1307.                          
  1308.               CPrintToChat(iClient, "[ SHOP ] Set \x03%i \x01credits in the player: %N", amount, iClient);
  1309.         }
  1310.     }
  1311.  
  1312.     return Plugin_Continue;
  1313. }
  1314.  
  1315. public Action:SetCreditos(client, args)
  1316. {
  1317.         if(client == 0)
  1318.         {
  1319.                 PrintToServer("%t","Command is in-game only");
  1320.                 return Plugin_Handled;
  1321.         }
  1322.  
  1323.         if(args < 2)
  1324.         {
  1325.                 ReplyToCommand(client, "[SM] Use: sm_give <#userid|name> [amount]");
  1326.                 return Plugin_Handled;
  1327.         }
  1328.  
  1329.         decl String:arg2[10];
  1330.  
  1331.         GetCmdArg(2, arg2, sizeof(arg2));
  1332.  
  1333.         new amount = StringToInt(arg2);
  1334.  
  1335.         decl String:strTarget[32]; GetCmdArg(1, strTarget, sizeof(strTarget));
  1336.  
  1337.  
  1338.         decl String:strTargetName[MAX_TARGET_LENGTH];
  1339.         decl TargetList[MAXPLAYERS], TargetCount;
  1340.         decl bool:TargetTranslate;
  1341.  
  1342.         if ((TargetCount = ProcessTargetString(strTarget, client, TargetList, MAXPLAYERS, COMMAND_FILTER_CONNECTED,
  1343.                                                                                    strTargetName, sizeof(strTargetName), TargetTranslate)) <= 0)
  1344.         {
  1345.                   ReplyToTargetError(client, TargetCount);
  1346.                   return Plugin_Handled;
  1347.         }
  1348.  
  1349.  
  1350.         for (new i = 0; i < TargetCount; i++)
  1351.         {
  1352.                 new iClient = TargetList[i];
  1353.                 if (IsClientInGame(iClient))
  1354.                 {
  1355.                           g_iCreditos[iClient] += amount;
  1356.                          
  1357.                           CPrintToChat(iClient, "[ SHOP ] Give \x03%i \x01credits in the player: %N", amount, iClient);
  1358.  
  1359.                 }
  1360.         }
  1361.  
  1362.         return Plugin_Continue;
  1363. }
  1364.  
  1365. public Action:Command_SendCredits(client, args)
  1366. {
  1367.         if(client == 0)
  1368.         {
  1369.                 PrintToServer("%t","Command is in-game only");
  1370.                 return Plugin_Handled;
  1371.         }
  1372.  
  1373.         if(args < 2) // Not enough parameters
  1374.         {
  1375.                 ReplyToCommand(client, "[SM] Use: sm_gift <#userid|name> [amount]");
  1376.                 return Plugin_Handled;
  1377.         }
  1378.  
  1379.         decl String:arg2[10];
  1380.         GetCmdArg(2, arg2, sizeof(arg2));
  1381.  
  1382.         new amount = StringToInt(arg2);
  1383.  
  1384.         decl String:strTarget[32]; GetCmdArg(1, strTarget, sizeof(strTarget));
  1385.  
  1386.         decl String:strTargetName[MAX_TARGET_LENGTH];
  1387.         decl TargetList[MAXPLAYERS], TargetCount;
  1388.         decl bool:TargetTranslate;
  1389.  
  1390.         if ((TargetCount = ProcessTargetString(strTarget, client, TargetList, MAXPLAYERS, COMMAND_FILTER_CONNECTED,
  1391.                 strTargetName, sizeof(strTargetName), TargetTranslate)) <= 0)
  1392.         {
  1393.                 ReplyToTargetError(client, TargetCount);
  1394.                 return Plugin_Handled;
  1395.         }
  1396.        
  1397.         for (new i = 0; i < TargetCount; i++)
  1398.         {
  1399.                 new iClient = TargetList[i];
  1400.                 if (IsClientInGame(iClient) && amount > 0)
  1401.                 {
  1402.                         if (g_iCreditos[client] < amount)
  1403.                                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","NoCredits");
  1404.                         else
  1405.                         {
  1406.                                 g_iCreditos[client] -= amount;
  1407.                                 g_iCreditos[iClient] += amount;
  1408.                        
  1409.                                 CPrintToChat(client, "[ SHOP ] You give \x03%i \x01credits for player: %N", amount, iClient);
  1410.                                 CPrintToChat(iClient, "[ SHOP ] You get \x03%i \x01credits from player: %N", amount, client);
  1411.                         }
  1412.                 }
  1413.         }
  1414.         return Plugin_Continue;
  1415. }
  1416.  
  1417. public Action:OnTakeDamage(victim, &attacker, &inflictor, &Float:damage, &damagetype)
  1418. {
  1419.         if (g_Godmode[victim] == true)
  1420.         {
  1421.            damage = 0.0;
  1422.            return Plugin_Changed;
  1423.         }
  1424.         else if(IsValidClient(attacker))
  1425.         {
  1426.                 if((vampire[attacker] && GetClientTeam(attacker) != GetClientTeam(victim)))
  1427.                 {
  1428.                         new recibir = RoundToFloor(damage * 0.5);
  1429.                         recibir += GetClientHealth(attacker);
  1430.                         SetEntityHealth(attacker, recibir);
  1431.                 }
  1432.                
  1433.                 if(super_faca[attacker])
  1434.                 {
  1435.                         decl String:weaponName[255];
  1436.                         GetClientWeapon(attacker, weaponName, sizeof(weaponName));
  1437.                         decl String:sGame[255];
  1438.                         GetGameFolderName(sGame, sizeof(sGame));
  1439.                         if (StrEqual(sGame, "cstrike") || StrEqual(sGame, "cstrike_beta"))
  1440.                         {
  1441.                                 if(StrEqual(weaponName, "weapon_knife"))
  1442.                                 {
  1443.                                         DealDamage(victim,100,attacker,DMG_BULLET,weaponName);
  1444.                                 }
  1445.                         }
  1446.                         else if (StrEqual(sGame, "csgo"))
  1447.                         {
  1448.                                 if(StrEqual(weaponName, "weapon_knifegg"))
  1449.                                 {
  1450.                                         DealDamage(victim,100,attacker,DMG_BULLET,weaponName);
  1451.                                 }
  1452.                         }
  1453.                        
  1454.                 }
  1455.                
  1456.         }
  1457.  
  1458.         return Plugin_Continue;
  1459. }
  1460.  
  1461.  
  1462. stock bool:IsValidClient(client, bool:bAlive = false)
  1463. {
  1464.         if(client >= 1 && client <= MaxClients && IsClientConnected(client) && IsClientInGame(client) && (bAlive == false || IsPlayerAlive(client)))
  1465.         {
  1466.                 return true;
  1467.         }
  1468.        
  1469.         return false;
  1470. }
  1471.  
  1472. public Action:OnPlayerRunCmd(client, &buttons, &impulse, Float:vel[3], Float:angles[3], &weapon)
  1473. {
  1474.         new water = GetEntProp(client, Prop_Data, "m_nWaterLevel");
  1475.         if (IsPlayerAlive(client))
  1476.         {
  1477.                 if (buttons & IN_JUMP)
  1478.                 {
  1479.                         if (water <= 1)
  1480.                         {
  1481.                                 if (!(GetEntityMoveType(client) & MOVETYPE_LADDER))
  1482.                                 {
  1483.                                         SetEntPropFloat(client, Prop_Send, "m_flStamina", 0.0);
  1484.                                         if (!(GetEntityFlags(client) & FL_ONGROUND))
  1485.                                         {
  1486.                                                 if(bhop[client] == true)
  1487.                                                 {
  1488.                                                         buttons &= ~IN_JUMP;   
  1489.                                                 }
  1490.                                         }
  1491.                                 }
  1492.                         }
  1493.                 }
  1494.         }
  1495.        
  1496.         return Plugin_Continue;
  1497. }
  1498.  
  1499.  
  1500.  
  1501. public Action:OnWeaponCanUse(client, weapon)
  1502. {
  1503.         if (g_Ivisivel[client])
  1504.         {
  1505.                 decl String:sClassname[32];
  1506.                 GetEdictClassname(weapon, sClassname, sizeof(sClassname));
  1507.                 if (!StrEqual(sClassname, "weapon_knife"))
  1508.                 return Plugin_Handled;
  1509.         }
  1510.         return Plugin_Continue;
  1511. }
  1512.  
  1513. public OnClientPutInServer(client)
  1514. {
  1515.         SDKHook(client, SDKHook_OnTakeDamage, OnTakeDamage);
  1516.         SDKHook(client, SDKHook_WeaponCanUse, OnWeaponCanUse);
  1517. }
  1518.  
  1519. public OnClientPostAdminCheck(client)
  1520. {
  1521.         g_Godmode[client] = false;
  1522.         g_Ivisivel[client] = false;
  1523.         fogo[client] = false;
  1524.         super_faca[client] = false;
  1525.         poison[client] = false;
  1526.         vampire[client] = false;
  1527.         AWP[client] = true;
  1528.         EAGLE[client] = true;
  1529.         view[client] = false;
  1530. }
  1531.  
  1532. public Action:Event_OnRoundEnd(Handle:event, const String:name[], bool:dontBroadcast)
  1533. {
  1534.         for (new i = 1; i <= GetMaxClients(); i++)
  1535.                 if (IsClientInGame(i))
  1536.                         {
  1537.                                 poison[i] = false;
  1538.                                 vampire[i] = false;
  1539.                                 view[i] = false;
  1540.                                 fogo[i] = false;
  1541.                                 super_faca[i] = false;
  1542.                                 bhop[i] = false;
  1543.                                 AWP[i] = true;
  1544.                                 EAGLE[i] = true;
  1545.                         }
  1546. }
  1547.  
  1548. public Action:PlayerSpawn(Handle:event, const String:name[], bool:dontBroadcast)
  1549. {
  1550.         new client = GetClientOfUserId(GetEventInt(event, "userid"));
  1551.  
  1552.         if (GetClientTeam(client) == 1 && !IsPlayerAlive(client))
  1553.         {
  1554.                 return;
  1555.         }
  1556.  
  1557.         CreateTimer(1.0, MensajesSpawn, client);
  1558.        
  1559. }
  1560.  
  1561. Normalizar(client)
  1562. {
  1563.         if (g_Godmode[client])
  1564.         {
  1565.                 g_Godmode[client] = false;
  1566.         }
  1567.         if (g_Ivisivel[client])
  1568.         {
  1569.                 g_Ivisivel[client] = false;
  1570.                 SDKUnhook(client, SDKHook_SetTransmit, Hook_SetTransmit);  
  1571.         }
  1572.        
  1573.         poison[client] = false;
  1574.         vampire[client] = false;
  1575.         view[client] = false;
  1576.         fogo[client] = false;
  1577.         super_faca[client] = false;
  1578.         bhop[client] = false;
  1579.         AWP[client] = true;
  1580.         EAGLE[client] = true;
  1581. }
  1582.  
  1583. public OnAvailableLR(Announced)
  1584. {
  1585.         for (new i = 1; i <= GetMaxClients(); i++)
  1586.         {
  1587.                 if (IsClientInGame(i) && IsPlayerAlive(i) && GetClientTeam(i) == CS_TEAM_T)
  1588.                 {
  1589.                         if(GetAllPlayersCount() >= GetConVarInt(cvarMinPlayersToGetCredits) && (GetConVarInt(cvarCreditsOnWarmup) != 0 || GameRules_GetProp("m_bWarmupPeriod") != 1) )
  1590.                                 if (IsPlayerReservationAdmin(i))
  1591.                                         g_iCreditos[i] += GetConVarInt(cvarCreditos_LR_VIP);
  1592.                                 else
  1593.                                         g_iCreditos[i] += GetConVarInt(cvarCreditos_LR);
  1594.                         SetEntityGravity(i, 1.0);
  1595.                         Normalizar(i);
  1596.                         SetEntPropFloat(i, Prop_Data, "m_flLaggedMovementValue", 1.0);
  1597.                 }
  1598.         }
  1599. }
  1600.  
  1601.  
  1602. public Action:OpcionNumero16b(Handle:timer, any:client)
  1603. {
  1604.         if ( (IsClientInGame(client)) && (IsPlayerAlive(client)) )
  1605.         {
  1606.            CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Mortal3");
  1607.            g_Godmode[client] = false;
  1608.         }
  1609.  
  1610. }
  1611.  
  1612. public Action:Invisible(Handle:timer, any:client)
  1613. {
  1614.  if ( (IsClientInGame(client)) && (IsPlayerAlive(client)) )
  1615.  {
  1616.    g_Ivisivel[client] = false;
  1617.    CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Visivel novamente");
  1618.    SDKUnhook(client, SDKHook_SetTransmit, Hook_SetTransmit);  
  1619.  }
  1620. }
  1621.  
  1622. public Action:Invisible2(Handle:timer, any:client)
  1623. {
  1624.         if ( (IsClientInGame(client)) && (IsPlayerAlive(client)) )
  1625.         {
  1626.                 CPrintToChat(client, "\x0E[ SHOP ] \x04%t","Visivel novamente");
  1627.                 SetEntityRenderMode(client, RENDER_TRANSCOLOR);
  1628.                 g_Ivisivel[client] = false;
  1629.                 SetEntityRenderColor(client, 255, 255, 255, 255);
  1630.         }
  1631. }
  1632.  
  1633. public Action:abrir()
  1634. {
  1635.     for(new i = 0; i < sizeof(EntityList); i++)
  1636.         while((iEnt = FindEntityByClassname(iEnt, EntityList[i])) != -1)
  1637.             AcceptEntityInput(iEnt, "Open");
  1638.     return Plugin_Handled;
  1639. }
  1640.  
  1641.  
  1642. public Action:Hook_SetTransmit(entity, client)  
  1643. {  
  1644.     if (entity != client)  
  1645.         return Plugin_Handled;
  1646.      
  1647.     return Plugin_Continue;  
  1648. }
  1649.  
  1650.  
  1651. public Action:Command_ShowCredits(client, args)
  1652. {
  1653.         decl String:sName[MAX_NAME_LENGTH], String:sUserId[10];
  1654.        
  1655.         new Handle:menu = CreateMenu(MenuHandlerShowCredits);
  1656.         SetMenuTitle(menu, "%t","Players Credits");
  1657.        
  1658.         for(new i=1;i<=MaxClients;i++)
  1659.         {
  1660.                 if (IsClientInGame(i))
  1661.                 {
  1662.                         GetClientName(i, sName, sizeof(sName));
  1663.                         IntToString(GetClientUserId(i), sUserId, sizeof(sUserId));
  1664.                         decl String:buffer[255];
  1665.                         Format(buffer, sizeof(buffer), "%s: %d", sName, g_iCreditos[i]);
  1666.                         AddMenuItem(menu, sUserId, buffer, ITEMDRAW_DISABLED );                 //sUserID to id_usera, a sName to nick ktory sie wyswietla w Menu
  1667.                 }
  1668.         }
  1669.        
  1670.         SetMenuExitButton(menu, true);
  1671.         DisplayMenu(menu, client, 20);
  1672.        
  1673.         return Plugin_Handled;
  1674. }
  1675.  
  1676. public MenuHandlerShowCredits(Handle:menu, MenuAction:action, param1, param2)
  1677. {
  1678.  
  1679. }
  1680.  
  1681. GetAllPlayersCount()
  1682. {
  1683.   decl iCount, i; iCount = 0;
  1684.  
  1685.   for( i = 1; i <= MaxClients; i++ )
  1686.     if( IsClientInGame( i ) && !IsFakeClient(i) )
  1687.       iCount++;
  1688.   return iCount;
  1689. }
  1690.  
  1691. bool:IsPlayerReservationAdmin(client)
  1692. {
  1693.     if (CheckCommandAccess(client, "Admin_Reservation", ADMFLAG_RESERVATION, false))
  1694.     {
  1695.         return true;
  1696.     }
  1697.     return false;
  1698. }
  1699.  
  1700.  

Replies to Untitled rss

Title Name Language When
shop_jail GhostPanterra cpp 4 Years ago.