Mantis #2230
The result of constants arithmetic can be a CLI type. This allows floating point CLI types to be parsed out of lists properly.0.6.0-stable
parent
4ce0e6d822
commit
8407d7fbd2
|
@ -436,6 +436,18 @@ namespace OpenSim.Region.ScriptEngine.Shared
|
||||||
{
|
{
|
||||||
return (LSL_Types.LSLInteger)m_data[itemIndex];
|
return (LSL_Types.LSLInteger)m_data[itemIndex];
|
||||||
}
|
}
|
||||||
|
else if (m_data[itemIndex] is Int32)
|
||||||
|
{
|
||||||
|
return new LSL_Types.LSLFloat((int)m_data[itemIndex]);
|
||||||
|
}
|
||||||
|
else if (m_data[itemIndex] is float)
|
||||||
|
{
|
||||||
|
return new LSL_Types.LSLFloat((float)m_data[itemIndex]);
|
||||||
|
}
|
||||||
|
else if (m_data[itemIndex] is Double)
|
||||||
|
{
|
||||||
|
return new LSL_Types.LSLFloat((Double)m_data[itemIndex]);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return (LSL_Types.LSLFloat)m_data[itemIndex];
|
return (LSL_Types.LSLFloat)m_data[itemIndex];
|
||||||
|
|
Loading…
Reference in New Issue