What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

[Plugin] ItemRuleExaminer 1.0

Giles, sorry I was at work and doing it from memory. Try this:

ZetaDia.Actors.Update();

I ran the plugin while I was logged in and so v1.1 wouldn't work for me either without that line

Edit:

And I am also running Windows 7 64 bit also.
 
Okay, the ZetaDia.Actors.Update(); looks promising, I've uploaded version 1.2 using that in the hopes that this might fix the problem.
 
Giles, sorry I was at work and doing it from memory. Try this:
ZetaDia.Actors.Update();
I ran the plugin while I was logged in and so v1.1 wouldn't work for me either without that line
Edit:
And I am also running Windows 7 64 bit also.

Yarrrr! Well done, that fixed it :D I also did what you mentioned earlier - removed the pulse code, and removed any references to the blacklist or current date/time - so it's just a "use once" thing (enable then disable to get a current list of everything, repeat when needed). Thanks both Ipo and Zephyr for getting this working! Wonder why only some of us need that "Update()" call, and some don't, strange!
 
Okay, the ZetaDia.Actors.Update(); looks promising, I've uploaded version 1.2 using that in the hopes that this might fix the problem.
Nice one Ipo, will help others too! Very strange that it doesn't affect everyone, but might be useful info for other plugin developers too regarding Zeta data stuff!
 
Sorry for spam posting, but want to try and fix this plugin completely (as it's damned useful, because DB does seem to mess up interpreting item rules sometimes). Anyway, couple of things after experimenting with rulesets. First of all tried your 1.2 Ipo - you need to remove the "is null" check that you have BEFORE the "Update();" call. It's *ALWAYS* Null UNTIL that update is called, so it's always exiting. The routine should be something like;
Code:
  private void DoUpdate()
  {
   ZetaDia.Actors.Update();
   if (ZetaDia.Actors.Me == null)
   {
    return;
   }
   foreach (var item in ZetaDia.Actors.Me.Inventory.Equipped)
   {

Secondly, I found that if I had lootrules that were blank in a specific category, for example this;
Code:
  <Category ruleType="Sell">
   <!--Sells everything else -->
  </Category>

Then the "RuleMatchItem" function crashed at whichever point it was trying to read blank rules from - for example in the above empty Sell category, it'd crash out with an exception when doing "if (ItemManager.EvaluateItem(item, ItemManager.RuleType.Sell)", giving this exception;
Code:
[03:21:41.380 D] Exception while enabling plugin LootRuleCheck 1.0: System.NullReferenceException: Object reference not set to an instance of an object.
   at System.Linq.Enumerable.<SelectManyIterator>d__31`3.MoveNext()
   at (Object )
   at Zeta.CommonBot.ItemManager.EvaluateItem(ACDItem item, RuleType type)
   at LootRuleCheck.LootRuleCheck.RuleMatchItem(ACDItem item)
   at LootRuleCheck.LootRuleCheck.CheckItems()
   at LootRuleCheck.LootRuleCheck.OnEnabled()
   at Zeta.Common.Plugins.PluginContainer.set_Enabled(Boolean value)

Only way I (with my primitive code knowledge!) could find to stop this was just to add a rule into the sell category with impossible-criteria, rather than leave it blank. This might stop some deep DB crashes too (DB itself might not like empty categories!) :D
 
Okay, that was a very detailed bug report, both of those issues should now be fixed in version 1.3.
 
Code:
[13:41:09.686 D] Exception while enabling plugin ItemRuleExaminer 1.3: System.Exception: Process must have frozen or gotten out of sync: InjectionFinishedEvent was never fired
   bei ..(String debugMessage)
   bei Zeta.Internals.Actors.ACDItem.(ACD acd)
   bei Zeta.Internals.Actors.ACDItem.get_ItemLink()
   bei Zeta.Internals.Actors.ACDItem.get_Name()
   bei ItemRuleExaminer.ItemRuleExaminer.RuleMatchItem(ACDItem item)
   bei ItemRuleExaminer.ItemRuleExaminer.DoUpdate()
   bei ItemRuleExaminer.ItemRuleExaminer.OnEnabled()
   bei Zeta.Common.Plugins.PluginContainer.set_Enabled(Boolean value)

any suggestions? :(
 
I don't know, from the looks of it I would guess it was just DB temporarily stumbling or something. Does it persist even if you restart DB/log in to the game/get the bot running before starting the plugin?
 
IPO, can we get an option to just scan items on the floor?
 
IPO, can we get an option to just scan items on the floor?
Adding such an option seems like a lot of work if it's just to save people the effort of opening the log-file to find their item of interest amidst the spam, sorry. The plugin can be left enabled, in which case it will filter items as they pop up for the first time, for example as they're dropped by a monster or chest, if it's something along those lines that you're looking for.

In other news I just added 1.4, no huge changes, but hopefully it shouldn't list as many completely invalid items anymore.
 
im asking that more to avoid crashing the client, bcse it tries to read way too much data. it is all it does to me, crash crash crash.

and also bcse, i was trying to use this to check out the damn bugs DB has with filtering shit. Just because of that. And report back to DEVS with a sure proof that DB filtering/stashing system is broken . . .

but if its too much work, then leave it.
 
Back
Top