problems with new gametype

  • Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.
After reading a few tutorials there, i tried to subclass DeathMatchPlus (called it MyGameDebugInfo) and change a few simple things (added a log comment and a subclassed Bot), but i can't quite get it to work. My .int file is:

[Public]
Object=(Name=MyGameDebug.MyGameDebugInfo,Class=Class,MetaClass=Botpack.TournamentGameInfo)
Preferences=(Caption="Debug DeathMatch",Parent="Game Types",Class=MyGameDebug.MyGameDebugInfo,Immediate=True)

Well i get a new entry in the gametypes menu at the bottom of the list, called "DeathMatchPlus", and when i run my map with it, it doesn't call my customized version. Shouldn't it show up as "Debug Deathmatch"?

Then, in Spawnbot i changed the var declaration from type bot to:

local DebugBot NewBot;

and the two lines that spawn the bots to:

NewBot = Spawn(class'MyGameDebug.DebugBot',,,StartSpot.Location,StartSpot.Rotation);

The only thing different in DebugBot is i added a line to FellOutOfTheWorld() to log the bot's location ...

*******************************

Two main problems are i can't normally get it to run my custom subclass of DeathMatchPlus, and then once i got it to run launching out of UED2 (first game only; once i went to Practice Session and started another game it used the normal code), the log showed many errors involving not finding meshes for the bots during Animation calls, plus they were invisible in the game and didn't move around, just stayed in place.

I didn't mess around with PRI's like in the tutorials because i have no changes to make to the standard PRI ... I'm missing something about how all this works i guess. I think it's real close but something is not quite right.
 

ca

CHiMERiC Grandmaster
Oct 11, 1999
84
0
0
www.unrealscript.com
The menu listing of the game types looks up the string GameName in the GameInfo class instead of referring to the .int file.

defaultproperties
{
GameName="Debug DeathMatch"
}

Log the Login() function or something to make sure you're actually running your gametype. I usually test via the commandline (as loading uwindows is slow):

unrealtournament dm-agony?game=mypkg.mygameinfo

You can always double-check the log file too, as it should show the gametype loaded when it parses the url.
 

Captain Kewl

I know kewl.
Feb 13, 2001
794
0
0
IN YOUR HOUSE
Visit site
What package is DebugBot in? If it's compiled in with MyGameDebug, as it seems to be as referred to in your gameInfo:

NewBot = Spawn(class'MyGameDebug.DebugBot',,,StartSpot.Location,StartSpot.Rotation);

You'd probably want the int file to say

Object=(Name=MyGameDebug.DebugBot,Class=Class,MetaClass=Botpack.Bot,Description="DebugBot")

Also, make sure Description matches the MenuName defaultproperty of the bot.
 
Well, when i couldn't get the gametype to work, i made a package called DebugBot with just the Bot subclass in it (also called DebugBot), hence my .int file:

Object=(Name=DebugBot.DebugBot,Class=Class,MetaClass=Botpack.Bot,Description="DebugBot")


However, i was unaware of the MenuName default property and made no changes to it ... Don't know if a mismatch between that and my Description in .int could cause it not to work, but i'll give it a try tomorrow.