.:: Bots United ::.  
filebase forums discord server github wiki web
cubebot epodbot fritzbot gravebot grogbot hpbbot ivpbot jkbotti joebot
meanmod podbotmm racc rcbot realbot sandbot shrikebot soulfathermaps yapb

Go Back   .:: Bots United ::. > Cyborg Factory > ShrikeBot > Bug Base
Bug Base Catch 'em all !!! (and post them here)

Reply
 
Thread Tools
Bogus Message Type, Server Crashes
Old
  (#1)
Spykie
Guest
 
Status:
Posts: n/a
Default Bogus Message Type, Server Crashes - 17-04-2004

When I wake up in the morning and check my server it's showing this error:
Code:
Tried to create a message with a bogus message type (0)
Any idea why it's doing this?


Keep up the great work!
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#2)
Cpl. Shrike
ShrikeBot Coder/Moderator
 
Cpl. Shrike's Avatar
 
Status: Offline
Posts: 550
Join Date: Mar 2004
Location: The Netherlands
Default Re: Bogus Message Type, Server Crashes - 17-04-2004

Quote:
Tried to create a message with a bogus message type (0)
Well i have never seen that message before. ???

Do you get that alot ??
Or was it a one time glitch.
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#3)
Spykie
Guest
 
Status:
Posts: n/a
Default Re: Bogus Message Type, Server Crashes - 18-04-2004

Every morning when I woke up and the server is filled with 20-32 players
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#4)
Pierre-Marie Baty
Roi de France
 
Pierre-Marie Baty's Avatar
 
Status: Offline
Posts: 5,049
Join Date: Nov 2003
Location: 46°43'60N 0°43'0W 0.187A
Default Re: Bogus Message Type, Server Crashes - 19-04-2004

I've already seen this message before...

For me it was a memory problem... there must be a leak somewhere... or an overflow... or something. Ensure that when you free() stuff you never free it twice, and all the usual checks ...



RACC home - Bots-United: beer, babies & bots (especially the latter)
"Learn to think by yourself, else others will do it for you."
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#5)
Spykie
Guest
 
Status:
Posts: n/a
Default Re: Bogus Message Type, Server Crashes - 19-04-2004

Hmm I don't think I've ever done something like that...
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#6)
Pierre-Marie Baty
Roi de France
 
Pierre-Marie Baty's Avatar
 
Status: Offline
Posts: 5,049
Join Date: Nov 2003
Location: 46°43'60N 0°43'0W 0.187A
Default Re: Bogus Message Type, Server Crashes - 19-04-2004

rofl, nah, obviously

my reply was about coding, it was directed at Cpl Shrike, not you, sorry dude



RACC home - Bots-United: beer, babies & bots (especially the latter)
"Learn to think by yourself, else others will do it for you."
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#7)
Cpl. Shrike
ShrikeBot Coder/Moderator
 
Cpl. Shrike's Avatar
 
Status: Offline
Posts: 550
Join Date: Mar 2004
Location: The Netherlands
Default Re: Bogus Message Type, Server Crashes - 19-04-2004



Guess i need to get me memory debugger.

Im not skilled on that yet though o_O
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#8)
Spykie
Guest
 
Status:
Posts: n/a
Default Re: Bogus Message Type, Server Crashes - 19-04-2004

lol ok guys, thanks for the hard work
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#9)
botman
Super Moderator
 
Status: Offline
Posts: 280
Join Date: Jan 2004
Location: Plano, TX
Default Re: Bogus Message Type, Server Crashes - 21-04-2004

"bogus message type (0)" errors are caused when you try to send a network message without registering it first. For example, if you had something like this...
Code:
pfnMessageBegin( MSG_ONE, gmsgTextMsg, NULL, pEntity );
Code:
pfnWriteByte( msg_dest );
pfnWriteString( msg_name );
pfnMessageEnd();

...you can get that error if you never registered 'gmsgTextMsg' using REG_USER_MSG.

You should have the code be something like this instead...
Code:
if (gmsgTextMsg == 0)
Code:
gmsgTextMsg = REG_USER_MSG( "TextMsg", -1 );

pfnMessageBegin( MSG_ONE, gmsgTextMsg, NULL, pEntity );
pfnWriteByte( msg_dest );
pfnWriteString( msg_name );
pfnMessageEnd();

It should be pretty simple to search your bot code for "MESSAGE_BEGIN" or "pfnMessageBegin" and find all the places where you're not checking the message ID for == 0.

EDIT: I have NO idea why it's putting the "Courier New" crap in there.

botman

Last edited by botman; 21-04-2004 at 01:23..
  
Reply With Quote
Re: Bogus Message Type, Server Crashes
Old
  (#10)
Pierre-Marie Baty
Roi de France
 
Pierre-Marie Baty's Avatar
 
Status: Offline
Posts: 5,049
Join Date: Nov 2003
Location: 46°43'60N 0°43'0W 0.187A
Default Re: Bogus Message Type, Server Crashes - 21-04-2004

...that's because you must have copypasted this code, botman...
I know, my [ code ] tags suck But the default ones have this bug, too.



RACC home - Bots-United: beer, babies & bots (especially the latter)
"Learn to think by yourself, else others will do it for you."
  
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
vBulletin Skin developed by: vBStyles.com