Jump to content

Recommended Posts

Posted

@rrtn updated botguy thankyou

@darsig make sure you uninvite the bot before you remove them.

@collinsp I have not had a problem with this as of yet as long as they are removed properly.

  • Replies 1.8k
  • Created
  • Last Reply

Top Posters In This Topic

Posted

ok, thanks.

Can you make ".bot add" command like gm? This way you can disable or enable player bot for players by typing 0 or 1-3 access level in `commands` table without mangos core recompiling.

This patch is great, thanks a lot.

Posted

Hello,

In playerbotai.cpp

Please change

m_bot->TeleportTo( loc.mapid, loc.x, loc.y, loc.z, m_bot->GetOrientation() );

in

m_bot->TeleportTo( loc.mapid, loc.coord_x, loc.coord_y, loc.coord_z, m_bot->GetOrientation() );

at line 1961

In new version of mangos(8027).

Thank you and sorry for bad english :P

Posted

@guillaumederval added your code thank you

m_bot->TeleportTo( loc.mapid, loc.coord_x, loc.coord_y, loc.coord_z, m_bot->GetOrientation() ); 

and merged to mangos 8029 and pushed.:)

Posted

From http://getmangos.ru:

This code

   if( pet )
   {
       if( ((float)pet->GetHealth()/(float)pet->GetMaxHealth()) < 0.5f )
       {
           // heal pet when health lower 50%
           if( PET_MEND>0 && !pet->HasAura(PET_MEND,0) && ai->CastSpell(PET_MEND,*m_bot) )
           {
               ai->TellMaster( "healing pet" );
               return;
           }
       }
   }

replace (It is better to replace it:):


   if(( pet ) 
   && ( ((float)pet->GetHealth()/(float)pet->GetMaxHealth()) < 0.5f )
   && ( PET_MEND>0 && !pet->HasAura(PET_MEND,0) && ai->CastSpell(PET_MEND,*m_bot) ))
   {
       ai->TellMaster( "healing pet" );
       return;
   }

Posted

Who did the changes to /contrib/ and /dep/ files? If you are pushing to PlaybotAI branch, please don't push your custom stuffs please

It looks really bad, gonna need some clean up

Posted

player bot break hunter's pet. 2 players - 2 clients - hunter and priest ( as example )

1. Hunter vision:

hunter tames beast, all ok, but when taiming is over hunter can not control his pet. pet always stand in one plase and hunter commands do not have any effect on pet.....

2. Another player ( priest ) vision:

Another player ( priest ) looking at hunter and see that pet running, attackind and etch. but this is not pet , this is hunter himself in pet skin for this another player ( priest ). Hunter ( pet in hunter skin for priest ) stands in one place and do nothing.

This is big problem. Can it be fixed somehow?

p.s. sorry for my english

Delete this post. Another character works normal....

Posted
Reward taking is still buggy. Problem with choosing a reward, (e.g. at quest http://www.wowhead.com/?quest=10324 )

Hi, I fixed the problem, here's the patch:

diff --git a/src/game/PlayerbotAI.cpp b/src/game/PlayerbotAI.cpp
index ea3e00d..1270dd4 100644
--- a/src/game/PlayerbotAI.cpp
+++ b/src/game/PlayerbotAI.cpp
@@ -559,7 +559,16 @@ void PlayerbotAI::HandleMasterIncomingPacket(const WorldPacket& packet, WorldSes
                                    }
                                }
                                // just choose first reward if we cant use any of the rewards
-                                uint32 rewardItemId = (pRewardItem == NULL) ? pQuest->RewChoiceItemId[0] : pRewardItem->ItemId;
+                                uint32 rewardItemId;
+                                if (pRewardItem == NULL)
+                                {
+                                        rewardItemId = pQuest->RewChoiceItemId[0];
+                                        pRewardItem = objmgr.GetItemPrototype(rewardItemId);
+                                }
+                                else
+                                {
+                                        rewardItemId = pRewardItem->ItemId;
+                                }

                                if (bot->CanRewardQuest(pQuest, rewardItemId, false))
                                {

pRewardItem could be still null, so the line 'std::string itemName = pRewardItem->Name1;' crashed.

I have no github account, so feel free to upload this. ;)

Posted

@KiriX i tryed your code but can not seem to make it work

if(( pet ) 
   && ( ((float)pet->GetHealth()/(float)pet->GetMaxHealth()) < 0.5f )
   && ( PET_MEND>0 && !pet->HasAura(PET_MEND,0) && ai->CastSpell(PET_MEND,*m_bot) ))
   {
       ai->TellMaster( "healing pet" );
       return;
   }

@walkofdoom i added and it works better thank you.

+                                uint32 rewardItemId;
+                                if (pRewardItem == NULL)
+                                {
+                                        rewardItemId = pQuest->RewChoiceItemId[0];
+                                        pRewardItem = objmgr.GetItemPrototype(rewardItemId);
+                                }
+                                else
+                                {
+                                        rewardItemId = pRewardItem->ItemId;
+                                }

                                if (bot->CanRewardQuest(pQuest, rewardItemId, false))
                                {

Np crashes at all :)

Also merged to mangos 8036

Posted

@clinton i do not use the 64 bit i use 32 bit ver and i am not having problems. sorry

@marry521 Maybe go into characters data base and delete any corpse's it might help.

Posted
@marry521 Maybe go into characters data base and delete any corpse's it might help.

this is problem. deliting corpses helps only for 20-30 min till next bot die.... alike problem was with "spirit of redemption" spell in core.

and can you make somehow to disable or anabe bot ( in mangosd.conf or database table ). This is not good to full recompile core if you want to disable bot.

+ when you calls out bot , all his archievements comes out in guild chat every time. It is good to disable it. thanks.^_^

p.s.very sorry for my english

added. Where in code i can set up maximum allowed bots for on player. Now we have 9, how can i set up 2 for exemple? thanks...

Posted

@collinsp the quest reward is great but they just take the first one in the quest, Which is better then having it crash which it was not doing with the Quests. But i am not sure if we should have left it the other way. Because at least you can log out and log back in and turn in the quest and pick the one the bot needs.But yes you can still do that this way. Just my 2 cents. But i do thank you for your hard work and every one else that has been contributing. :)

Posted

bots can now turn quests in even if master can't talk to NPC (master must target the quest rewarder)

if there is greater then 1 quest reward, bot asks master what reward to take. TO select a reward for your bot, send a tell to the bot and link the item.

Posted

@collinsp Ok this is what everyone is having a problem with, they are in a party with the bots and they right click there portrait the master and select leave party it will crash the server. this is not the way to do it but you can't Explain this to all people. Give it a try .

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use