Raised This Month: $ Target: $400
 0% 

Several Arguments for show_hudmessage?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Mandiii
Junior Member
Join Date: Jun 2010
Old 06-10-2010 , 08:01   Several Arguments for show_hudmessage?
Reply With Quote #1

Is it possible to write something along these lines:

PHP Code:
show_hudmessage(0killer" has eaten "hamburgers[killer], " hamburgers"
Mandiii is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 06-10-2010 , 08:07   Re: Several Arguments for show_hudmessage?
Reply With Quote #2

show_hudmessage(0, killer, " has eaten %d hamburgers", hamburgers[killer])
__________________
Arkshine is offline
Sylwester
Veteran Member
Join Date: Oct 2006
Location: Poland
Old 06-10-2010 , 08:37   Re: Several Arguments for show_hudmessage?
Reply With Quote #3

You made little mistake.
PHP Code:
new name[32]
get_user_name(killername31)
show_hudmessage(0"%s has eaten %d hamburgers"namehamburgers[killer]) 
__________________
Impossible is Nothing
Sylwester is offline
Mandiii
Junior Member
Join Date: Jun 2010
Old 06-10-2010 , 10:18   Re: Several Arguments for show_hudmessage?
Reply With Quote #4

Could you give me a brief explanation why you are writing %d and %s.
Mandiii is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 06-10-2010 , 12:48   Re: Several Arguments for show_hudmessage?
Reply With Quote #5

%s means you want to put a string in there.
%d means a number.
%i means integer value.
%f.1 means a float and 1 means how many numbers behind . will be shown. i'm not completely sure about %d someone else could explain it
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
Brreaker
Senior Member
Join Date: Oct 2009
Location: Constanta, Romania
Old 06-10-2010 , 12:55   Re: Several Arguments for show_hudmessage?
Reply With Quote #6

%d comes from data, but it prints only integers so you can use %d or %i in the same circumstances
__________________
There are 10 kinds of people.Those who understand binary, and those who don't.
Also, for those who understand binary, there is a donation tab too!
No steam || PM support!
Brreaker is offline
Send a message via MSN to Brreaker Send a message via Yahoo to Brreaker
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 05:24.


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