spacer graphic
spacer graphic
Montage of games AGS Logo
spacer graphic

 

spacer graphic
Menu
spacer graphic Home
About
News
Features
Download AGS
spacer graphic Games 
Games main page
Award Winners
Picks of the month
Short games
Medium length games
Full length games
In Production
Hints & Tips
Community
Forums
AGSers World Map
Member websites
Chat
Resources
Tutorials
FAQ
Knowledge Base
Downloads
Links
AGS-related links
* AGS Manual
  * Scripting
    * String functions

Format

(Formerly known as global function StrFormat, which is now obsolete)

static String.Format(string fmt, ...)
Processes the string FMT in the same way as the Display function does but instead of displaying it on the screen, returns the result as a new string.

You can insert the value of variables into the message. For more information, see the string formatting section.

NOTE: This function is static, which means you do not call it on an existing string variable, but use String.Format() instead.

Example:

int health=10;
String text = String.Format("%d", health);
will create a text string containing "10".

See Also: Display


User comments and notes
There are currently no user comments on this page.
The user comment facility is currently disabled.