some types may already be native in MOD_Api ConvertFromLSL

This commit is contained in:
UbitUmarov
2016-11-05 20:14:11 +00:00
parent 22d20dbf17
commit 8cc8d15f95
3 changed files with 7 additions and 3 deletions

View File

@@ -365,8 +365,12 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
/// </summary>
protected object ConvertFromLSL(object lslparm, Type type, string fname)
{
if(lslparm.GetType() == type)
return lslparm;
// ---------- String ----------
if (lslparm is LSL_String)
else if (lslparm is LSL_String)
{
if (type == typeof(string))
return (string)(LSL_String)lslparm;