Difference between revisions of "ActionScript:ExternalCommands.GetValue"

From Dragon Age Toolset Wiki
Jump to: navigation, search
(Update using new template. Usage example to follow.)
 
(Description added.)
Line 3: Line 3:
 
{{asfunction
 
{{asfunction
 
|name=GetValue
 
|name=GetValue
|brief=Returns the requested token value from the engine
+
|brief=Returns the requested attribute value from the game engine
 
|param1name=a_sAttributeName
 
|param1name=a_sAttributeName
|param1desc=The token string associated with the value to retrieve
+
|param1desc=The hierarchical attribute-string associated with the value to retrieve
|returndesc=The requested token value
+
|returndesc=The requested attribute value from the game engine
 
}}
 
}}
 +
 +
== Description ==
 +
The attribute name is a string which has meaning to the game engine. It's typically hierarchical, using dots to separate the levels.
 +
 +
For example, <code>ExternalCommands.GetValue("ClientOptions.VideoOptions.Gamma")</code> would return the gamma setting in the user's DragonAge.ini file.
 +
 +
If the retrieved value is to be passed back to the game and is a number, you must instead use [[ActionScript:ExternalCommands.GetNumber|GetNumber]] or convert the value back into a Number type first.
  
 
[[Category:ActionScript:Functions]]
 
[[Category:ActionScript:Functions]]
 
[[Category:ActionScript]]
 
[[Category:ActionScript]]
 
[[Category:GUI]]
 
[[Category:GUI]]

Revision as of 19:45, 13 December 2009

A class method of the ExternalCommands ActionScript class.

Returns the requested attribute value from the game engine

GetValue(

a_sAttributeName

);

Parameters:
a_sAttributeName
The hierarchical attribute-string associated with the value to retrieve

Returns:
The requested attribute value from the game engine


Description

The attribute name is a string which has meaning to the game engine. It's typically hierarchical, using dots to separate the levels.

For example, ExternalCommands.GetValue("ClientOptions.VideoOptions.Gamma") would return the gamma setting in the user's DragonAge.ini file.

If the retrieved value is to be passed back to the game and is a number, you must instead use GetNumber or convert the value back into a Number type first.