Jump to content
SubSpace Forum Network

Recommended Posts

Posted

Hi everyone,

 

When working with MERVBot I noticed there was a bug / problem with the limited operators. Maybe I'm doing something wrong, maybe it is already fixed, however it doesnt work with me ;) . Here is the problem / bug:

 

When you have a mervbot online and you got acces to it, add a operator with limited acces.

!addop -l=1 SomePlayer

 

No problems here.. All works fine. However when you close the bot, the bot writes the added operators to the text file Operators.txt. So 'SomePlayer' is added to Operators like this:

1:SomePlayer:

 

No problems. Only when you start the bot, the following message is given:

Invalid Limited-level operator ignored: SomePlayer ()

 

The operator isnt added at all, it is ignored because it recognizes it as a invalid operator.

 

I think this is a bug, however it hasnt has to be smile.gif

 

Please check this and let me know how to resolve this.

 

Thank you,

MMaverick

Posted

What is the name of the player? I know that message appears when there is a % sign in a name or the name is an invalid SS name.

Here is another problem

void gotOperator(char *line)
{
String s = line;

Operator_Level level;
String name, p!@#$%^&*;

level = (Operator_Level)s.split(':').toInteger();
name = s.split(':');
p!@#$%^&* = s.split(':');

if ((level >= OP_Moderator && level <= OP_God) &&
 (!invalidName(name.msg))      )
{
 db->addOperator(name.msg, passmsg, level);

 printf("Added %s-level operator: %s (%s)\n", getLevelString(level), name.msg, passmsg);
}
else
 printf("Invalid %s-level operator ignored: %s (%s)\n", getLevelString(level), name.msg, passmsg);
}
enum Operator_Level
{
OP_Player,    // Requests information services
OP_Limited,    // Player with some privelages
OP_Moderator, 	 // Represents player interests
OP_SuperModerator,  // Manages moderators
OP_SysOp,    // Adds/removes/modifies available bot services
OP_Owner,    // Changes internal bot settings
OP_Duke,
OP_Baron,
OP_King,
OP_Emperor,
OP_RockStar,
OP_Q,
OP_God   	 // ...Some other ways to say "Owner"
};

 

if ((level >= OP_Moderator && level <= OP_God) &&

(!invalidName(name.msg))

Should be

if ((level >= OP_Limited&& level <= OP_God) &&

(!invalidName(name.msg))

 

ill email catid about it, i added the fix to this post. For some reason .net compiles merv 100k smaller than vc++6

Guest
This topic is now closed to further replies.
×
×
  • Create New...