Raised This Month: $ Target: $400
 0% 

%f %c ^n ????????????????


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
~ScORpY
Senior Member
Join Date: Sep 2009
Location: Norway, bergen
Old 11-26-2009 , 08:12   %f %c ^n ????????????????
Reply With Quote #1

hi im new at scripting and i was wondering what thos sins mean :S

%f %c and all that stuff...

can some one give me a list of %(letter) and what they do?

thanks =)
~ScORpY is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 11-26-2009 , 08:22   Re: %f %c ^n ????????????????
Reply With Quote #2

Format tag that are replaced by the values specified. All natives which can format. Here a c++ function which format a string. It quite the same except some tag which won't work on amxx. You can see some examples using format(). ( %L is for Multilingual, search if you want to learn more )

Next time, post in scripting section.
__________________

Last edited by Arkshine; 11-26-2009 at 08:30.
Arkshine is offline
~ScORpY
Senior Member
Join Date: Sep 2009
Location: Norway, bergen
Old 11-26-2009 , 08:32   Re: %f %c ^n ????????????????
Reply With Quote #3

THANKS!!!
didnt know that it was c++

and ill do that next time =)
~ScORpY is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 11-26-2009 , 08:46   Re: %f %c ^n ????????????????
Reply With Quote #4

I've showed you a c++ function because there was a list of different format tag. [flags], [width] and [.precision] work too. Not all the format tag will work though. It was more convenient to show that directly since the syntax is the same. The available format tag for Amxx are %c, %f, %d, %i, %s, %L, %x, %a, if I'm right.
__________________

Last edited by Arkshine; 11-27-2009 at 01:52.
Arkshine is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 11-26-2009 , 23:03   Re: %f %c ^n ????????????????
Reply With Quote #5

%a works for dynamic array handles. Example in mapchooser.sma.
__________________
fysiks is online now
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 11-27-2009 , 01:52   Re: %f %c ^n ????????????????
Reply With Quote #6

Ah yes, forget this one.
__________________
Arkshine is offline
~ScORpY
Senior Member
Join Date: Sep 2009
Location: Norway, bergen
Old 12-04-2009 , 15:59   Re: %f %c ^n ????????????????
Reply With Quote #7

thanks for the help

i love this forum <3
~ScORpY is offline
Belo95135
Member
Join Date: Jun 2012
Location: Slovakia
Old 12-06-2016 , 08:29   Re: %f %c ^n ????????????????
Reply With Quote #8

http://www.amxmodx.org/funcwiki.php?go=func&id=49
-->
Belo95135 is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 12-06-2016 , 15:09   Re: %f %c ^n ????????????????
Reply With Quote #9

http://www.amxmodx.org/api/string/format
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Napoleon_be
Veteran Member
Join Date: Jul 2011
Location: Belgium
Old 12-06-2016 , 16:48   Re: %f %c ^n ????????????????
Reply With Quote #10

difference between format & formatex?
__________________
Napoleon_be is offline
Send a message via Skype™ to Napoleon_be
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 00:55.


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