mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 00:46:02 +08:00
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.
This commit is contained in:
@@ -436,6 +436,18 @@ namespace OpenSim.Region.ScriptEngine.Shared
|
||||
{
|
||||
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
|
||||
{
|
||||
return (LSL_Types.LSLFloat)m_data[itemIndex];
|
||||
|
||||
Reference in New Issue
Block a user