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

Message color


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
MihailoZ
Member
Join Date: Aug 2013
Old 09-04-2019 , 10:15   Message color
Reply With Quote #1

I would like to edit the color of this message "show_hudmessage(plr, "Ready Or Not, Here We Come!");"

This is the code.

Code:
team = cs_get_user_team(plr);
			if( team == HNS_TEAM_SEEKER || team == HNS_TEAM_HIDER )
			{
				if( team == HNS_TEAM_SEEKER && g_bAlive[plr] )
				{
					make_ScreenFade(plr, 0.0, 0.0, 0, 0, 0, 255);
					
					cs_reset_user_maxspeed(plr);
					//set_pev(plr, pev_flags, pev(plr, pev_flags) & ~FL_FROZEN);
				}
				
				set_hudmessage(hud_red, hud_green, hud_blue, -1.0, -1.0, 0, 0.0, 3.0, 0.1, 0.1, 1);
				show_hudmessage(plr, "Ready Or Not, Here We Come!");
				
				param[0] = _:team;
				taskGiveWeapons(param, plr + TASK_ID_GIVEWEAPONS)
__________________
mhvtnns
MihailoZ is offline
MihailoZ
Member
Join Date: Aug 2013
Old 09-04-2019 , 10:21   Re: Message color
Reply With Quote #2

Is it okay if I just change hud_red, hud_green, hud_blue ?
__________________
mhvtnns
MihailoZ is offline
SHIELD755
Veteran Member
Join Date: Feb 2018
Location: FROM MARVEL STUDIO
Old 09-04-2019 , 10:31   Re: Message color
Reply With Quote #3

Quote:
Originally Posted by MihailoZ View Post
Is it okay if I just change hud_red, hud_green, hud_blue ?
you must write RGB color code , in place of hud_red , hud_green, hud_blue
for example :-

RED Color hud (255,0,0)

PHP Code:
set_hudmessage(25500, -1.0, -1.000.03.00.10.11);
        
show_hudmessage(plr"Ready Or Not, Here We Come!"); 
you can get color code from here CLICK HERE
__________________
SED LYF !!!
SHIELD755 is offline
DON KHAN 1
Senior Member
Join Date: Mar 2019
Location: Pakistan
Old 09-04-2019 , 11:37   Re: Message color
Reply With Quote #4

another example is using colors by const them with HUD_COLOR.

put this
PHP Code:
new const HUD_COLOR[3] = {255 0
then use this code.

PHP Code:
team cs_get_user_team(plr);
            if( 
team == HNS_TEAM_SEEKER || team == HNS_TEAM_HIDER )
            {
                if( 
team == HNS_TEAM_SEEKER && g_bAlive[plr] )
                {
                    
make_ScreenFade(plr0.00.0000255);
                    
                    
cs_reset_user_maxspeed(plr);
                    
//set_pev(plr, pev_flags, pev(plr, pev_flags) & ~FL_FROZEN);
                
}
                
                
set_hudmessage(HUD_COLOR[0], HUD_COLOR[1], HUD_COLOR[2], -1.0, -1.000.03.00.10.11);
                
show_hudmessage(plr"Ready Or Not, Here We Come!");
                
                
param[0] = _:team;
                
taskGiveWeapons(paramplr TASK_ID_GIVEWEAPONS
this will help u for random color hud message.
__________________
Facebook
My YouTube
Ro{Y}aL WarLanD CommuniTy
Selling Zombie CSO 4.3 Money System Mod

Last edited by DON KHAN 1; 09-04-2019 at 11:38.
DON KHAN 1 is offline
LearninG
Senior Member
Join Date: Apr 2019
Location: Iran
Old 09-04-2019 , 11:55   Re: Message color
Reply With Quote #5

Quote:
Originally Posted by DON KHAN 1 View Post
this will help u for random color hud message.
how is this supposed to make random colors ?
Code:
new const HUD_COLOR[3] = {0 , 255 , 0}
LearninG is offline
thEsp
BANNED
Join Date: Aug 2017
Old 09-04-2019 , 12:11   Re: Message color
Reply With Quote #6

Quote:
Originally Posted by LearninG View Post
how is this supposed to make random colors ?
Code:
new const HUD_COLOR[3] = {0 , 255 , 0}
By rote.
Quote:
Originally Posted by DON KHAN 1 View Post
another example is using colors by const them with HUD_COLOR.
What "const them" means tho?

Last edited by thEsp; 09-04-2019 at 12:13.
thEsp is offline
I AM NOOB
Junior Member
Join Date: May 2019
Location: NEPAL BOARDER
Old 09-04-2019 , 12:20   Re: Message color
Reply With Quote #7

Quote:
Originally Posted by DON KHAN 1 View Post
this will help u for random color hud message.
For random number why don't use random_num(0,255)
__________________
"Never think yourself as successfull ror DON because "
DON stands for DONKEY OF NATION

GIVE RESPECT = TAKE RESPECT

ONLY SIGNATURE , NO PERSONAL
I AM NOOB is offline
LearninG
Senior Member
Join Date: Apr 2019
Location: Iran
Old 09-04-2019 , 12:50   Re: Message color
Reply With Quote #8

Quote:
Originally Posted by thEsp View Post
By rote.
I didn't understand , sorry.


Quote:
Originally Posted by I AM NOOB View Post
For random number why don't use random_num(0,255)
why not ? :
Code:
random(255)


btw i see somewhere
Code:
random(256)
which is right ?
LearninG is offline
DON KHAN 1
Senior Member
Join Date: Mar 2019
Location: Pakistan
Old 09-04-2019 , 13:53   Re: Message color
Reply With Quote #9

Quote:
"Never think yourself as successfull ror DON because "
DON stands for DONKEY OF NATION

GIVE RESPECT = TAKE RESPECT

"Adding much reply in forum will not make you veteran Member"

ONLY SIGNATURE , NO PERSONAL
Ahahah thank u for giving me lot of request ... but NVM cuz i don't mind theme types of my insult & about veteran member as u can see my posts & can understand how i got this.

anyways thEsp i added const them by mistake sorry about that.

LearninG i also saw them in plugins but mostly random(255) but not pretty confirm which is right.
__________________
Facebook
My YouTube
Ro{Y}aL WarLanD CommuniTy
Selling Zombie CSO 4.3 Money System Mod
DON KHAN 1 is offline
thEsp
BANNED
Join Date: Aug 2017
Old 09-04-2019 , 17:57   Re: Message color
Reply With Quote #10

Quote:
"Adding much reply in forum will not make you veteran Member"
Posting insultive and useless replies in this forum won't help you become a veteran member. You are here just to provoke and insult other people no matter who they are. Bullshit posting won't help you in any case, just thank god there is no admin active at the moment...
thEsp 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 07:30.


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