Attempt to fix Mantis #1804
Fetches the correct link part to chenge. Please provide feedback, since I was not able to test all variants of this huge function.0.6.0-stable
parent
f079af87dc
commit
db06e628de
|
@ -5286,30 +5286,17 @@ namespace OpenSim.Region.ScriptEngine.Common
|
||||||
|
|
||||||
public void llSetPrimitiveParams(LSL_Types.list rules)
|
public void llSetPrimitiveParams(LSL_Types.list rules)
|
||||||
{
|
{
|
||||||
llSetLinkPrimitiveParams(m_host.LinkNum+1, rules);
|
llSetLinkPrimitiveParams(m_host.LinkNum, rules);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void llSetLinkPrimitiveParams(int linknumber, LSL_Types.list rules)
|
public void llSetLinkPrimitiveParams(int linknumber, LSL_Types.list rules)
|
||||||
{
|
{
|
||||||
m_host.AddScriptLPS(1);
|
m_host.AddScriptLPS(1);
|
||||||
|
|
||||||
SceneObjectPart part=null;
|
if(m_host.ParentGroup == null)
|
||||||
|
return;
|
||||||
|
|
||||||
if (m_host.LinkNum+1 != linknumber)
|
SceneObjectPart part = m_host.ParentGroup.GetLinkNumPart(linknumber);
|
||||||
{
|
|
||||||
foreach (SceneObjectPart partInst in m_host.ParentGroup.GetParts())
|
|
||||||
{
|
|
||||||
if ((partInst.LinkNum) == linknumber)
|
|
||||||
{
|
|
||||||
part = partInst;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
part = m_host;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (part == null)
|
if (part == null)
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -5085,30 +5085,17 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
||||||
|
|
||||||
public void llSetPrimitiveParams(LSL_Types.list rules)
|
public void llSetPrimitiveParams(LSL_Types.list rules)
|
||||||
{
|
{
|
||||||
llSetLinkPrimitiveParams(m_host.LinkNum+1, rules);
|
llSetLinkPrimitiveParams(m_host.LinkNum, rules);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void llSetLinkPrimitiveParams(int linknumber, LSL_Types.list rules)
|
public void llSetLinkPrimitiveParams(int linknumber, LSL_Types.list rules)
|
||||||
{
|
{
|
||||||
m_host.AddScriptLPS(1);
|
m_host.AddScriptLPS(1);
|
||||||
|
|
||||||
|
if(m_host.ParentGroup == null)
|
||||||
|
return;
|
||||||
|
|
||||||
SceneObjectPart part=null;
|
SceneObjectPart part = m_host.ParentGroup.GetLinkNumPart(linknumber);
|
||||||
|
|
||||||
if (m_host.LinkNum+1 != linknumber)
|
|
||||||
{
|
|
||||||
foreach (SceneObjectPart partInst in m_host.ParentGroup.GetParts())
|
|
||||||
{
|
|
||||||
if ((partInst.LinkNum) == linknumber)
|
|
||||||
{
|
|
||||||
part = partInst;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
part = m_host;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (part == null)
|
if (part == null)
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue