EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Development::Bots (https://www.eqemulator.org/forums/forumdisplay.php?f=676)
-   -   EQoffline, bots and more.. (https://www.eqemulator.org/forums/showthread.php?t=22667)

kiirdiir 03-07-2008 10:07 AM

Quote:

Originally Posted by Lotek (Post 144246)
Any chance you could put them up on filebeam ?

I can help you out there: filebeam.com link.

Congdar 03-08-2008 02:49 PM

I've merged the bots with build 1102. Have fun! Source and EXE's
Several crash fixes
Set bots to not aggro when set to "guard"
Caster bots will report they need to meditate

kiirdiir 03-08-2008 03:10 PM

Nice.

I just finished doing that myself, minus the changes you made. Thanks!

Aramid 03-10-2008 06:59 AM

Quote:

Originally Posted by Congdar (Post 144153)
I've made it easier to patch in by surrounding the bot code in blocks of #ifdef EQBOTS and I have been making fixes to things that were causing crashes and added extra helpful text when using #bot commands.

Where do you #def EQBOTS so they will be available when compiling in Linux (Debian 4) or is there something else that needs to be done?

Congdar 03-10-2008 07:08 AM

Not sure for linux compiles, sorry. In Visual Studio you add EQBOTS to the preprocessor settings. Not sure if it's necessary but I add it to the zone, world and emusharemem components.

Derision 03-10-2008 10:05 AM

Quote:

Originally Posted by Aramid (Post 144407)
Where do you #def EQBOTS so they will be available when compiling in Linux (Debian 4) or is there something else that needs to be done?

To define a symbol for the pre-processor you need to add -D<symbol> to the compiler command line. e.g.:

Code:

#include <stdio.h>

int main() {

#ifdef EQBOTS
        printf("EQBOTS defined\n");
#endif

}

entwisd@rama ~ $ g++ test.cpp
entwisd@rama ~ $ ./a.out
entwisd@rama ~ $ g++ -DEQBOTS test.cpp
entwisd@rama ~ $ ./a.out
EQBOTS defined
entwisd@rama ~ $

I've not tried this bots code, but I would guess adding -DEQBOTS to the first DFLAGS line in zone/makefile should be all that is required, i.e. change

Code:

DFLAGS=-DEQDEBUG=5 -DCATCH_CRASH -DNO_PIDLOG -DSHAREMEM -DSPELL_EFFECT_SPAM -DFIELD_ITEMS -DCOMBINED -DAPP_OPCODE_SIZE=2 -Di386
to

Code:

DFLAGS=-DEQDEBUG=5 -DCATCH_CRASH -DNO_PIDLOG -DSHAREMEM -DSPELL_EFFECT_SPAM -DFIELD_ITEMS -DCOMBINED -DAPP_OPCODE_SIZE=2 -Di386 -DEQBOTS
then do a make clean; make

cavedude 03-10-2008 11:15 AM

You also need to add the 3 bot files to the makefile to compile. so in zone/makefile.common

Code:

../common/guild_base.o guild_mgr.o
becomes:

Code:

../common/guild_base.o guild_mgr.o botRaids.o botAI.o petAI.o

Aramid 03-10-2008 11:45 AM

Thanks Derision and Cavedude, that was what was needed. It compiled and appears to be working fine.

cubber 03-12-2008 02:37 AM

If I am running the latest PEQ database from CVS is there a need to drop the npc_spells_entries table and replace it with the one from the link in the readme? I noticed that the bot tables are already put in and isbot is added to npc_types by default in PEQ.

Congdar 03-12-2008 03:02 AM

I wouldn't, that sql file is pretty old and missing much of what is in the current table.

cubber 03-12-2008 03:14 AM

Great thanks for the reply. I just want to make sure I got this right, there is a lot of info in this thread. So on a linux server after downloading your 1102 sources all I would have to do is:

1. Change the following in zone/makefile:

Code:

DFLAGS=-DEQDEBUG=5 -DCATCH_CRASH -DNO_PIDLOG -DSHAREMEM -DSPELL_EFFECT_SPAM -DFIELD_ITEMS -DCOMBINED -DAPP_OPCODE_SIZE=2 -Di386
to:

Code:

DFLAGS=-DEQDEBUG=5 -DCATCH_CRASH -DNO_PIDLOG -DSHAREMEM -DSPELL_EFFECT_SPAM -DFIELD_ITEMS -DCOMBINED -DAPP_OPCODE_SIZE=2 -Di386 -DEQBOTS
2. Then change the following in zone/makefile.common

Code:

../common/guild_base.o guild_mgr.o
to:

Code:

../common/guild_base.o guild_mgr.o botRaids.o botAI.o petAI.o
3. run make

4. copy the world, zone , and libEMuShareMem.so files from the bot source to my current working server directory replacing the normal world, zone and libEMuShareMem.so files, and run my start script that I use to normally start my server.

Then if I wish to revert back to my old server just copy the old world, zone, libEMuShareMem.so files back to the working server directory over the bot files.

Thanks

Congdar 03-12-2008 03:28 AM

Not sure if \common is the correct place for those files. The original eqoffline source files are in the \zone folder.

cavedude 03-12-2008 03:40 AM

That's absolutely correct, cubber. Though, to toggle between eqoffline and normal binaries you only need to swap out zone. The other binaries are not changed.

../common is the location of guild_base.cpp and guild_base.h. If you notice, the other 4 files after it have no directory, so the makefile will just use its current directory for those, which of course is zone.

cubber 03-12-2008 03:45 AM

Thats how I thought the line read thanks cavedude! So basically the only thing I need to compile after downloading the 1102 source linked above is zone. Since I already have a 1102 eqemu server running.

cavedude 03-12-2008 04:00 AM

Yep, that's it.


All times are GMT -4. The time now is 04:02 PM.

Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.