Raised This Month: $51 Target: $400
 12% 

[Help] hud to dhud


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
black_heart
Senior Member
Join Date: May 2015
Old 08-23-2015 , 15:29   [Help] hud to dhud
Reply With Quote #1

how to make this code to dhud?

PHP Code:
    // Spectating someone else?
    
if (id != ID_SHOWHUD)
    {
        
// Show name, health, class, and ammo packs
        
set_hudmessage(255255255HUD_SPECT_XHUD_SPECT_Y06.01.10.00.0, -1)
        
show_hudmessage(ID_SHOWHUD,  "%L %s^nHP: %d - %L %s - %L %d"ID_SHOWHUD"SPECTATING"g_playername[id], pev(idpev_health), ID_SHOWHUD"CLASS_CLASS", class, ID_SHOWHUD"AMMO_PACKS1"g_ammopacks[id])
    }
    else
    {
        
// Show health, class and ammo packs
        
set_hudmessage(redgreenblue0.000.1806.01.10.00.0, -1)
        
show_hudmessage(ID_SHOWHUD"[%L: %d]^n[%L %s]^n[%L %d]"id"ZOMBIE_ATTRIB1"pev(ID_SHOWHUDpev_health), ID_SHOWHUD"CLASS_CLASS", class, ID_SHOWHUD"AMMO_PACKS1"g_ammopacks[ID_SHOWHUD])
    } 

Last edited by black_heart; 08-23-2015 at 15:48.
black_heart is offline
Send a message via Skype™ to black_heart
siriusmd99
Veteran Member
Join Date: Oct 2013
Location: Republic of Moldova
Old 08-23-2015 , 15:33   Re: [Help] hud to dhud
Reply With Quote #2

Just change set_dhudmessage to set_hudmessage
Note: dhudmessage is used only on show not on set
siriusmd99 is offline
black_heart
Senior Member
Join Date: May 2015
Old 08-23-2015 , 16:54   Re: [Help] hud to dhud
Reply With Quote #3

Quote:
Originally Posted by siriusmd99 View Post
Just change set_dhudmessage to set_hudmessage
Note: dhudmessage is used only on show not on set
i mean set_hudmessage to dhudmessage..
black_heart is offline
Send a message via Skype™ to black_heart
wickedd
Veteran Member
Join Date: Nov 2009
Old 08-23-2015 , 17:12   Re: [Help] hud to dhud
Reply With Quote #4

Read this
__________________
Just buy the fucking game!!!!
I hate No-Steamers and lazy ass people.
wickedd is offline
siriusmd99
Veteran Member
Join Date: Oct 2013
Location: Republic of Moldova
Old 08-23-2015 , 17:21   Re: [Help] hud to dhud
Reply With Quote #5

Quote:
Originally Posted by black_heart View Post
how to make this code to dhud?
Download dhudmessage.inc and move it to includes folder. (Download link in the previous post)
After that compile this script:
PHP Code:
//dont forget to add include file at the top
include <dhudmessage>
    
// Spectating someone else?
    
if (id != ID_SHOWHUD)
    {
        
// Show name, health, class, and ammo packs
        
set_dhudmessage(255255255HUD_SPECT_XHUD_SPECT_Y06.01.10.00.0, -1)
        
show_dhudmessage(ID_SHOWHUD,  "%L %s^nHP: %d - %L %s - %L %d"ID_SHOWHUD"SPECTATING"g_playername[id], pev(idpev_health), ID_SHOWHUD"CLASS_CLASS", class, ID_SHOWHUD"AMMO_PACKS1"g_ammopacks[id])
    }
    else
    {
        
// Show health, class and ammo packs
        
set_dhudmessage(redgreenblue0.000.1806.01.10.00.0, -1)
        
show_dhudmessage(ID_SHOWHUD"[%L: %d]^n[%L %s]^n[%L %d]"id"ZOMBIE_ATTRIB1"pev(ID_SHOWHUDpev_health), ID_SHOWHUD"CLASS_CLASS", class, ID_SHOWHUD"AMMO_PACKS1"g_ammopacks[ID_SHOWHUD])
    } 

Last edited by siriusmd99; 08-23-2015 at 17:23.
siriusmd99 is offline
black_heart
Senior Member
Join Date: May 2015
Old 08-24-2015 , 03:42   Re: [Help] hud to dhud
Reply With Quote #6

Quote:
Originally Posted by siriusmd99 View Post
Download dhudmessage.inc and move it to includes folder. (Download link in the previous post)
After that compile this script:
PHP Code:
//dont forget to add include file at the top
include <dhudmessage>
    
// Spectating someone else?
    
if (id != ID_SHOWHUD)
    {
        
// Show name, health, class, and ammo packs
        
set_dhudmessage(255255255HUD_SPECT_XHUD_SPECT_Y06.01.10.00.0, -1)
        
show_dhudmessage(ID_SHOWHUD,  "%L %s^nHP: %d - %L %s - %L %d"ID_SHOWHUD"SPECTATING"g_playername[id], pev(idpev_health), ID_SHOWHUD"CLASS_CLASS", class, ID_SHOWHUD"AMMO_PACKS1"g_ammopacks[id])
    }
    else
    {
        
// Show health, class and ammo packs
        
set_dhudmessage(redgreenblue0.000.1806.01.10.00.0, -1)
        
show_dhudmessage(ID_SHOWHUD"[%L: %d]^n[%L %s]^n[%L %d]"id"ZOMBIE_ATTRIB1"pev(ID_SHOWHUDpev_health), ID_SHOWHUD"CLASS_CLASS", class, ID_SHOWHUD"AMMO_PACKS1"g_ammopacks[ID_SHOWHUD])
    } 
when im compile it show me 4 warnings .. Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Warning: Loose indentation on line 10225
Warning: Tag mismatch on line 10228
Warning: Tag mismatch on line 10234
Warning: Symbol is assigned a value that is never used: "g_MsgSync2" on line 13206
Header size: 8304 bytes
Code size: 393128 bytes
Data size: 191916 bytes
Stack/heap size: 16384 bytes; max. usage is unknown, due to recursion
Total requirements: 609732 bytes

4 Warnings.
Done.
black_heart is offline
Send a message via Skype™ to black_heart
black_heart
Senior Member
Join Date: May 2015
Old 08-24-2015 , 04:24   Re: [Help] hud to dhud
Reply With Quote #7

Quote:
Originally Posted by wickedd View Post
i read it but im not so good in scripting ..
black_heart is offline
Send a message via Skype™ to black_heart
siriusmd99
Veteran Member
Join Date: Oct 2013
Location: Republic of Moldova
Old 08-24-2015 , 04:55   Re: [Help] hud to dhud
Reply With Quote #8

You didnt post the full script ,you have warnings on other sequences of script , not this.
siriusmd99 is offline
Reply



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 23:24.


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