Scorpio.Script.CreateDouble C# (CSharp) Method

CreateDouble() public method

public CreateDouble ( double value ) : ScriptNumber
value double
return ScriptNumber
        public ScriptNumber CreateDouble(double value)
        {
            return new ScriptNumberDouble(this, value);
        }
        public ScriptArray CreateArray()

Usage Example

        public static void Load(Script script) {
            ScriptTable Table = script.CreateTable();
			Table.SetValue("PI", script.CreateDouble(PI));
			Table.SetValue("Deg2Rad", script.CreateDouble(Deg2Rad));
			Table.SetValue("Rad2Deg", script.CreateDouble(Rad2Deg));
			Table.SetValue("Epsilon", script.CreateDouble(Epsilon));
			Table.SetValue("min", script.CreateFunction(new min()));
			Table.SetValue("max", script.CreateFunction(new max()));
			Table.SetValue("abs", script.CreateFunction(new abs()));
			Table.SetValue("floor", script.CreateFunction(new floor()));
			Table.SetValue("clamp", script.CreateFunction(new clamp()));
			Table.SetValue("sqrt", script.CreateFunction(new sqrt()));
			Table.SetValue("pow", script.CreateFunction(new pow()));
            script.SetObjectInternal("math", Table);
        }
All Usage Examples Of Scorpio.Script::CreateDouble