cmangos / issues

This repository is used as a centralized point for all issues regarding CMaNGOS.
179 stars 47 forks source link

[TBC] Playerbot /p attack #1442

Closed dunjeon closed 7 years ago

dunjeon commented 7 years ago

Current behavior: /p attack (with target selected) yields zero results /t BOTNAME attack (with target selected) yields zero results

Expected behavior: The bot should attack the selected target

Steps to reproduce:

  1. .bot add BOTNAME
  2. /invite BOTNAME
  3. select a target for combat
  4. /p attack

Client version: 2.4.3

botattack

cala commented 7 years ago

Confirmed. This only concerns TBC branch for some reason.

dunjeon commented 7 years ago

As far as my testing goes the bots don't work on woTLK either. same /p attack issue and they won't respond to orders combat commands

cala commented 7 years ago

Strange. I checked the day before yesterday for the Classic, TBC and WotLK revision at that time (respectively https://github.com/cmangos/mangos-classic/commit/a5cd368731a44d762f8c2b54d383b1b379f0a91e, https://github.com/cmangos/mangos-tbc/commit/978f8aa529f6178260bf68fa8f26862417031ecc and https://github.com/cmangos/mangos-wotlk/commit/8e9cafc2986ef210b24a33528fdfacd84816b58b). Bots were taking combat orders in all branches and were responding to attack command in Classic and WotLK branches. Only the TBC branch had an issue, with the attack command.

I'd like you to confirm that with revision https://github.com/cmangos/mangos-wotlk/commit/8e9cafc2986ef210b24a33528fdfacd84816b58b, bots have :

same /p attack issue and they won't respond to orders combat commands

Thanks.

dunjeon commented 7 years ago

Confirmed. Fresh compile with pull from 8-25-207 and cmangos/mangos-wotlk@8e9cafc applied.

The bots do not respond to combat orders or a /p attack (WoTLK).

TBC fresh compile 8-25-207 with cmangos/mangos-tbc@978f8aa has bots taking combat orders, but not responding to /p attack or direct tell (/t attack)

Classic fresh compile pulled from 8-25-2017 with cmangos/mangos-classic@a5cd368 works by design

Screen shot below is from WoTLK. No response from bots. TBC yields responses from orders combat only, and classic provides expected results.

wotlk_bots

cala commented 7 years ago

I'm sorry, I'm unable to reproduce the issue with WotLK branch. Fresh build from yesterday, Rogue as main character (master) and druid as bot: it was taking combat orders (heal) and was responding to /p attack I'd like to help you, but I don't know how.

dunjeon commented 7 years ago

I just tried it on a non elevated account (player, player) and it seems to work by design (WoTLK). Gamemaster account, commands are ignored.

dunjeon commented 7 years ago

For what it's worth I am, also, efforting a solution.

cala commented 7 years ago

I did not look at the code yet to be honest. I assume that WotLK has a GM check that is not in TBC and Classic branch. In my opinion, this check should be remove (why GM should be prevented privileges that users have?).

For attack command in TBC, comparing the attack command handler in TBC to WotLK should bring some light.

dunjeon commented 7 years ago

I was able to correct the attack issue in TBC. I will look at the WoTLK GM issue soon (I think it may require a new case(?) the player is not just a party leader, but also a GM... the chat box has a special icon in it.)

cala commented 7 years ago

Closed by https://github.com/cmangos/mangos-tbc/commit/436fb062f62cd6b545418c72efe996c7b79717b3