NET:LavishScriptAPI.LavishScriptObject.GetValue

From Lavish Software Wiki
Revision as of 22:57, 16 December 2006 by Lax (talk | contribs)
(diff) ←Older revision | view current revision (diff) | Newer revision→ (diff)
Jump to navigation Jump to search

Overview

Performs the equivalent of Object.ToString, converting the result to the desired type.

Reference Library

Lavish.InnerSpace.dll

Fully Qualified Name

LavishScriptAPI.LavishScript.Objects.GetObject

Declaration

public T GetValue<T>()

Parameters

None

Return Value

  • T
The converted result of LavishScript's "ToString" operation on the LavishScript object.

Examples

Frame.Lock();
LavishScriptObject Obj = LavishScript.Objects.GetObject("LavishScript");
if (Obj == null)
{
    InnerSpace.Echo("object not found");
}
else
{
    /* "LavishScript" object's ToString value is its version number, which follows the form of a typical float */
    float Version = Obj.GetValue<float>();
    InnerSpace.Echo("LavishScript Version " + Version.ToString());
}
Frame.Unlock();

See Also