Raised This Month: $32 Target: $400
 8% 

Hud message in the date


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Dimanok
Junior Member
Join Date: Jan 2010
Old 08-21-2010 , 15:03   Hud message in the date
Reply With Quote #1

Hello! Prompt please how to do that by setting the date, this day gotten all the players when they join the server any HUD message.
If it can be an example. Thank you
Dimanok is offline
nikhilgupta345
Veteran Member
Join Date: Aug 2009
Location: Virginia
Old 08-21-2010 , 18:43   Re: Hud message in the date
Reply With Quote #2

first, you would declare an array date[9]
then, use get_time

then, set_hudmessage
then, show_hudmessage with %s, date in teh message.
nikhilgupta345 is offline
Send a message via ICQ to nikhilgupta345 Send a message via Yahoo to nikhilgupta345
SpeeDeeR
Veteran Member
Join Date: Mar 2010
Location: Bulgaria
Old 08-22-2010 , 08:34   Re: Hud message in the date
Reply With Quote #3

Quote:
Originally Posted by nikhilgupta345 View Post
first, you would declare an array date[9]
then, use get_time

then, set_hudmessage
then, show_hudmessage with %s, date in teh message.
Very very discriptive! Good work

PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>

#define PLUGIN "Date in HUD"
#define VERSION "1.0"
#define AUTHOR "SpeeD"


public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
// Add your code here...
}

public 
client_putinserver(id)
{
    
set_task(8.0,"HudDate",id)
}

public 
HudDate(id)
{
    new 
cdate[9]
    
get_time("%d/%m/%Y",cdate,8)
    
set_hudmessage(002550.300.1406.012.0)
    
show_hudmessage(id"Current date is %s",cdate)

SpeeDeeR is offline
RedRobster
Veteran Member
Join Date: Apr 2010
Location: Your Closet
Old 08-22-2010 , 10:23   Re: Hud message in the date
Reply With Quote #4

It actually was descriptive. He said to do exactly what you did for the most part. Only difference is he was actually trying to help Dimanok by having him do it by himself.

Last edited by RedRobster; 08-22-2010 at 12:18.
RedRobster is offline
Dimanok
Junior Member
Join Date: Jan 2010
Old 08-22-2010 , 11:06   Re: Hud message in the date
Reply With Quote #5

All thanks, i'm just learning codding.
Dimanok is offline
nikhilgupta345
Veteran Member
Join Date: Aug 2009
Location: Virginia
Old 08-22-2010 , 22:09   Re: Hud message in the date
Reply With Quote #6

Quote:
Originally Posted by RedRobster View Post
It actually was descriptive. He said to do exactly what you did for the most part. Only difference is he was actually trying to help Dimanok by having him do it by himself.

nikhilgupta345 is offline
Send a message via ICQ to nikhilgupta345 Send a message via Yahoo to nikhilgupta345
Reply


Thread Tools
Display Modes

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 03:05.


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