hlmod.hu
https://hlmod.hu/

SMA átírás
https://hlmod.hu/viewtopic.php?f=9&t=2959
Oldal: 1 / 1

Szerző:  imikeeee2 [2011.12.24. 10:31 ]
Hozzászólás témája:  SMA átírás

Üdv ezt valaki átírná nekem h ne armor-t hanem defuset valamit (hatástalanító) adjon?

Kód:
#include <amxmodx>
#include <cstrike>
#include <hamsandwich>

new gCvarArmor;
new gCvarAmount;

public plugin_init() {
   register_plugin( "Spawn with Armor", "1.0", "xPaw" );
   
   gCvarArmor = register_cvar( "sv_armor",   "2" );
   gCvarAmount = register_cvar( "sv_armor_amount",   "100" );
   
   RegisterHam( Ham_Spawn, "player", "fwdPlayerSpawn", 1 );
}

public fwdPlayerSpawn( id ) {
   if( is_user_alive( id ) ) {
      new iPluginArmorType = clamp( get_pcvar_num( gCvarArmor ), 0, 2 );
      
      if( iPluginArmorType > 0 ) {
         new CsArmorType:iPlayerArmorType;
         new iPlayerAmount = cs_get_user_armor( id, iPlayerArmorType );
         new iPluginAmount = min( get_pcvar_num( gCvarAmount ), 0xFF );

         cs_set_user_armor( id, max( iPluginAmount, iPlayerAmount ), CsArmorType:max( iPluginArmorType, _:iPlayerArmorType ) );
      }
   }
}

Szerző:  kiki [2011.12.24. 10:37 ]
Hozzászólás témája:  Re: SMA átírás

Kód:
#include <amxmodx>
#include <cstrike>
#include <hamsandwich>

public plugin_init() {
   register_plugin( "Ingyen Hatastalanito", "1.0", "kiki33" );
   
   RegisterHam( Ham_Spawn, "player", "fwdPlayerSpawn", 1 );
}

public fwdPlayerSpawn( id )
{
   if( is_user_alive( id ) )
    {
      if(cs_get_user_team(id) == CS_TEAM_CT)
      {
      cs_set_user_defuse(id, 1, 0, 160, 0)
      } 
    }   
}


Csak ctknek ad

Szerző:  imikeeee2 [2011.12.24. 16:21 ]
Hozzászólás témája:  Re: SMA átírás

kiki írta:
Kód:
#include <amxmodx>
#include <cstrike>
#include <hamsandwich>

public plugin_init() {
   register_plugin( "Ingyen Hatastalanito", "1.0", "kiki33" );
   
   RegisterHam( Ham_Spawn, "player", "fwdPlayerSpawn", 1 );
}

public fwdPlayerSpawn( id )
{
   if( is_user_alive( id ) )
    {
      if(cs_get_user_team(id) == CS_TEAM_CT)
      {
      cs_set_user_defuse(id, 1, 0, 160, 0)
      } 
    }   
}


Csak ctknek ad



THX (am gondoltam :))

Oldal: 1 / 1 Minden időpont UTC+02:00 időzóna szerinti
Powered by phpBB® Forum Software © phpBB Limited
https://www.phpbb.com/