• Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • [Bot] Prosto_Pets: Battle Pets 4 in 1, and more

    Discussion in 'Botbases' started by Prostak, Jan 7, 2015.

    1. Prostak

      Prostak Member

      Joined:
      Mar 17, 2013
      Messages:
      249
      Likes Received:
      16
      Trophy Points:
      18
      Should be there now. Please check.
       
    2. Prostak

      Prostak Member

      Joined:
      Mar 17, 2013
      Messages:
      249
      Likes Received:
      16
      Trophy Points:
      18
      I've tried to outline the future plans in the post no 3: https://www.thebuddyforum.com/honor...attle-pets-4-1-a-post1810928.html#post1810928
      Daily tamers are in item 4, which is now at the second position. Safari Hat is too simple, I keep forgetting to include it, lol.
       
    3. Valpsjuk

      Valpsjuk Member

      Joined:
      Nov 10, 2014
      Messages:
      397
      Likes Received:
      4
      Trophy Points:
      18
      Yepp, now they were added :)
       
    4. Prostak

      Prostak Member

      Joined:
      Mar 17, 2013
      Messages:
      249
      Likes Received:
      16
      Trophy Points:
      18
      That's possible right now. Just uncheck "Auto Load" in "Pet Zones" tab and load a profile through standard HB profile loading button.
      That's actually how I've created PetZones profiles: by using World Explorer profiles, links are in "Credits" post below the starting one.
       
    5. Prostak

      Prostak Member

      Joined:
      Mar 17, 2013
      Messages:
      249
      Likes Received:
      16
      Trophy Points:
      18
      Included in 0.9.12, just pushed. Please check.
      I've spent like 15 minutes trying to figure out if it is ok to introduce nice but different style here. Finally decided that since you are now the boss in tactics, I can just relax :)
       
    6. Prostak

      Prostak Member

      Joined:
      Mar 17, 2013
      Messages:
      249
      Likes Received:
      16
      Trophy Points:
      18
      Underground detection is possible, yes. I have already added underwater detection since (it seems) a battle can't be started in water (always obstructed).
      But do you think it will be better to exclude these hotspots from the profile?
       
    7. Studio60

      Studio60 Well-Known Member Buddy Store Developer

      Joined:
      Sep 3, 2014
      Messages:
      3,411
      Likes Received:
      48
      Trophy Points:
      48
      Haha, that is giving me way, way too much credit, but thanks for incorporating the changes anyway. I really don't want to step on anyone's toes (especially yours) because you are doing a great job. And should I overreach, just tell me and I'll take it down a few notches. :) I will implement the new tactics on a few pets today and take them for another spin.
       
    8. Prostak

      Prostak Member

      Joined:
      Mar 17, 2013
      Messages:
      249
      Likes Received:
      16
      Trophy Points:
      18
      You are not stepping on the shoes, you are lifting a huge burden from my neck. Seriously.
       
    9. Valpsjuk

      Valpsjuk Member

      Joined:
      Nov 10, 2014
      Messages:
      397
      Likes Received:
      4
      Trophy Points:
      18
      Yes, it should be possible I guess, but these ones I encountered yesterday was as I said when it was checking Coldarra and it got to close to the mountains and picked up the ones that are in the grotto close to Winterfin Village I think, so it's not really a hotspot in itself I don't think.
       
    10. xmichael

      xmichael New Member

      Joined:
      Aug 2, 2013
      Messages:
      1
      Likes Received:
      0
      Trophy Points:
      0
      very good !
       
    11. HBfanboy1980

      HBfanboy1980 Active Member

      Joined:
      Jan 16, 2012
      Messages:
      1,139
      Likes Received:
      11
      Trophy Points:
      38
      God this things a beast now. I would compare it to what HB does in allowing us to use botbases and routines to Your botbase and the pet logics!

      :)
       
    12. Studio60

      Studio60 Well-Known Member Buddy Store Developer

      Joined:
      Sep 3, 2014
      Messages:
      3,411
      Likes Received:
      48
      Trophy Points:
      48
      I found a nasty little bug today. Probably a copy&paste thing. :)

      PetTacticsBase.cs:
      Code:
              // our active pet speed
              public static int speed { get { return MyPets.ActivePet.Speed; } }
              // enemy active pet speed
              public static int speedEnemy { get { return MyPets.[COLOR="#FF0000"]ActivePet[/COLOR].Speed; } }
      
      should probably be
      Code:
              // our active pet speed
              public static int speed { get { return MyPets.ActivePet.Speed; } }
              // enemy active pet speed
              public static int speedEnemy { get { return MyPets.[COLOR="#FF0000"]EnemyActivePet[/COLOR].Speed; } }
      
      I was really baffled, because my speed checks didn't seem to work. :)

      "Fly you damn bird, you can do it..."
      "But I am not fast enough..."
      Sounds like the setup for a Pixar movie..
       
    13. SIL3N7

      SIL3N7 Active Member

      Joined:
      Jun 12, 2012
      Messages:
      1,119
      Likes Received:
      11
      Trophy Points:
      38
      Where can i donate to your time/ work. keep it up =)
       
    14. Studio60

      Studio60 Well-Known Member Buddy Store Developer

      Joined:
      Sep 3, 2014
      Messages:
      3,411
      Likes Received:
      48
      Trophy Points:
      48
      Prostak has his paypal information in his signature:

       
    15. SIL3N7

      SIL3N7 Active Member

      Joined:
      Jun 12, 2012
      Messages:
      1,119
      Likes Received:
      11
      Trophy Points:
      38

      Thanks i looked there since most do but he did not have one. He does now tho weird..
      But thanks
       
    16. Studio60

      Studio60 Well-Known Member Buddy Store Developer

      Joined:
      Sep 3, 2014
      Messages:
      3,411
      Likes Received:
      48
      Trophy Points:
      48
      I managed to slip in an oversight when I asked you to add those new tactic functions. Apparently elemental pets do not suffer from negative weather effects so any check would have to respect that.

      If you have the time, could you please update the following two code blocks as well? Or give me SVN access (just kidding). :)

      MyPets.cs:285ff
      Code:
              public static bool enemyIsBlinded()
              {
                  if ([COLOR="#FF0000"](_weather == "Darkness" && EnemyActivePet.PetType != (int)PF.Elemental)[/COLOR] || 
                      debuff("Blinding Poison") || debuff("Blinded") || debuff("Partially Blinded"))
                  {
                      return true;
                  }
                  return false;
              }
      
              public static bool enemyIsBurning()
              {
                  if ([COLOR="#FF0000"](_weather == "Scorched Earth" && EnemyActivePet.PetType != (int)PF.Elemental)[/COLOR] || 
                      debuff("Fel Immolate") || debuff("Flame Breath") || debuff("Flame Jet") ||
                      debuff("Flamethrower") || debuff("Immolate"))
                  {
                      return true;
                  }
                  return false;
              }
      
              public static bool enemyIsChilled()
              {
                  if ([COLOR="#FF0000"](_weather == "Blizzard" && EnemyActivePet.PetType != (int)PF.Elemental)[/COLOR] || 
                      debuff("Frostbite") || debuff("Frost Nova") || 
                      debuff("Frost Shock") || debuff("Slippery Ice"))
                  {
                      return true;
                  }
                  return false;
              }
      
      MyPets.cs:367ff
      Code:
              public static bool myPetIsBlinded()
              {
                  if ([COLOR="#FF0000"](_weather == "Darkness" && ActivePet.PetType != (int)PF.Elemental)[/COLOR] || 
                      buff("Blinding Poison") || buff("Blinded") || buff("Partially Blinded"))
                  {
                      return true;
                  }
                  return false;
              }
      
              public static bool myPetIsBurning()
              {
                  if ([COLOR="#FF0000"](_weather == "Scorched Earth" && ActivePet.PetType != (int)PF.Elemental)[/COLOR] || 
                      buff("Fel Immolate") || buff("Flame Breath") || buff("Flame Jet") ||
                      buff("Flamethrower") || buff("Immolate"))
                  {
                      return true;
                  }
                  return false;
              }
      
              public static bool myPetIsChilled()
              {
                  if ([COLOR="#FF0000"](_weather == "Blizzard" && ActivePet.PetType != (int)PF.Elemental)[/COLOR] || 
                      buff("Frostbite") || buff("Frost Nova") || 
                      buff("Frost Shock") || buff("Slippery Ice"))
                  {
                      return true;
                  }
                  return false;
              }
      
      Sorry for that. :-(
       
      Last edited: Jan 20, 2015
    17. Studio60

      Studio60 Well-Known Member Buddy Store Developer

      Joined:
      Sep 3, 2014
      Messages:
      3,411
      Likes Received:
      48
      Trophy Points:
      48
      Why do you think profiles are the way to go? I think profiles are great to manage things like traveling to pet battle trainers, accepting and turning in daily quests, healing at Stable Masters or repeatedly engaging with the garrison NPC/challenge pole to grind a certain pet battle. For this, you could probably use, what the questing botbase already offers.

      But defining tactics for those fights in XML seems a bit redundant to me as we already create them in c#. It is also pretty difficult if you think about the fact that you have to create multiple tactics for each fight depending on which pets the players own. If I were to implement such a feature, I would probably create a BossBattle override folder where one boss tactic per file can be placed the bot just tries to find a suitable one by iterating through the available tactics for specific team setups.

      The following is pseudocode, but you should get the idea:

      Code:
                  // the target we would have to catch before the pet battle starts. can be both an NPC or an object
                  if (enemyNpcId == 79179) // Squirt <Wandering Trainer>
                  {
                      // here we would have to define the team with an option to include leveling pets
                      setTeamPet("Slot1", "Scourged Whelpling", "Tail Sweep", "Death and Decay", "Plagued Blood");
                      setTeamPet("Slot2", "Rapana Whelk", "Absorb", "Shell Shield", "Dive");
                      string carryPetName = setCarryPet("Slot3", 4, 24); // selects carry pet between level 4 and 24 and returns name
      
                      // if the above team can't be created, then we would have to look in the other override files
                      if (validTeam() == false)
                          return;
      
                      // if the required team can be created, we just run through the defined tactic
                      if (petName == "Scourged Whelpling")
                      {
                          custom_abilities = new List<AandC>() {
                              // ...
                              new AandC("SWAPIN3", () => battleRound == 4),	// Slot 3
                              // ...
                          };
                      }
                      if (petName == "Rapana Whelk")
                      {
                          // ...
                      }
                      if (petName == carryPetName)
                      {
                          custom_abilities = new List<AandC>() {
                              new AandC("USEANYTHING", () => battleRound == 5),	// Slot 3
                              new AandC("SWAPIN2", () => battleRound == 6),	// Slot 3
                          };
                      }
      
                      // after the battle we return control to the profile
                  }
      
      At some point this could even be extended to wild pet battles: "If we encounter enemy x in zone y, then select two ringers of type z"...

      Man, I really feel like I am being overzealous... I'll stop for today.
       
      Last edited: Jan 20, 2015
    18. Prostak

      Prostak Member

      Joined:
      Mar 17, 2013
      Messages:
      249
      Likes Received:
      16
      Trophy Points:
      18
      Version 0.9.13: (all changes thx to Studio60)
      - speedEnemy corrected;
      - Base tactics corrected.
      - debuffLeft added.

      I've seen some strange speed-related behavior but have not stopped to investigate.
       
      Last edited: Jan 20, 2015
    19. Prostak

      Prostak Member

      Joined:
      Mar 17, 2013
      Messages:
      249
      Likes Received:
      16
      Trophy Points:
      18
      Marketing guys would not call it "correcting an oversight". They would call it "making a significant improvement".
      Added to 0.9.13.
       
    20. Studio60

      Studio60 Well-Known Member Buddy Store Developer

      Joined:
      Sep 3, 2014
      Messages:
      3,411
      Likes Received:
      48
      Trophy Points:
      48
      You are right. But in my daily life I am always trying to market my games and spin even bad things into a positive. On these forums I can just be a simple developer that messes up and then fixes his bugs. :)
       

    Share This Page