IPB

Welcome Guest ( Log In | Register )

3 Pages V < 1 2 3 >  
Reply to this topicStart new topic
> Compiling RCBot2
JRob
post Apr 20 2015, 01:44 AM
Post #21


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



So I took a closer look at the code.

It looks like extern IVEngineServer *engine; is specified in engine_wrappers.h.

But it is not properly defined anywhere else in the entire project.

When I look at another example metamod plugin, https://github.com/bcserv/smpm/blob/master/extension.cpp they fill the pointer to the engine with this line "GET_V_IFACE_ANY(GetEngineFactory, engine, IVEngineServer, INTERFACEVERSION_VENGINESERVER);" which I cannot find anywhere in RCBots.

I am really confused how you got this to compile. Did you maybe not include a file or update it? I downloaded the files straight from the SVN r467.

Yeah it looks like you aren't uploading whatever version of RCBot you use to actually compile.

The problem is that it is missing the file bot_plugin_meta.cpp in the project.

And now that I added it, there is another error saying rcbot2-code-467\utils\rcbot2_meta\bot_plugin_meta.cpp(750): error C2039: 'PostClientMessagesSent' : is not a member of 'IServerGameClients'

This seems to be the final list of files missing that need to be included for it to compile.

- bot_plugin_meta.cpp
- bot_cvars.cpp
- bot_sigscan.cpp

...And finally it compiled... I think you didn't push the updated version of your visual studio project into SVN.

I am afraid to think of what else needs to be done for linux.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Apr 20 2015, 01:45 PM
Post #22


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



QUOTE(JRob @ Apr 20 2015, 02:44 AM) *

So I took a closer look at the code.

It looks like extern IVEngineServer *engine; is specified in engine_wrappers.h.

But it is not properly defined anywhere else in the entire project.

When I look at another example metamod plugin, https://github.com/bcserv/smpm/blob/master/extension.cpp they fill the pointer to the engine with this line "GET_V_IFACE_ANY(GetEngineFactory, engine, IVEngineServer, INTERFACEVERSION_VENGINESERVER);" which I cannot find anywhere in RCBots.

I am really confused how you got this to compile. Did you maybe not include a file or update it? I downloaded the files straight from the SVN r467.

Yeah it looks like you aren't uploading whatever version of RCBot you use to actually compile.

The problem is that it is missing the file bot_plugin_meta.cpp in the project.

And now that I added it, there is another error saying rcbot2-code-467\utils\rcbot2_meta\bot_plugin_meta.cpp(750): error C2039: 'PostClientMessagesSent' : is not a member of 'IServerGameClients'

This seems to be the final list of files missing that need to be included for it to compile.

- bot_plugin_meta.cpp
- bot_cvars.cpp
- bot_sigscan.cpp

...And finally it compiled... I think you didn't push the updated version of your visual studio project into SVN.

I am afraid to think of what else needs to be done for linux.


Perhaps you're using the wrong VC proj file -- it should be the VCX proj

it should be https://sourceforge.net/p/rcbot2/code/HEAD/...PB_Bot2.vcxproj

it has the files (+preprocessor definitions) included

as for ServerGameClients -- it's in eiface.h, check the eiface.h in the bot SVN or the latest github in the first post
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
JRob
post Apr 20 2015, 07:36 PM
Post #23


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



QUOTE(Cheeseh @ Apr 20 2015, 01:45 PM) *

Perhaps you're using the wrong VC proj file -- it should be the VCX proj

it should be https://sourceforge.net/p/rcbot2/code/HEAD/...PB_Bot2.vcxproj

it has the files (+preprocessor definitions) included

as for ServerGameClients -- it's in eiface.h, check the eiface.h in the bot SVN or the latest github in the first post


Well I only see 1 set of vcproj/vcxproj in the directory. Maybe the settings got clobbered when visual studio 2013 upgraded the project. Maybe you should delete the vcproj file because the last 3 versions of visual studio use vcxproj.

I have also just built it on Linux. but it crashes whenever I add the bot.

Instructions:

Delete

bot_convar.cpp
bot_hooks.cpp
bot_hooks.h

===bot.h
Remove inline
Vector snipe ( Vector &vAiming );

===bot_fortress.h
Remove inline
bool someoneCalledMedic ();

===bot_sigscan.cpp

#ifdef __linux__
#include "shake.h" //bir3yk
#include "elf.h"

#define PAGE_SIZE 4096
#define PAGE_ALIGN_UP(x) ((x + PAGE_SIZE - 1) & ~(PAGE_SIZE - 1))
lib.memorySize = PAGE_ALIGN_UP(hdr.p_filesz);

And here is the makefile adapted from the metamod example. It just compiles every CPP in the directory so you don't have a muck around with the visual studio to makefile converter.

http://www.filedropper.com/makefile_1
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Apr 21 2015, 01:26 AM
Post #24


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



bot_hooks.cpp and header are only important for vsp

cheers for the makefile and Linux fixes -- posting it below

CODE

# (C)2004-2010 Metamod:Source Development Team
# Makefile written by David "BAILOPAN" Anderson

###########################################
### EDIT THESE PATHS FOR YOUR OWN SETUP ###
###########################################

HL2SDK_ORIG = ../../hl2sdk
HL2SDK_OB = ../../hl2sdk-ob
HL2SDK_CSS = ../../hl2sdk-css
HL2SDK_OB_VALVE = ../sdk/hl2sdk-ob-valve
HL2SDK_L4D = ../../hl2sdk-l4d
HL2SDK_L4D2 = ../../hl2sdk-l4d2
HL2SDK_CSGO = ../../hl2sdk-csgo
MMSOURCE19 = ../sdk/mmsource

#####################################
### EDIT BELOW FOR OTHER PROJECTS ###
#####################################

PROJECT = rcbot
OBJECTS = $(wildcard *.cpp)

##############################################
### CONFIGURE ANY OTHER FLAGS/OPTIONS HERE ###
##############################################

OPT_FLAGS = -O3 -funroll-loops -pipe
GCC4_FLAGS = -fvisibility=hidden -fvisibility-inlines-hidden
DEBUG_FLAGS = -g -ggdb3 -D_DEBUG
CPP = gcc
CPP_OSX = clang

##########################
### SDK CONFIGURATIONS ###
##########################

override ENGSET = false

# Check for valid list of engines
ifneq (,$(filter original orangebox orangeboxvalve css left4dead left4dead2 csgo,$(ENGINE)))
    override ENGSET = true
endif

ifeq "$(ENGINE)" "original"
    HL2SDK = $(HL2SDK_ORIG)
    CFLAGS += -DSOURCE_ENGINE=1
endif
ifeq "$(ENGINE)" "orangebox"
    HL2SDK = $(HL2SDK_OB)
    CFLAGS += -DSOURCE_ENGINE=3
endif
ifeq "$(ENGINE)" "css"
    HL2SDK = $(HL2SDK_CSS)
    CFLAGS += -DSOURCE_ENGINE=6
endif
ifeq "$(ENGINE)" "orangeboxvalve"
    HL2SDK = $(HL2SDK_OB_VALVE)
    CFLAGS += -DSOURCE_ENGINE=7
endif
ifeq "$(ENGINE)" "left4dead"
    HL2SDK = $(HL2SDK_L4D)
    CFLAGS += -DSOURCE_ENGINE=8
endif
ifeq "$(ENGINE)" "left4dead2"
    HL2SDK = $(HL2SDK_L4D2)
    CFLAGS += -DSOURCE_ENGINE=9
endif
ifeq "$(ENGINE)" "csgo"
    HL2SDK = $(HL2SDK_CSGO)
    CFLAGS += -DSOURCE_ENGINE=12
endif

HL2PUB = $(HL2SDK)/public

ifeq "$(ENGINE)" "original"
    INCLUDE += -I$(HL2SDK)/public/dlls
    METAMOD = $(MMSOURCE19)/core-legacy
else
    INCLUDE += -I$(HL2SDK)/public/game/server
    METAMOD = $(MMSOURCE19)/core
endif

OS := $(shell uname -s)

ifeq "$(OS)" "Darwin"
    LIB_EXT = dylib
    HL2LIB = $(HL2SDK)/lib/mac
else
    LIB_EXT = so
    ifeq "$(ENGINE)" "original"
        HL2LIB = $(HL2SDK)/linux_sdk
    else
        HL2LIB = $(HL2SDK)/lib/linux
    endif
endif

# if ENGINE is original or OB
ifneq (,$(filter original orangebox,$(ENGINE)))
    LIB_SUFFIX = _i486.$(LIB_EXT)
else
    LIB_PREFIX = lib
    ifneq (,$(filter orangeboxvalve css left4dead2,$(ENGINE)))
        ifneq "$(OS)" "Darwin"
            LIB_SUFFIX = _srv.$(LIB_EXT)
        else
            LIB_SUFFIX = .$(LIB_EXT)
        endif
    else
        LIB_SUFFIX = .$(LIB_EXT)
    endif
endif

CFLAGS += -DSE_EPISODEONE=1 -DSE_DARKMESSIAH=2 -DSE_ORANGEBOX=3 -DSE_BLOODYGOODTIME=4 -DSE_EYE=5 \
    -DSE_CSS=6 -DSE_ORANGEBOXVALVE=7 -DSE_LEFT4DEAD=8 -DSE_LEFT4DEAD2=9 -DSE_ALIENSWARM=10 \
    -DSE_PORTAL2=11 -DSE_CSGO=12

LINK += $(HL2LIB)/tier1_i486.a $(LIB_PREFIX)vstdlib$(LIB_SUFFIX) $(LIB_PREFIX)tier0$(LIB_SUFFIX) $(HL2LIB)/mathlib_i486.a

ifeq "$(ENGINE)" "csgo"
    LINK += $(HL2LIB)/interfaces_i486.a
endif

INCLUDE += -I. -I.. -I$(HL2PUB) -I$(HL2PUB)/engine -I$(HL2PUB)/mathlib -I$(HL2PUB)/vstdlib -I$(HL2SDK)/game/shared -I$(HL2SDK)/game/server \
    -I$(HL2PUB)/tier0 -I$(HL2PUB)/tier1 -I. -I$(METAMOD) -I$(METAMOD)/sourcehook

################################################
### DO NOT EDIT BELOW HERE FOR MOST PROJECTS ###
################################################

BINARY = $(PROJECT).$(LIB_EXT)

ifeq "$(DEBUG)" "true"
    BIN_DIR = Debug.$(ENGINE)
    CFLAGS += $(DEBUG_FLAGS)
else
    BIN_DIR = Release.$(ENGINE)
    CFLAGS += $(OPT_FLAGS)
endif


ifeq "$(OS)" "Darwin"
    CPP = $(CPP_OSX)
    LIB_EXT = dylib
    CFLAGS += -DOSX -D_OSX
    LINK += -dynamiclib -lstdc++ -mmacosx-version-min=10.5
else
    LIB_EXT = so
    CFLAGS += -D_LINUX
    LINK += -shared
endif

IS_CLANG := $(shell $(CPP) --version | head -1 | grep clang > /dev/null && echo "1" || echo "0")

ifeq "$(IS_CLANG)" "1"
    CPP_MAJOR := $(shell $(CPP) --version | grep clang | sed "s/.*version \([0-9]\)*\.[0-9]*.*/\1/")
    CPP_MINOR := $(shell $(CPP) --version | grep clang | sed "s/.*version [0-9]*\.\([0-9]\)*.*/\1/")
else
    CPP_MAJOR := $(shell $(CPP) -dumpversion >&1 | cut -b1)
    CPP_MINOR := $(shell $(CPP) -dumpversion >&1 | cut -b3)
endif

CFLAGS += -DPOSIX -Dstricmp=strcasecmp -D_stricmp=strcasecmp -D_strnicmp=strncasecmp \
    -Dstrnicmp=strncasecmp -D_snprintf=snprintf -D_vsnprintf=vsnprintf -D_alloca=alloca \
    -Dstrcmpi=strcasecmp -DCOMPILER_GCC -Wall -Wno-non-virtual-dtor -Wno-overloaded-virtual \
    -fPIC -fno-rtti -msse -m32 -fno-strict-aliasing -Wno-write-strings

# Clang || GCC >= 4
ifeq "$(shell expr $(IS_CLANG) \| $(CPP_MAJOR) \>= 4)" "1"
    CFLAGS += $(GCC4_FLAGS)
endif

# Clang >= 3 || GCC >= 4.7
ifeq "$(shell expr $(IS_CLANG) \& $(CPP_MAJOR) \>= 3 \| $(CPP_MAJOR) \>= 4 \& $(CPP_MINOR) \>= 7)" "1"
    CFLAGS += -Wno-delete-non-virtual-dtor
endif

# OS is Linux and not using clang
ifeq "$(shell expr $(OS) \= Linux \& $(IS_CLANG) \= 0)" "1"
    LINK += -static-libgcc
endif

OBJ_BIN := $(OBJECTS:%.cpp=$(BIN_DIR)/%.o)

$(BIN_DIR)/%.o: %.cpp
    $(CPP) $(INCLUDE) $(CFLAGS) -o $@ -c $<

all: check
    mkdir -p $(BIN_DIR)
    ln -sf $(HL2LIB)/$(LIB_PREFIX)vstdlib$(LIB_SUFFIX)
    ln -sf $(HL2LIB)/$(LIB_PREFIX)tier0$(LIB_SUFFIX)
    $(MAKE) -f Makefile stub_mm
    
check:
    if [ "$(ENGSET)" = "false" ]; then \
        echo "You must supply one of the following values for ENGINE:"; \
        echo "csgo, left4dead2, left4dead, css, orangeboxvalve, orangebox, or original"; \
        exit 1; \
    fi

stub_mm: check $(OBJ_BIN)
    $(CPP) $(INCLUDE) -m32 $(OBJ_BIN) $(LINK) -ldl -lm -o $(BIN_DIR)/$(BINARY)

default: all

clean: check
    rm -rf $(BIN_DIR)/*.o
    rm -rf $(BIN_DIR)/$(BINARY)




although not every .CPP file should be compiled, some are excluded from the project such as plugin_valve.cpp (that's the VSP file) delete that one, there are some others

Some offsets will be different in Linux. if its crashing when you're adding a bot its most likely the playerRunCmd offset -- depending on what mod you are playing with - you could change the default numbers of these cvars

rcbot_runplayer_cmd_dods
rcbot_runplayer_cmd_tf2

by putting them up by one or down by one, tweaking will find it
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
JRob
post Apr 21 2015, 09:28 PM
Post #25


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



QUOTE

although not every .CPP file should be compiled, some are excluded from the project such as plugin_valve.cpp (that's the VSP file) delete that one, there are some others

Some offsets will be different in Linux. if its crashing when you're adding a bot its most likely the playerRunCmd offset -- depending on what mod you are playing with - you could change the default numbers of these cvars

rcbot_runplayer_cmd_dods
rcbot_runplayer_cmd_tf2

by putting them up by one or down by one, tweaking will find it


I was looking at the code again and I noticed that you load the offsets from hookinfo.ini AFTER you hooked playerRunCmd. Shouldn't it be done before?

You are also missing the rcbotd command in bot_plugin_meta.cpp.

After I changed playerRunCmd to 419, it doesn't crash anymore but the bots do not join unless I first add a bot with the "bot" command.

All of them except 1 do not move and they are all sniper bots with the name bot02 bot03 etc... even though the console said it loaded the the default profiles.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Apr 22 2015, 01:56 AM
Post #26


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



QUOTE(JRob @ Apr 21 2015, 10:28 PM) *

I was looking at the code again and I noticed that you load the offsets from hookinfo.ini AFTER you hooked playerRunCmd. Shouldn't it be done before?

You are also missing the rcbotd command in bot_plugin_meta.cpp.

After I changed playerRunCmd to 419, it doesn't crash anymore but the bots do not join unless I first add a bot with the "bot" command.

All of them except 1 do not move and they are all sniper bots with the name bot02 bot03 etc... even though the console said it loaded the the default profiles.


1. the playerruncmd hook has to be declared first -- this is before the offset is hooked - it isn't actually hooked until a player is added
2. check the latest update it has rcbotd in plugin meta cpp
3. with bot01 bot02 that means they are just puppet bots you've added. you need to use rcbotd control <botname> to make rcbot use them.
the fact that rcbot didn't add a bot could be something to do with Linux server command in metamod ( not certain as I haven't looked at this yet)

try a lower value for player run cmd rather than a higher one in linux
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
JRob
post Apr 22 2015, 02:41 AM
Post #27


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



QUOTE(Cheeseh @ Apr 22 2015, 01:56 AM) *

1. the playerruncmd hook has to be declared first -- this is before the offset is hooked - it isn't actually hooked until a player is added
2. check the latest update it has rcbotd in plugin meta cpp
3. with bot01 bot02 that means they are just puppet bots you've added. you need to use rcbotd control <botname> to make rcbot use them.
the fact that rcbot didn't add a bot could be something to do with Linux server command in metamod ( not certain as I haven't looked at this yet)

try a lower value for player run cmd rather than a higher one in linux


1. I'm not talking about the declaration. I'm talking about the part where you load the offset like this

if (pKVL->getInt("runplayermove_tf2_linux", &val))
rcbot_runplayercmd_tf2.SetValue(val);

after you do this

SH_MANUALHOOK_RECONFIGURE(MHook_PlayerRunCmd, rcbot_runplayercmd_tf2.GetInt(), 0, 0);

rcbot_runplayercmd_tf2.GetInt() does not have the correct value here.

2. I manually copy and pasted rcbotd into it already.
3. They aren't puppet bots, I added them with rcbotd addbot and rcbotd config min_bots

rcbotd control bot03
[RCBot] already controlling player
[RCBot] error: couldn't control bot 'bot03'


According to Sourcemod playerruncmd is 419 on linux.

https://github.com/alliedmodders/sourcemod/...game.tf.txt#L97

Have you thought about using signatures instead? They hardly ever change.

I've been trying to figure out why it only controls 1 bot and doesn't use the profiles and I can't figure it out. I'm about to give up.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Apr 22 2015, 08:04 AM
Post #28


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



QUOTE(JRob @ Apr 22 2015, 03:41 AM) *

1. I'm not talking about the declaration. I'm talking about the part where you load the offset like this

if (pKVL->getInt("runplayermove_tf2_linux", &val))
rcbot_runplayercmd_tf2.SetValue(val);

after you do this

SH_MANUALHOOK_RECONFIGURE(MHook_PlayerRunCmd, rcbot_runplayercmd_tf2.GetInt(), 0, 0);

rcbot_runplayercmd_tf2.GetInt() does not have the correct value here.

2. I manually copy and pasted rcbotd into it already.
3. They aren't puppet bots, I added them with rcbotd addbot and rcbotd config min_bots

rcbotd control bot03
[RCBot] already controlling player
[RCBot] error: couldn't control bot 'bot03'
According to Sourcemod playerruncmd is 419 on linux.

https://github.com/alliedmodders/sourcemod/...game.tf.txt#L97

Have you thought about using signatures instead? They hardly ever change.

I've been trying to figure out why it only controls 1 bot and doesn't use the profiles and I can't figure it out. I'm about to give up.


In that case it's a bug so just move the loading offsets before the reconfigure.

if bots aren't moving then player run cmd is not being called -- something wrong with the hook perhaps

unfortunately I don't know the signature for it -- it's a virtual function so it's probably best using the offset
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
JRob
post Apr 22 2015, 06:59 PM
Post #29


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



QUOTE(Cheeseh @ Apr 22 2015, 08:04 AM) *

In that case it's a bug so just move the loading offsets before the reconfigure.

if bots aren't moving then player run cmd is not being called -- something wrong with the hook perhaps

unfortunately I don't know the signature for it -- it's a virtual function so it's probably best using the offset


Yes that's what I did. It kept crashing because I specified the offsets with hookinfo.ini and since it never loaded these offsets it kept crashing. Maybe there are other bugs like this.

1 bot is moving so that means PlayerRunCmd is correctly hooked. The rest don't move and when I do rcbotd control on them, it says rcbot is already controlling them.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Apr 23 2015, 01:52 PM
Post #30


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



QUOTE(JRob @ Apr 22 2015, 07:59 PM) *

Yes that's what I did. It kept crashing because I specified the offsets with hookinfo.ini and since it never loaded these offsets it kept crashing. Maybe there are other bugs like this.

1 bot is moving so that means PlayerRunCmd is correctly hooked. The rest don't move and when I do rcbotd control on them, it says rcbot is already controlling them.

it's probably not finding the rcbot2 folder with the waypoints and ot profiles in them, as far as I know there is also a bug in Linux causing bot profiles not to load and causing bot01 02 names etc
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
JRob
post Apr 23 2015, 07:18 PM
Post #31


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



QUOTE(Cheeseh @ Apr 23 2015, 01:52 PM) *

it's probably not finding the rcbot2 folder with the waypoints and ot profiles in them, as far as I know there is also a bug in Linux causing bot profiles not to load and causing bot01 02 names etc


It is finding the folder. If it couldn't find the waypoints the 1st bot wouldn't move either.

And the it prints that it loaded the inis in the console.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Apr 24 2015, 02:19 AM
Post #32


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



QUOTE(JRob @ Apr 23 2015, 08:18 PM) *

It is finding the folder. If it couldn't find the waypoints the 1st bot wouldn't move either.

And the it prints that it loaded the inis in the console.


I'd do a debug with

rcbotd debug bot <bot name that isn't moving>
rcbotd debug nav 1

see what it is printing

if it doesn't print anything try

rcbotd debug task 1
rcbotd debug think 1

could be a problem with bots thinking they are dead or "void CBots :: handleAutomaticControl ()"
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
JRob
post Apr 24 2015, 07:30 PM
Post #33


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



QUOTE(Cheeseh @ Apr 24 2015, 02:19 AM) *

I'd do a debug with

rcbotd debug bot <bot name that isn't moving>
rcbotd debug nav 1

see what it is printing

if it doesn't print anything try

rcbotd debug task 1
rcbotd debug think 1

could be a problem with bots thinking they are dead or "void CBots :: handleAutomaticControl ()"


rcbotd debug bot04
[RCBot] [debug]
[RCBot] gameevent [can't use]
[RCBot] bot [can't use]
[RCBot] nav [can't use]
[RCBot] vis [can't use]
[RCBot] think [can't use]
[RCBot] look [can't use]
[RCBot] hud [can't use]
[RCBot] aim [can't use]
[RCBot] bot_goto [can't use]
[RCBot] bot_flush [can't use]
[RCBot] task [can't use]
[RCBot] givetask [can't use]
[RCBot] buttons [can't use]
[RCBot] speed [can't use]
[RCBot] usercmd [can't use]
[RCBot] util [can't use]
[RCBot] profiling [can't use]
[RCBot] edicts [can't use]
[RCBot] printprops [can't use]
[RCBot] getprop [can't use]
[RCBot] setprop [can't use]
[RCBot] findclass [can't use]
[RCBot] findclassname [can't use]
[RCBot] findprop [can't use]
[RCBot] memoryscan [can't use]
[RCBot] memorycheck [can't use]

I just tried it again today and all the bots are moving now. I have no idea why. But the bots are still named Bot01 Bot02 etc...
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Apr 25 2015, 02:49 AM
Post #34


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



hmm those commands won't work on dedicated console, you can use rcon while connected as a client to debug with those commands instead use 'rcbot debug' though and not 'rcbotd' and you have setup your client in accessclients ini

but if it's working now, no need. There is a bug that bots won't change names correctly in Linux.

they should be changing name (or at least trying) here

CODE
bot.cpp
bool CBot :: createBotFromEdict(edict_t *pEdict, CBotProfile *pProfile)
{
..
engine->SetFakeClientConVarValue(pEdict,"name",pProfile->m_szName);
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
JRob
post Apr 25 2015, 07:56 PM
Post #35


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



QUOTE(Cheeseh @ Apr 25 2015, 02:49 AM) *

hmm those commands won't work on dedicated console, you can use rcon while connected as a client to debug with those commands instead use 'rcbot debug' though and not 'rcbotd' and you have setup your client in accessclients ini

but if it's working now, no need. There is a bug that bots won't change names correctly in Linux.

they should be changing name (or at least trying) here

CODE
bot.cpp
bool CBot :: createBotFromEdict(edict_t *pEdict, CBotProfile *pProfile)
{
..
engine->SetFakeClientConVarValue(pEdict,"name",pProfile->m_szName);



Well I guess it doesn't really matter since I can use sourcemod to change names. But it is really strange that they started to work randomly.

The only thing I did differently was that I gave up, and left the server alone. The next day I added my steamid to accessinfo.ini, rebooted the server, and then it started to work.

Maybe I could provide you with a Linux VM so you could make sure rcbot works on Linux? It is really much nicer than running on Windows. It is really easy to add libraries to it and when the server crashes, you can get debug symbols. You also won't have to restart your tf2 client.

Also have you thought about moving the project to github?
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
incorporator
post Apr 26 2015, 11:18 AM
Post #36


Newbie
*

Group: Members
Posts: 5
Joined: 24-April 15
Member No.: 2,382



QUOTE(JRob @ Apr 25 2015, 07:56 PM) *

Well I guess it doesn't really matter since I can use sourcemod to change names. But it is really strange that they started to work randomly.

The only thing I did differently was that I gave up, and left the server alone. The next day I added my steamid to accessinfo.ini, rebooted the server, and then it started to work.

Maybe I could provide you with a Linux VM so you could make sure rcbot works on Linux? It is really much nicer than running on Windows. It is really easy to add libraries to it and when the server crashes, you can get debug symbols. You also won't have to restart your tf2 client.

Also have you thought about moving the project to github?


could you please help me. I've spent many hours trying to get this to compile and i'm stuck at this:

/usr/bin/gcc-3.4 -o ./vcpm ./obj/vcpm/makefilecreator.o ./obj/vcpm/vprojtomake.o ./obj/vcpm/vcprojconvert.o ./obj/vcpm/public/characterset.o ./obj/vcpm/public/interface.o ./obj/vcpm/public/generichash.o ./obj/vcpm/public/KeyValues.o ./obj/vcpm/public/stringpool.o ./obj/vcpm/public/utlbuffer.o ./obj/vcpm/public/utlsymbol.o ./obj/vcpm/public/strtools.o ./obj/vcpm/tinyxml/tinyxml.o ./obj/vcpm/tinyxml/tinyxmlerror.o ./obj/vcpm/tinyxml/tinyxmlparser.o ./obj/vcpm/tinyxml/tinystr.o -lm -ldl -Wl,-rpath /home/steam/tf2/bin /home/steam/tf2/bin/libtier0_srv.so /home/steam/tf2/bin/vstdlib_i486.so -Wl,-rpath-link /home/steam/tf2/bin
/home/steam/tf2/bin/libtier0_srv.so: error adding symbols: File in wrong format
collect2: ld returned 1 exit status

User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post Apr 27 2015, 06:37 AM
Post #37


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



QUOTE(JRob @ Apr 25 2015, 08:56 PM) *

Well I guess it doesn't really matter since I can use sourcemod to change names. But it is really strange that they started to work randomly.

The only thing I did differently was that I gave up, and left the server alone. The next day I added my steamid to accessinfo.ini, rebooted the server, and then it started to work.

Maybe I could provide you with a Linux VM so you could make sure rcbot works on Linux? It is really much nicer than running on Windows. It is really easy to add libraries to it and when the server crashes, you can get debug symbols. You also won't have to restart your tf2 client.

Also have you thought about moving the project to github?


It could be something to do with the server hibernating when there are no human players that join. You might be able to disable hibernating, I'm uncertain about dedicated servers as I never use them, but I've heard similar cases. check http://rcbot.bots-united.com/forums/index.php?showtopic=1727

I haven't thought about gihub, but if it's easier for linux developers to have a look at and edit the code I'd consider it eventually.

QUOTE(incorporator @ Apr 26 2015, 12:18 PM) *

could you please help me. I've spent many hours trying to get this to compile and i'm stuck at this:

/usr/bin/gcc-3.4 -o ./vcpm ./obj/vcpm/makefilecreator.o ./obj/vcpm/vprojtomake.o ./obj/vcpm/vcprojconvert.o ./obj/vcpm/public/characterset.o ./obj/vcpm/public/interface.o ./obj/vcpm/public/generichash.o ./obj/vcpm/public/KeyValues.o ./obj/vcpm/public/stringpool.o ./obj/vcpm/public/utlbuffer.o ./obj/vcpm/public/utlsymbol.o ./obj/vcpm/public/strtools.o ./obj/vcpm/tinyxml/tinyxml.o ./obj/vcpm/tinyxml/tinyxmlerror.o ./obj/vcpm/tinyxml/tinyxmlparser.o ./obj/vcpm/tinyxml/tinystr.o -lm -ldl -Wl,-rpath /home/steam/tf2/bin /home/steam/tf2/bin/libtier0_srv.so /home/steam/tf2/bin/vstdlib_i486.so -Wl,-rpath-link /home/steam/tf2/bin
/home/steam/tf2/bin/libtier0_srv.so: error adding symbols: File in wrong format
collect2: ld returned 1 exit status


perhaps try adding -m32 in the gcc command line
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
JRob
post Apr 27 2015, 07:29 PM
Post #38


Advanced Member
***

Group: Members
Posts: 52
Joined: 30-April 11
Member No.: 1,970



QUOTE(Cheeseh @ Apr 27 2015, 06:37 AM) *

It could be something to do with the server hibernating when there are no human players that join. You might be able to disable hibernating, I'm uncertain about dedicated servers as I never use them, but I've heard similar cases. check http://rcbot.bots-united.com/forums/index.php?showtopic=1727

I haven't thought about gihub, but if it's easier for linux developers to have a look at and edit the code I'd consider it eventually.
perhaps try adding -m32 in the gcc command line


Github has pull requests and a better interface. And since nearly all the people doing open source projects are there so you are more likely to get contributions. There is a git gui for windows.

But mainly the problem seems to be that you don't have a linux environment to build on.

I really find it much easier to debug issues in Linux. On Linux when an extension crashes, you will get a stack trace with the function names. On Windows, these symbols are stripped.

Maybe you won't have this problem anymore since you ported the plugin to metamod so all the platform specific code is handled by sourcehooks. But it is still rather annoying to have to figure out by trial and error which cpp files to add or remove.

I suppose I could just keep my own copy of rcbot that compiles on Linux.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
incorporator
post Apr 28 2015, 07:44 AM
Post #39


Newbie
*

Group: Members
Posts: 5
Joined: 24-April 15
Member No.: 2,382



got everything forced to m32 but i had issues with my makefile not actually making the thing at the end


Makefile.RCBot2Meta_ReleaseWin32
vcpm
Makefile.RCBot2Meta_Release_NonHomeFolderWin32
Makefile.RCBot2Meta_DebugWin32
Makefile.rcbot2
files.vdf

i have no idea what to do with these. please help me
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
Cheeseh
post May 2 2015, 09:45 AM
Post #40


Admin
*****

Group: Admin
Posts: 3,055
Joined: 11-September 03
From: uk
Member No.: 1



QUOTE(incorporator @ Apr 28 2015, 08:44 AM) *

got everything forced to m32 but i had issues with my makefile not actually making the thing at the end
Makefile.RCBot2Meta_ReleaseWin32
vcpm
Makefile.RCBot2Meta_Release_NonHomeFolderWin32
Makefile.RCBot2Meta_DebugWin32
Makefile.rcbot2
files.vdf

i have no idea what to do with these. please help me

you don't need to do anything with them specifically. what's the error?
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

3 Pages V < 1 2 3 >
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 28th March 2024 - 04:58 PM