auto change weapon.txt

来自「* first open client.cpp and search for t」· 文本 代码 · 共 47 行

TXT
47
字号
in Client.cpp 

add 

Code: 
static bool bChangeWEAPON=false; 


find 

Code: 
void CL_CreateMove (float frametime, struct usercmd_s *usercmd, int active) 


add code: 
Code: 
// auto change weapon 
   if (!me.iClip && me.alive) 
   { 

      if (currentWeaponID == WEAPON_SCOUT || currentWeaponID == WEAPON_M3 || currentWeaponID == WEAPON_SG550 || currentWeaponID == WEAPON_AWP || currentWeaponID == WEAPON_G3SG1) 
      { 
         if (!bChangeWEAPON) 
         { 
         cmd.exec("#slot2"); 
         bChangeWEAPON = true; 
         } 
         else 
         { 
            usercmd->buttons &= (~IN_ATTACK); 
         } 
      } 
   } 

   //changed reload 
   if (me.iClip && me.alive) 
   { 

      if (currentWeaponID==WEAPON_SCOUT || currentWeaponID==WEAPON_M3 || currentWeaponID==WEAPON_SG550 || currentWeaponID== WEAPON_AWP || currentWeaponID == WEAPON_G3SG1) 
      { 
         if (bChangeWEAPON) 
         { 
         bChangeWEAPON = false; 
         } 
      } 
   } 

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?