Difference between revisions of "String variables"

From the Fallout3 GECK Wiki
Jump to navigation Jump to search
imported>Odessa
(Created page with "String variables are added by NVSE 4. A string is simply some combination of text characters and exists widely in the vanilla game. A string variable allows you to store a str...")
 
imported>Odessa
(cleaned up title with redirect)
 
Line 1: Line 1:
String variables are added by NVSE 4. A string is simply some combination of text characters and exists widely in the vanilla game. A string variable allows you to store a string in a similar way to any other variable, and a wide range of functions allow powerful capabilities for them.
#Redirect [[String Variable]]
 
String variables are very simple to use, provided you also use [[Let]] instead of [[Set]] and 'if [[Eval|eval]]' instead of simply 'if'. To appreciate the full range of possibilites available, a [[Tutorial: String Variables|tutorial]] is available.
 
==Simple Example==
<pre>
string_var my_string
 
let my_string := "this is my string"
 
MessageEx my_string
 
if eval my_string == "this string"
  ; do something. Obviously this is false in this case.
endif
</pre>
 
<pre>
string_var my_string
int MyInt
 
let MyInt := 5
let my_string := "the value of MyInt is %g", MyInt
</pre>
 
[[Category:String Variables]]
[[Category:NVSE]]

Latest revision as of 12:12, 27 June 2014

Redirect to: