Remove support for the OS_NPC constant. That one seems to be overly paranoid

to have and confuses the issue.
avinationmerge
Melanie 2012-07-25 01:28:11 +01:00
parent d69f186f5a
commit af05aaaf36
2 changed files with 2 additions and 4 deletions

View File

@ -68,7 +68,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins
private const int AGENT = 1; private const int AGENT = 1;
private const int AGENT_BY_USERNAME = 0x10; private const int AGENT_BY_USERNAME = 0x10;
private const int NPC = 0x20; private const int NPC = 0x20;
private const int OS_NPC = 0x01000000;
private const int ACTIVE = 2; private const int ACTIVE = 2;
private const int PASSIVE = 4; private const int PASSIVE = 4;
private const int SCRIPTED = 8; private const int SCRIPTED = 8;
@ -221,7 +220,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins
List<SensedEntity> sensedEntities = new List<SensedEntity>(); List<SensedEntity> sensedEntities = new List<SensedEntity>();
// Is the sensor type is AGENT and not SCRIPTED then include agents // Is the sensor type is AGENT and not SCRIPTED then include agents
if ((ts.type & (AGENT | AGENT_BY_USERNAME | NPC | OS_NPC)) != 0 && (ts.type & SCRIPTED) == 0) if ((ts.type & (AGENT | AGENT_BY_USERNAME | NPC)) != 0 && (ts.type & SCRIPTED) == 0)
{ {
sensedEntities.AddRange(doAgentSensor(ts)); sensedEntities.AddRange(doAgentSensor(ts));
} }
@ -485,7 +484,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api.Plugins
// "[SENSOR REPEAT]: Inspecting scene presence {0}, type {1} on sensor sweep for {2}, type {3}", // "[SENSOR REPEAT]: Inspecting scene presence {0}, type {1} on sensor sweep for {2}, type {3}",
// presence.Name, presence.PresenceType, ts.name, ts.type); // presence.Name, presence.PresenceType, ts.name, ts.type);
if ((ts.type & NPC) == 0 && (ts.type & OS_NPC) == 0 && presence.PresenceType == PresenceType.Npc) if ((ts.type & NPC) == 0 && presence.PresenceType == PresenceType.Npc)
{ {
INPC npcData = npcModule.GetNPC(presence.UUID, presence.Scene); INPC npcData = npcModule.GetNPC(presence.UUID, presence.Scene);
if (npcData == null || !npcData.SenseAsAgent) if (npcData == null || !npcData.SenseAsAgent)

View File

@ -56,7 +56,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
public const int ACTIVE = 2; public const int ACTIVE = 2;
public const int PASSIVE = 4; public const int PASSIVE = 4;
public const int SCRIPTED = 8; public const int SCRIPTED = 8;
public const int OS_NPC = 0x01000000;
public const int CONTROL_FWD = 1; public const int CONTROL_FWD = 1;
public const int CONTROL_BACK = 2; public const int CONTROL_BACK = 2;