Caches all SNO related data.
Inheritance: SNO
Exemple #1
0
        public DebugEntry(CachedSNOEntry entry)
        {
            SNOID = entry.SNOID;
            Name = entry.InternalName;
            ActorType = entry.Actortype.HasValue ? (PluginActorType)Enum.Parse(typeof(PluginActorType), entry.Actortype.Value.ToString()) : PluginActorType.Invalid;
            GizmoType = entry.Gizmotype.HasValue ? (PluginGizmoType)Enum.Parse(typeof(PluginGizmoType), entry.Gizmotype.Value.ToString()) : PluginGizmoType.None;
            TargetType = entry.targetType.HasValue ? entry.targetType.Value : TargetType.None;

            if (ActorType == PluginActorType.Item)
                DroppedItemType = ItemFunc.DetermineDroppedItemType(Name, SNOID);
        }
Exemple #2
0
 public CachedSNOEntry(CachedSNOEntry parent)
     : base(parent)
 {
 }
Exemple #3
0
            dateSinceTemporaryBlacklistClear = DateTime.Today;
            dateSincePermBlacklistClear = DateTime.Today;
        }

        internal static void IgnoreThisObject(CachedSNOEntry snoObj, int RAGUID, bool removal = true, bool blacklistSNOID = true)
        {
            //Logger.DBLog.InfoFormat("[Blacklist] -- RAGUID {0} SNOID {1} ({2})", snoObj.SNOID, RAGUID, snoObj.InternalName);

            int sno, raguid;
            sno = snoObj.SNOID;
            raguid = RAGUID;

            //Add to our blacklist so we don't create it again..
            hashRGUIDIgnoreBlacklist.Add(raguid);

            if (blacklistSNOID)
                //Blacklist SNO so we don't create it ever again!
                BlacklistSnoIDs.Add(sno);

            if (removal)
            {
                //Clear SNO cache entries..
                ObjectCache.cacheSnoCollection.Remove(snoObj.SNOID);
Exemple #4
0
        public void CheckEntry(CachedSNOEntry entry)
        {
            var d = new DebugEntry(entry);
            if (entry.Gizmotype.HasValue)
            {
                if (entry.Gizmotype.Value == GizmoType.Door)
                {
                    if (!FunkyBaseExtension.Settings.Debugging.DebuggingDataTypes.HasFlag(DebugDataTypes.Doors))
                        return;

                    if (Doors.Entries.Contains(d)) return;
                    Doors.Entries.Add(d);
                    DebugData_Doors.SerializeToXML(Doors);
                }
                else if (entry.Gizmotype.Value == GizmoType.Chest)
                {
                    if (!FunkyBaseExtension.Settings.Debugging.DebuggingDataTypes.HasFlag(DebugDataTypes.Containers))
                        return;

                    if (Containers.Entries.Contains(d)) return;
                    Containers.Entries.Add(d);
                    DebugData_Containers.SerializeToXML(Containers);
                }
                else if (entry.Gizmotype.Value == GizmoType.BreakableChest || entry.Gizmotype.Value == GizmoType.DestroyableObject)
                {
                    if (!FunkyBaseExtension.Settings.Debugging.DebuggingDataTypes.HasFlag(DebugDataTypes.Destructibles))
                        return;

                    if (Destructibles.Entries.Contains(d)) return;
                    Destructibles.Entries.Add(d);
                    DebugData_Destructibles.SerializeToXML(Destructibles);
                }
                else if(entry.Gizmotype.Value == GizmoType.BreakableDoor)
                {
                    if (!FunkyBaseExtension.Settings.Debugging.DebuggingDataTypes.HasFlag(DebugDataTypes.Barricades))
                        return;

                    if (Barricades.Entries.Contains(d)) return;
                    Barricades.Entries.Add(d);
                    DebugData_Barricades.SerializeToXML(Barricades);
                }
            }
            else if (d.ActorType == PluginActorType.Item || d.TargetType == TargetType.Item)
            {
                if (!FunkyBaseExtension.Settings.Debugging.DebuggingDataTypes.HasFlag(DebugDataTypes.Items))
                    return;

                if (Items.Entries.Contains(d)) return;
                Items.Entries.Add(d);
                DebugData_DroppedItems.SerializeToXML(Items);
            }
        }