Raised This Month: $ Target: $400
 0% 

Show Clip-Ammo by HUDmsg


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 06-29-2012 , 03:06   Re: Show Clip-Ammo by HUDmsg
Reply With Quote #6

Quote:
Originally Posted by yokomo View Post
But in your code it only cap BP ammo at 254. Any idea how to get the true value that > 254?
You tested it ?

If you have tested and that it doesn't work, replace :

PHP Code:
public Event_AmmoX(id)
{
    
g_iBpAmmo[id][read_data(1)] = read_data(2)

with

PHP Code:
new const m_rgAmmo_CBasePlayer[15] = {376,377,...} 

public 
Event_AmmoX(id)
{
    new 
iAmmoIndex read_data(1)
    
g_iBpAmmo[id][iAmmoIndex] = get_pdata_int(idm_rgAmmo_CBasePlayer[iAmmoIndex])


You can do the same here :

PHP Code:
public Event_Health(id)
{
    
g_iHealth[id] = read_data(1)

to

PHP Code:
public Event_Health(id)
{
    
g_iHealth[id] = get_user_health(id)


I'm pretty sure that for Health event, passed value is real health value and not mask, should be the same for AmmoX.
__________________
- tired and retired -

- my plugins -

Last edited by ConnorMcLeod; 06-29-2012 at 03:10.
ConnorMcLeod is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:08.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode