Jump to content

[Patch] Auction House Bot (Xeross' Branch)


Recommended Posts

  • Replies 717
  • Created
  • Last Reply

Top Posters In This Topic

AuctionHouseEntry const* ahEntry = sAuctionMgr.GetAuctionHouseEntry(config->GetAHFID());
AuctionHouseObject* auctionHouse = sAuctionMgr.GetAuctionsMap(ahEntry);

try this where you get errors in AuctionHouseBot.cpp

compiles fine, however not tested if it works ingame :)

Link to comment
Share on other sites

Here is the patch file for 10252.

There is some modification in function, i hope i choosed the good way... Anyway it works until now.

AuctionHouseObject* auctionHouse = sAuctionMgr.GetAuctionsMap(config->GetAHFID());

replaced by

AuctionHouseEntry const* ahEntry = sAuctionMgr.GetAuctionHouseEntry(config->GetAHFID());
AuctionHouseObject* auctionHouse = sAuctionMgr.GetAuctionsMap(ahEntry);

Cheer

Edit : oops Homeless posted before :)

Link to comment
Share on other sites

What I mean by all details is how to fix the code like you showed and how did you apply the patch with git.

Pleas state: how to get AHBOT to work start to finish like how to use git to get it and fix cod and apply the patch and then compile like that.

Link to comment
Share on other sites

Yea I'm one of the ones to make a Howto On AHBot, Its has been 2 years so just was wondering how you do it now, cuas its not working so far this is what I did.

I got mangos with the GitBash command. So what I did is make a folder called MangosCompile I right click that folder and Selected GitBash Here, After the command Window comes up

I type

git://github.com/mangos/mangos.git

Next I made a folder called ScriptDev2 in MangosCompile\\src\\bindings I right click that folder and Selected SVN Checkout, After the Window comes up

I type

https://scriptdev2.svn.sourceforge.net/svnroot/scriptdev2

Next Step Time to apply Patches So what I did is follow this

====>I`m not git guru, so i made only patch file for everyone who want.

Patch was created from AHBot Xeross' Branch - no funcional modification, only compatibility with actual ManGOS.

Compatible MaNGOS revision: 10206+

Tested today, compile OK, Server running and AHBot works.

Way to apply patch:

Go to MaNGOS git repository and use commnad:

git apply "PATH TO PATCH"\\AHBot.patch<====

Download patch

So After I Downloaded that I put it in MangosCompile after that I used the PatchCommand on MangosCompile Folder. I right click that folder and Selected GitBash Here

After the command Window comes up I type

patch -p1 < AHBot.patch

"So it patches it."

The Version of Mangos I have is 10227

I compiles it with no errors, I added the sql to database and the AHBot one too. I edited the configs and all.

Now I made Account for the AHbot, I got the Account # and GUID of the player in the config.

Started the server logged in as the AHBot got in game exited.

So got my reg player in there works great!!! But with one Problem nothing in the Auctionhouse.

So I'm Stuck no compile errors nothing server works great but it like the AHBot is not Writing to the Auctionhouse in the Database.

Any Fixed or Ideas would be Great thanks.

Link to comment
Share on other sites

hmm u could update to 10254 and try this patch...ahbot_10254.zip

Conpiled with:VC++ 2010 [mangosdVC100.sln]

6>  AuctionHouseBot.cpp
6>..\\..\\src\\game\\AuctionHouseBot.cpp(434): error C2039: 'auctioneer' : is not a member of 'AuctionEntry'
6>          c:\\mangoscompile\\src\\game\\AuctionHouseMgr.h(48) : see declaration of 'AuctionEntry'
6>  AuctionHouseHandler.cpp
6>..\\..\\src\\game\\AuctionHouseHandler.cpp(267): error C2039: 'auctioneer' : is not a member of 'AuctionEntry'
6>          c:\\mangoscompile\\src\\game\\AuctionHouseMgr.h(48) : see declaration of 'AuctionEntry'
6>..\\..\\src\\game\\AuctionHouseHandler.cpp(287): error C2039: 'auctioneer' : is not a member of 'AuctionEntry'

========== Build: 7 succeeded, 1 failed, 4 up-to-date, 0 skipped ==========

Link to comment
Share on other sites

seem's like I messed that up! NVM it was late...

- auction->auctioneer = fields[1].GetUInt32();

+ uint32 houseid = fields[1].GetUInt32();

...thats why. Ok this patch compiles but I've not tested it...I've adding auctioneer back into the structure, ugly tho as it should be derived from new houseid variable. Can somebody test pls

Link to comment
Share on other sites

seem's like I messed that up! NVM it was late...

- auction->auctioneer = fields[1].GetUInt32();

+ uint32 houseid = fields[1].GetUInt32();

...thats why. Ok this patch compiles but I've not tested it...I've adding auctioneer back into the structure, ugly tho as it should be derived from new houseid variable. Can somebody test pls

Unable to patch in to 10259..

$ git apply ahbot_10254.patch

ahbot_10254.patch:3540: trailing whitespace.

ahbot_10254.patch:3570: trailing whitespace.

ahbot_10254.patch:157: new blank line at EOF.

+

ahbot_10254.patch:258: new blank line at EOF.

+

error: patch failed: src/game/AuctionHouseHandler.cpp:28

error: src/game/AuctionHouseHandler.cpp: patch does not apply

error: patch failed: src/game/AuctionHouseMgr.cpp:480

error: src/game/AuctionHouseMgr.cpp: patch does not apply

error: patch failed: src/game/Chat.h:118

error: src/game/Chat.h: patch does not apply

error: patch failed: src/game/World.cpp:60

error: src/game/World.cpp: patch does not apply

Link to comment
Share on other sites

I can't do much to help with code conflicts, but many of you have complaints that can be solved if you'd actually bother yourselves to read previous posts here and in the help sections of these forums.

For configuring AHBot, it's all right there in the README. Follow it, exactly, step-by-step. Many complaints of having no items are due to forgetting the steps where you must add the proper data to the auctionhousebot database table.

As for using Git, there are several ways you can apply AHBot to your master. One such method I've already described in an earlier post. For the rest of you, you're just going to have to dig in and actually learn Git. Putting it off is only going to cause more problems when you could be solving a lot of issues with just a few simple Git commands.

Link to comment
Share on other sites

seem's like I messed that up! NVM it was late...

- auction->auctioneer = fields[1].GetUInt32();

+ uint32 houseid = fields[1].GetUInt32();

...thats why. Ok this patch compiles but I've not tested it...I've adding auctioneer back into the structure, ugly tho as it should be derived from new houseid variable. Can somebody test pls

Hi, I tryed compile but end with compile error.

Platform: Linux Ubuntu

Mangos: 10264

SD2: 1749

../../../src/game/AuctionHouseBot.cpp: In member function âvoid AuctionHouseBot::addNewAuctions(Player*, AHBConfig*)â:
../../../src/game/AuctionHouseBot.cpp:28: error: invalid conversion from âuint32â to âUnit*â
../../../src/game/AuctionHouseBot.cpp:28: error:   initializing argument 1 of âstatic const AuctionHouseEntry* AuctionHouseMgr::GetAuctionHouseEntry(Unit*)â
../../../src/game/AuctionHouseBot.cpp: In member function âvoid AuctionHouseBot::addNewAuctionBuyerBotBid(Player*, AHBConfig*, WorldSession*)â:
../../../src/game/AuctionHouseBot.cpp:459: error: invalid conversion from âuint32â to âUnit*â
../../../src/game/AuctionHouseBot.cpp:459: error:   initializing argument 1 of âstatic const AuctionHouseEntry* AuctionHouseMgr::GetAuctionHouseEntry(Unit*)â
../../../src/game/AuctionHouseBot.cpp:603: warning: format â%fâ expects type âdoubleâ, but argument 3 has type âlong doubleâ
../../../src/game/AuctionHouseBot.cpp:657: warning: format â%fâ expects type âdoubleâ, but argument 3 has type âlong doubleâ
../../../src/game/AuctionHouseBot.cpp:664: warning: format â%fâ expects type âdoubleâ, but argument 3 has type âlong doubleâ
../../../src/game/AuctionHouseBot.cpp:683: warning: format â%fâ expects type âdoubleâ, but argument 3 has type âlong doubleâ
../../../src/game/AuctionHouseBot.cpp: In member function âvoid AuctionHouseBot::Initialize()â:
../../../src/game/AuctionHouseBot.cpp:813: warning: format not a string literal and no format arguments
../../../src/game/AuctionHouseBot.cpp:840: warning: format not a string literal and no format arguments
../../../src/game/AuctionHouseBot.cpp:1027: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1028: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1029: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1030: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1031: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1032: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1033: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1034: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1035: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1036: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1037: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1038: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1039: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp:1040: warning: format â%dâ expects type âintâ, but argument 3 has type âsize_tâ
../../../src/game/AuctionHouseBot.cpp: In member function âvoid AuctionHouseBot::Commands(uint32, uint32, uint32, char*)â:
../../../src/game/AuctionHouseBot.cpp:1093: error: invalid conversion from âuint32â to âUnit*â
../../../src/game/AuctionHouseBot.cpp:1093: error:   initializing argument 1 of âstatic const AuctionHouseEntry* AuctionHouseMgr::GetAuctionHouseEntry(Unit*)â
 CXX    AuctionHouseMgr.o
make[3]: *** [AuctionHouseBot.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory `/home/mangos/mcompile/mworlddev/mangos/objdir/src/game'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/mangos/mcompile/mworlddev/mangos/objdir/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/mangos/mcompile/mworlddev/mangos/objdir'
make: *** [all] Error 2

Link to comment
Share on other sites

patch -p1 < ../ahbot_10254.patch then commit will compile on 9fda6b50752803f33afdc88962c2594356ccd7ed [10254] but then AuctionHouse changes require skills beyond mine to make this patch work.

[10256] New `auction` command with subcommands for look different auction stores from anywhere.
Link to comment
Share on other sites

Can somebody test pls

$ git apply --check Addon/AHBot/ahbot.patch

error: patch failed: src/game/AuctionHouseHandler.cpp:28

error: src/game/AuctionHouseHandler.cpp: patch does not apply

error: patch failed: src/game/AuctionHouseMgr.cpp:480

error: src/game/AuctionHouseMgr.cpp: patch does not apply

error: patch failed: src/game/Chat.h:118

error: src/game/Chat.h: patch does not apply

I can't figure out why this isn't just part of the core in the first place. Doesn't every Bliz server have a working AH? I was happily updating my server until this didn't work. Server will stay down until this is fixed or I get fed up and switch to a repack or Trinity. Just don't have the time to deal with this. For some of you this is just easy and/or fun. For me it's more like, do I want to spend the time to figure this out or just do something else. Today it's something else. :)

Link to comment
Share on other sites

I made partially functional patch.

Patch was created from AHBot Xeross' Branch.

So and what mean "partially functional"?

AHBot sell and buy only in Neutral(goblin) auctionhouse !!!!!!

The old items in Horde and Alliance auctions stay and is possible auction them, but AHBot don't add new items and don't buy any items there :/

Then the GM subcommand "ahexpire" is not woking, do nothing, it is empty code now. (because I don't found there a simple solution)

I never used any of the AHBot commanda so it is not a big problem, I think:)

Until anyone made better patch with all functional auctionhouses, you can use this one with functional Neutral AuctionHouse.

I spawned Neutral Auctioneeers Goblins to Aliance and Horde AuctionHouse and set more items in neutral Auction as compensation of this :) (.npc add 8661)

I'm sorry, but I am Java programmer and c++ do as hobby for MaNGOS. Maybe later I'll have more time to learn more MaNGOS hardcode secrets and make better patches. I'll try make this patch functional for all auctionHouses, but this is the best I can made at this time.

Compatible MaNGOS revision: 10269+

Tested today, compile OK, Server running and AHBot works (partially).

Way to apply patch:

Go to MaNGOS git repository and use commnad:

git apply "PATH TO PATCH"\\AHBot_mnocz_20100725_MaNGOSr10269.patch

Download patch

Link to comment
Share on other sites

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