• Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • [A1 Inferno]FallenDev's, Bossqwerty-spiced FoM zorked edition -> MP10 E-skipping

    Discussion in 'Archives' started by zorked, Oct 6, 2013.

    1. danonji

      danonji New Member

      Joined:
      Oct 19, 2012
      Messages:
      39
      Likes Received:
      0
      Trophy Points:
      0
      can someone explain to me how to edit the town.cs? i dunno if i did it correctly thx :)) feel free to post one already fixed
       
    2. Kevin Spacey

      Kevin Spacey Community Developer

      Joined:
      Aug 31, 2013
      Messages:
      2,830
      Likes Received:
      11
      Trophy Points:
      38
      CUSTOM TOWNRUN explanation in my profile's topic

      you dont need to edit it
      its another file
       
    3. danonji

      danonji New Member

      Joined:
      Oct 19, 2012
      Messages:
      39
      Likes Received:
      0
      Trophy Points:
      0

      i dont see anything can u give me the link thx
       
    4. Kevin Spacey

      Kevin Spacey Community Developer

      Joined:
      Aug 31, 2013
      Messages:
      2,830
      Likes Received:
      11
      Trophy Points:
      38
      at my signature
       
    5. rrrix

      rrrix DEVELOPER Buddy Core Dev

      Joined:
      Jul 11, 2010
      Messages:
      3,449
      Likes Received:
      61
      Trophy Points:
      0
      Actually, to be more precise, it's due to the internal Demonbuddy DungeonExplorer.

      ... Which by the way works *much* better in the latest beta. Nesox added some magic...
       
    6. bombastic

      bombastic New Member

      Joined:
      Jun 18, 2012
      Messages:
      430
      Likes Received:
      3
      Trophy Points:
      0
      Zork, to avoid all these problems about entering Decaying Crypts, change your FoMCrypts (and you guys having the problem, change yourselves)

      Change:
      Code:
      <TrinityExploreDungeon questId="[B][SIZE=4]136656[/SIZE][/B]" stepId="1" boxSize="27" boxTolerance="0.18" pathPrecision="20"
      For:
      Code:
      <TrinityExploreDungeon questId="[B][SIZE=4]1[/SIZE][/B]" stepId="1" boxSize="27" boxTolerance="0.18" pathPrecision="20"
      No need to specify the real quest there. I think this will stop the endless complaints ;)
       
    7. speculoos

      speculoos Member

      Joined:
      Jun 11, 2012
      Messages:
      397
      Likes Received:
      1
      Trophy Points:
      18
      bombastic, Thanks for your tweak it works well in general but i have a question when i see in DB : "===== Ignoring Poison: True =====" i saw my Hero not moving at all and stay in the middle of it but sometimes it works it gets out of the poison directly and i did this : "Poison Tree: 100 (important, careful with that value to avoid flip-flop due to my new anti-poison code)" . Anything i could have done wrong? Thanks anyway :)
       
    8. bombastic

      bombastic New Member

      Joined:
      Jun 18, 2012
      Messages:
      430
      Likes Received:
      3
      Trophy Points:
      0
      Speculoos, I changed that Poison Code exactly because of this, in my new version. I'll post it tomorrow, with a lot of new tweaks :)
       
    9. kaze3d

      kaze3d New Member

      Joined:
      Jun 19, 2012
      Messages:
      105
      Likes Received:
      1
      Trophy Points:
      0
      If you havent already, dont forget to add the 2H weapon fix from rrix's git. :) Your current version has the skipping 2h leg bug that doesnt pick up Skorns, etc. Great work btw.
       
    10. bombastic

      bombastic New Member

      Joined:
      Jun 18, 2012
      Messages:
      430
      Likes Received:
      3
      Trophy Points:
      0
      I didn't know about that. I use my own soft itemrules, and it picks Skorns.

      I'll look and fix it as well.
       
    11. speculoos

      speculoos Member

      Joined:
      Jun 11, 2012
      Messages:
      397
      Likes Received:
      1
      Trophy Points:
      18
      That sounds great :) Thanks


      Could you link me the fix mate please?
       
    12. bombastic

      bombastic New Member

      Joined:
      Jun 18, 2012
      Messages:
      430
      Likes Received:
      3
      Trophy Points:
      0
      RefreshCachedItem.cs, change:

      Code:
      if (pickupItem.IsTwoHand && !Settings.Loot.Pickup.TwoHandedWeapons)
      To:
      Code:
      if (pickupItem.IsTwoHand && !Settings.Loot.Pickup.TwoHandedWeapons && c_ItemQuality < ItemQuality.Legendary)
       
    13. speculoos

      speculoos Member

      Joined:
      Jun 11, 2012
      Messages:
      397
      Likes Received:
      1
      Trophy Points:
      18
      Dont have this in my RefresCachedItem.cs

      Code:
      using System;
      using System.IO;
      using Trinity.Cache;
      using Trinity.Config.Loot;
      using Trinity.Technicals;
      using Zeta.CommonBot;
      using Zeta.Internals.Actors;
      
      namespace Trinity
      {
          public partial class Trinity
          {
              private static bool RefreshItem()
              {
                  bool logNewItem = false;
                  bool AddToCache = false;
      
                  if (c_BalanceID == -1)
                  {
                      AddToCache = false;
                      c_IgnoreSubStep = "InvalidBalanceID";
                  }
      
                  var item = c_diaObject as DiaItem;
                  c_ItemQuality = item.CommonData.ItemQualityLevel;
      
                  float fExtraRange = 0f;
      
                  if (c_ItemQuality >= ItemQuality.Legendary)
                  {
                      // always pickup
                      AddToCache = true;
                  }
                  else
                  {
                      if (c_ItemQuality >= ItemQuality.Rare4)
                          fExtraRange = CurrentBotLootRange;
      
                      if (iKeepLootRadiusExtendedFor > 0)
                          fExtraRange += 90f;
      
                      if (c_CentreDistance > (CurrentBotLootRange + fExtraRange))
                      {
                          c_IgnoreSubStep = "OutOfRange";
                          AddToCache = false;
                          // return here to save CPU on reading unncessary attributes for out of range items;
                          if (!AddToCache)
                              return AddToCache;
                      }
                  }
      
                  c_ItemDisplayName = item.CommonData.Name;
                  c_GameBalanceID = item.CommonData.GameBalanceId;
                  c_ItemLevel = item.CommonData.Level;
                  c_DBItemBaseType = item.CommonData.ItemBaseType;
                  c_DBItemType = item.CommonData.ItemType;
                  c_IsOneHandedItem = item.CommonData.IsOneHand;
                  c_IsTwoHandedItem = item.CommonData.IsTwoHand;
                  c_item_tFollowerType = item.CommonData.FollowerSpecialType;
      
                  var pickupItem = new PickupItem
                  {
                      Name = c_ItemDisplayName,
                      InternalName = c_InternalName,
                      Level = c_ItemLevel,
                      Quality = c_ItemQuality,
                      BalanceID = c_BalanceID,
                      DBBaseType = c_DBItemBaseType,
                      DBItemType = c_DBItemType,
                      IsOneHand = c_IsOneHandedItem,
                      IsTwoHand = c_IsTwoHandedItem,
                      ItemFollowerType = c_item_tFollowerType,
                      DynamicID = c_GameDynamicID,
                      Position = c_Position,
                      ActorSNO = c_ActorSNO
                  };
      
                  // Calculate item type
                  c_item_GItemType = DetermineItemType(c_InternalName, c_DBItemType, c_item_tFollowerType);
      
                  // And temporarily store the base type
                  GItemBaseType itemBaseType = DetermineBaseType(c_item_GItemType);
      
                  // Treat all globes as a yes
                  if (c_item_GItemType == GItemType.HealthGlobe)
                  {
                      c_ObjectType = GObjectType.Globe;
                      // Create or alter this cached object type
                      objectTypeCache[c_RActorGuid] = c_ObjectType;
                      AddToCache = true;
                  }
      
                  // Item stats
                  logNewItem = RefreshItemStats(itemBaseType);
      
                  // Get whether or not we want this item, cached if possible
                  if (!pickupItemCache.TryGetValue(c_RActorGuid, out AddToCache))
                  {
                      if (Settings.Loot.ItemFilterMode == ItemFilterMode.DemonBuddy)
                      {
                          AddToCache = ItemManager.Current.ShouldPickUpItem((ACDItem) c_CommonData);
                      }
                      else if (Settings.Loot.ItemFilterMode == ItemFilterMode.TrinityWithItemRules)
                      {
                          AddToCache = ItemRulesPickupValidation(pickupItem);
                      }
                      else
                      {
                          AddToCache = PickupItemValidation(pickupItem);
                      }
      
                      // Pickup low level enabled, and we're a low level
                      if (!AddToCache && Settings.Loot.Pickup.PickupLowLevel && Player.Level <= 10)
                      {
                          AddToCache = PickupItemValidation(pickupItem);
                      }
      
                      pickupItemCache.Add(c_RActorGuid, AddToCache);
                  }
      
                  // Using DB built-in item rules
                  if (AddToCache && ForceVendorRunASAP)
                      c_IgnoreSubStep = "ForcedVendoring";
      
                  // Didn't pass pickup rules, so ignore it
                  if (!AddToCache && c_IgnoreSubStep == String.Empty)
                      c_IgnoreSubStep = "NoMatchingRule";
      
                  if (Settings.Advanced.LogDroppedItems && logNewItem && c_DBItemType != ItemType.Unknown)
                      LogDroppedItem();
      
                  return AddToCache;
              }
      
              private static void LogDroppedItem()
              {
                  string droppedItemLogPath = Path.Combine(FileManager.TrinityLogsPath, String.Format("ItemsDropped.csv"));
      
                  bool pickupItem = false;
                  pickupItemCache.TryGetValue(c_RActorGuid, out pickupItem);
      
                  bool writeHeader = !File.Exists(droppedItemLogPath);
                  using (var LogWriter = new StreamWriter(droppedItemLogPath, true))
                  {
                      if (writeHeader)
                      {
                          LogWriter.WriteLine("Timestamp,ActorSNO,RActorGUID,DyanmicID,GameBalanceID,ACDGuid,Name,InternalName,DBBaseType,TBaseType,DBItemType,TItemType,Quality,Level,IgnoreItemSubStep,Distance,Pickup,SHA1Hash");
                      }
                      LogWriter.Write(FormatCSVField(DateTime.Now));
                      LogWriter.Write(FormatCSVField(c_ActorSNO));
                      LogWriter.Write(FormatCSVField(c_RActorGuid));
                      LogWriter.Write(FormatCSVField(c_GameDynamicID));
                      // GameBalanceID
                      LogWriter.Write(FormatCSVField(c_GameBalanceID));
                      LogWriter.Write(FormatCSVField(c_ACDGUID));
                      LogWriter.Write(FormatCSVField(c_ItemDisplayName));
                      LogWriter.Write(FormatCSVField(c_InternalName));
                      LogWriter.Write(FormatCSVField(c_DBItemBaseType.ToString()));
                      LogWriter.Write(FormatCSVField(DetermineBaseType(c_item_GItemType).ToString()));
                      LogWriter.Write(FormatCSVField(c_DBItemType.ToString()));
                      LogWriter.Write(FormatCSVField(c_item_GItemType.ToString()));
                      LogWriter.Write(FormatCSVField(c_ItemQuality.ToString()));
                      LogWriter.Write(FormatCSVField(c_ItemLevel));
                      LogWriter.Write(FormatCSVField(c_IgnoreSubStep));
                      LogWriter.Write(FormatCSVField(c_CentreDistance));
                      LogWriter.Write(FormatCSVField(pickupItem));
                      LogWriter.Write(FormatCSVField(c_ItemMd5Hash));
                      LogWriter.Write("\n");
                  }
              }
      
              private static bool RefreshGold(bool AddToCache)
              {
                  //int rangedMinimumStackSize = 0;
                  AddToCache = true;
      
                  if (Player.ActorClass == ActorClass.Barbarian && Settings.Combat.Barbarian.IgnoreGoldInWOTB && Hotbar.Contains(SNOPower.Barbarian_WrathOfTheBerserker) &&
                      GetHasBuff(SNOPower.Barbarian_WrathOfTheBerserker))
                  {
                      AddToCache = false;
                      c_IgnoreSubStep = "IgnoreGoldInWOTB";
                      return AddToCache;
                  }
      
                  // Get the gold amount of this pile, cached if possible
                  if (!goldAmountCache.TryGetValue(c_RActorGuid, out c_GoldStackSize))
                  {
                      try
                      {
                          c_GoldStackSize = ((ACDItem) c_CommonData).Gold;
                      }
                      catch
                      {
                          Logger.Log(TrinityLogLevel.Debug, LogCategory.CacheManagement, "Safely handled exception getting gold pile amount for item {0} [{1}]", c_InternalName, c_ActorSNO);
                          AddToCache = false;
                          c_IgnoreSubStep = "GetAttributeException";
                      }
                      goldAmountCache.Add(c_RActorGuid, c_GoldStackSize);
                  }
      
                  if (c_GoldStackSize < Settings.Loot.Pickup.MinimumGoldStack)
                  {
                      AddToCache = false;
                      c_IgnoreSubStep = "NotEnoughGold";
                      return AddToCache;
                  }
      
                  if (c_CentreDistance <= Player.GoldPickupRadius)
                  {
                      AddToCache = false;
                      c_IgnoreSubStep = "WithinPickupRadius";
                      return AddToCache;
                  }
      
                  //if (!AddToCache)
                  //    LogSkippedGold();
      
                  //DbHelper.Log(TrinityLogLevel.Debug, LogCategory.CacheManagement, "Gold Stack {0} has iPercentage {1} with rangeMinimumStackSize: {2} Distance: {3} MininumGoldStack: {4} PickupRadius: {5} AddToCache: {6}",
                  //    c_GoldStackSize, iPercentage, rangedMinimumStackSize, c_CentreDistance, Settings.Loot.Pickup.MinimumGoldStack, ZetaDia.Me.GoldPickUpRadius, AddToCache);
      
                  return AddToCache;
              }
      
              private static void LogSkippedGold()
              {
                  string skippedItemsPath = Path.Combine(FileManager.LoggingPath, String.Format("SkippedGoldStacks_{0}_{1}.csv", Player.ActorClass, DateTime.Now.ToString("yyyy-MM-dd")));
      
                  bool writeHeader = !File.Exists(skippedItemsPath);
                  using (var LogWriter = new StreamWriter(skippedItemsPath, true))
                  {
                      if (writeHeader)
                      {
                          LogWriter.WriteLine("ActorSNO,RActorGUID,DyanmicID,ACDGuid,Name,GoldStackSize,IgnoreItemSubStep,Distance");
                      }
                      LogWriter.Write(FormatCSVField(c_ActorSNO));
                      LogWriter.Write(FormatCSVField(c_RActorGuid));
                      LogWriter.Write(FormatCSVField(c_GameDynamicID));
                      LogWriter.Write(FormatCSVField(c_ACDGUID));
                      LogWriter.Write(FormatCSVField(c_InternalName));
                      LogWriter.Write(FormatCSVField(c_GoldStackSize));
                      LogWriter.Write(FormatCSVField(c_IgnoreSubStep));
                      LogWriter.Write(FormatCSVField(c_CentreDistance));
                      LogWriter.Write("\n");
                  }
              }
      
              private static string FormatCSVField(DateTime time)
              {
                  return String.Format("\"{0:yyyy-MM-ddTHH:mm:ss.ffffzzz}\",", time);
              }
      
              private static string FormatCSVField(string text)
              {
                  return String.Format("\"{0}\",", text);
              }
      
              private static string FormatCSVField(int number)
              {
                  return String.Format("\"{0}\",", number);
              }
      
              private static string FormatCSVField(double number)
              {
                  return String.Format("\"{0:0}\",", number);
              }
      
              private static string FormatCSVField(bool value)
              {
                  return String.Format("\"{0}\",", value);
              }
          }
      }
       
    14. kaze3d

      kaze3d New Member

      Joined:
      Jun 19, 2012
      Messages:
      105
      Likes Received:
      1
      Trophy Points:
      0
    15. speculoos

      speculoos Member

      Joined:
      Jun 11, 2012
      Messages:
      397
      Likes Received:
      1
      Trophy Points:
      18
    16. bombastic

      bombastic New Member

      Joined:
      Jun 18, 2012
      Messages:
      430
      Likes Received:
      3
      Trophy Points:
      0
      My v2 is based in Trinity 1.7.3.8.

      That option was created later, in 1.7.3.9.
       
    17. speculoos

      speculoos Member

      Joined:
      Jun 11, 2012
      Messages:
      397
      Likes Received:
      1
      Trophy Points:
      18
      My bad then no worries :) Ill wait for your v3 bombastic, thanks to both of you :)
       
    18. Kevin Spacey

      Kevin Spacey Community Developer

      Joined:
      Aug 31, 2013
      Messages:
      2,830
      Likes Received:
      11
      Trophy Points:
      38
      your 1.7.3.8 better for total IPH than your 1.7.3.9 for my barb-2
      look in the signature
      dunno why
       
    19. cayine

      cayine New Member

      Joined:
      Sep 4, 2013
      Messages:
      28
      Likes Received:
      0
      Trophy Points:
      0
      any idea whats savage beast acrotID number?
       
    20. zorked

      zorked New Member

      Joined:
      Mar 23, 2013
      Messages:
      576
      Likes Received:
      4
      Trophy Points:
      0
      Hah, you're a genious. The simple things are always the ones I seem to overlook :p

      Friday I'll be able to move into my new appartment. Then I'll set up my computers again and will have time to do some fixes. At least I hope I'll have some time for that...
       

    Share This Page