⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 health.txt

📁 * first open client.cpp and search for that USER_MSG_INTERCEPT(TeamInfo) over it u add this
💻 TXT
字号:
* first open client.cpp and search for that USER_MSG_INTERCEPT(TeamInfo) 

over it u add this 

Code: 
USER_MSG_INTERCEPT(Health)  
{ 
     BEGIN_READ(pbuf,iSize); 
     me.iHealth = READ_BYTE(); 
     return USER_MSG_CALL(Health); 
} 


* then we search for int HookUserMsg (char *szMsgName, pfnUserMsgHook pfn) 

and add this 
Code: 
REDIRECT_MESSAGE( Health ) 


*k now we have the health registered and can read it out  i stop this hear know cuz i must thanks panzer and w00t.nl that they helped me with it first time! 

*ok now we go to int HUD_Redraw (float x, int y) and packing this draw code in it 

Code: 

int a = 20; 
int b = 750; 
int c = 765; 
DrawHudString(a,b,clr->r,clr->g,clr->b,"Health: %d",me.iHealth); // this code draws health on ur screen 
DrawHudString(a,c,clr->r,clr->g,clr->b,"Armor: %d",playerItems.armor); 
 
* open client.h and add this there in local_player_info 

Code: 

int iHealth; 
 
ffs no no edit button 

just change int a = 20; , int b; and int c; to 

Code: 

      int a = 20; 
      int b = displayCenterY*2-180-100; 
                                int c = displayCenterY*2-180-120; 

ColorEntry* clr5


//-----------------------------------------------------------------

if (cvar.health_esp==1)
	{
		int numBars = ceil(vPlayers[ax].hitpoints/2.0);
		ColorEntry* bar = colorList.get(43 + numBars);
		DrawHudStringCenter(x,y,bar->r,bar->g,bar->b,"%i hp",(short int)vPlayers[ax].hitpoints*10);
	}

// health
	int hitpoints;
	int health;
	bool kevlar;

enum    { MAX_HITPOINTS = 10 };
hitpoints = MAX_HITPOINTS;

⌨️ 快捷键说明

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