* Added "Error: Command disabled." error message
CoreCommands:
* Added "Error: Command disabled." error message
RenX.Core:
* Fixed all known crashing/corruption issues related to the new BanDatabase.
* Replaced 'banCheck' processLine lambda function
* bIsCompetitive is now tracked as 'competitive'
* Added checks for commands disabled when 'competitive' is true
RenX.Commands:
* Combined Date and Time fields in BanSearch IRC Command results.
* Added error message for when certain commands are disabled/not supported by a server
* Global ban checks are now run after a "ban" or "addban" command is executed
source->sendMessage(channel,STRING_LITERAL_AS_REFERENCE("All deployables (c4, beacons, etc) belonging to ")+RenX::getFormattedPlayerName(player)+STRING_LITERAL_AS_REFERENCE(IRCCOLOR" have been disarmed."));
else
source->sendMessage(channel,"Error: Server does not support disarms."_jrs);
}
else
source->sendNotice(nick,STRING_LITERAL_AS_REFERENCE("Error: Player not found."));
source->sendMessage(channel,STRING_LITERAL_AS_REFERENCE("All C4 belonging to ")+RenX::getFormattedPlayerName(player)+STRING_LITERAL_AS_REFERENCE(IRCCOLOR" have been disarmed."));
else
source->sendMessage(channel,"Error: Server does not support disarms."_jrs);
}
else
source->sendNotice(nick,STRING_LITERAL_AS_REFERENCE("Error: Player not found."));
source->sendMessage(channel,STRING_LITERAL_AS_REFERENCE("All beacons belonging to ")+RenX::getFormattedPlayerName(player)+STRING_LITERAL_AS_REFERENCE(IRCCOLOR" have been disarmed."));
else
source->sendMessage(channel,"Error: Server does not support disarms."_jrs);
}
else
source->sendNotice(nick,STRING_LITERAL_AS_REFERENCE("Error: Player not found."));
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[0]->timestamp+last_to_expire[0]->length)));
if(last_to_expire[0]->length==0)
this->forceKickPlayer(player,Jupiter::StringS::Format("You were permanently banned from the server on %s for: %.*s",timeStr,last_to_expire[0]->reason.size(),last_to_expire[0]->reason.ptr()));
else
this->forceKickPlayer(player,Jupiter::StringS::Format("You are banned from the server until %s for: %.*s",timeStr,last_to_expire[0]->reason.size(),last_to_expire[0]->reason.ptr()));
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[1]->timestamp+last_to_expire[1]->length)));
this->mute(player);
if(last_to_expire[1]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently muted on this server on %s for: %.*s",timeStr,last_to_expire[1]->reason.size(),last_to_expire[1]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are muted on this server until %s for: %.*s",timeStr,last_to_expire[1]->reason.size(),last_to_expire[1]->reason.ptr()));
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[2]->timestamp+last_to_expire[2]->length)));
if(last_to_expire[2]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently bot-muted on this server on %s for: %.*s",timeStr,last_to_expire[2]->reason.size(),last_to_expire[2]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are bot-muted on this server until %s for: %.*s",timeStr,last_to_expire[2]->reason.size(),last_to_expire[2]->reason.ptr()));
}
if(last_to_expire[3]!=nullptr)// Vote ban
{
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[3]->timestamp+last_to_expire[3]->length)));
if(last_to_expire[3]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently vote-muted on this server on %s for: %.*s",timeStr,last_to_expire[3]->reason.size(),last_to_expire[3]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are vote-muted on this server until %s for: %.*s",timeStr,last_to_expire[3]->reason.size(),last_to_expire[3]->reason.ptr()));
}
if(last_to_expire[4]!=nullptr)// Mine ban
{
this->mineBan(player);
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[4]->timestamp+last_to_expire[4]->length)));
if(last_to_expire[4]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently mine-banned on this server on %s for: %.*s",timeStr,last_to_expire[4]->reason.size(),last_to_expire[4]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are mine-banned on this server until %s for: %.*s",timeStr,last_to_expire[4]->reason.size(),last_to_expire[4]->reason.ptr()));
}
if(last_to_expire[5]!=nullptr)// Ladder ban
{
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[5]->timestamp+last_to_expire[5]->length)));
if(last_to_expire[5]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently ladder-banned on this server on %s for: %.*s",timeStr,last_to_expire[5]->reason.size(),last_to_expire[5]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are ladder-banned on this server until %s for: %.*s",timeStr,last_to_expire[5]->reason.size(),last_to_expire[5]->reason.ptr()));
Jupiter::StringLmsg=Jupiter::StringL::Format(IRCCOLOR"04[Alert] "IRCCOLORIRCBOLD"%.*s"IRCBOLDIRCCOLOR" is marked for monitoring by %.*s for: \"%.*s\". Please keep an eye on them in ",fmtName.size(),fmtName.ptr(),last_to_expire[6]->banner.size(),last_to_expire[6]->banner.ptr(),last_to_expire[6]->reason.size(),last_to_expire[6]->reason.ptr());
Jupiter::StringSmsg2=Jupiter::StringS::Format(IRCCOLOR"04[Alert] "IRCCOLORIRCBOLD"%.*s"IRCBOLDIRCCOLOR" is marked for monitoring by %.*s for: \"%.*s\"."IRCCOLOR,fmtName.size(),fmtName.ptr(),last_to_expire[6]->banner.size(),last_to_expire[6]->banner.ptr(),last_to_expire[6]->reason.size(),last_to_expire[6]->reason.ptr());
RenX::Server::forceKickPlayer(player,Jupiter::StringS::Format("You are permanently banned from the server for: %.*s",reason.size(),reason.ptr()));
}
elseif(banner.isNotEmpty())
RenX::Server::forceKickPlayer(player,Jupiter::StringS::Format("You are banned from the server by %.*s for the next %d days, %d:%d:%d for: %.*s",banner.size(),banner.ptr(),length/86400,length%3600,(length%3600)/60,length%60,reason.size(),reason.ptr()));
RenX::Server::forceKickPlayer(player,Jupiter::StringS::Format("You are banned from the server by %.*s for the next %lld days, %.2d:%.2d:%.2d for: %.*s",banner.size(),banner.ptr(),static_cast<longlong>(length/86400),static_cast<int>(length%3600),static_cast<int>((length%3600)/60),static_cast<int>(length%60),reason.size(),reason.ptr()));
else
RenX::Server::forceKickPlayer(player,Jupiter::StringS::Format("You are banned from the server for the next %d days, %d:%d:%d for: %.*s",length/86400,length%3600,(length%3600)/60,length%60,reason.size(),reason.ptr()));
RenX::Server::forceKickPlayer(player,Jupiter::StringS::Format("You are banned from the server for the next %lld days, %.2d:%.2d:%.2d for: %.*s",static_cast<longlong>(length/86400),static_cast<int>(length%3600),static_cast<int>((length%3600)/60),static_cast<int>(length%60),reason.size(),reason.ptr()));
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[0]->timestamp+last_to_expire[0]->length)));
if(last_to_expire[0]->length==0)
this->forceKickPlayer(player,Jupiter::StringS::Format("You were permanently banned from the server on %s for: %.*s",timeStr,last_to_expire[0]->reason.size(),last_to_expire[0]->reason.ptr()));
else
this->forceKickPlayer(player,Jupiter::StringS::Format("You are banned from the server until %s for: %.*s",timeStr,last_to_expire[0]->reason.size(),last_to_expire[0]->reason.ptr()));
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[1]->timestamp+last_to_expire[1]->length)));
this->mute(player);
if(last_to_expire[1]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently muted on this server on %s for: %.*s",timeStr,last_to_expire[1]->reason.size(),last_to_expire[1]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are muted on this server until %s for: %.*s",timeStr,last_to_expire[1]->reason.size(),last_to_expire[1]->reason.ptr()));
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[2]->timestamp+last_to_expire[2]->length)));
if(last_to_expire[2]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently bot-muted on this server on %s for: %.*s",timeStr,last_to_expire[2]->reason.size(),last_to_expire[2]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are bot-muted on this server until %s for: %.*s",timeStr,last_to_expire[2]->reason.size(),last_to_expire[2]->reason.ptr()));
}
if(last_to_expire[3]!=nullptr)// Vote ban
{
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[3]->timestamp+last_to_expire[3]->length)));
if(last_to_expire[3]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently vote-muted on this server on %s for: %.*s",timeStr,last_to_expire[3]->reason.size(),last_to_expire[3]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are vote-muted on this server until %s for: %.*s",timeStr,last_to_expire[3]->reason.size(),last_to_expire[3]->reason.ptr()));
}
if(last_to_expire[4]!=nullptr)// Mine ban
{
this->mineBan(player);
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[4]->timestamp+last_to_expire[4]->length)));
if(last_to_expire[4]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently mine-banned on this server on %s for: %.*s",timeStr,last_to_expire[4]->reason.size(),last_to_expire[4]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are mine-banned on this server until %s for: %.*s",timeStr,last_to_expire[4]->reason.size(),last_to_expire[4]->reason.ptr()));
}
if(last_to_expire[5]!=nullptr)// Ladder ban
{
strftime(timeStr,sizeof(timeStr),"%b %d %Y at %H:%M:%S",localtime(std::addressof<consttime_t>(last_to_expire[5]->timestamp+last_to_expire[5]->length)));
if(last_to_expire[5]->length==0)
this->sendMessage(player,Jupiter::StringS::Format("You were permanently ladder-banned on this server on %s for: %.*s",timeStr,last_to_expire[5]->reason.size(),last_to_expire[5]->reason.ptr()));
else
this->sendMessage(player,Jupiter::StringS::Format("You are ladder-banned on this server until %s for: %.*s",timeStr,last_to_expire[5]->reason.size(),last_to_expire[5]->reason.ptr()));
Jupiter::StringLmsg=Jupiter::StringL::Format(IRCCOLOR"04[Alert] "IRCCOLORIRCBOLD"%.*s"IRCBOLDIRCCOLOR" is marked for monitoring by %.*s for: \"%.*s\". Please keep an eye on them in ",fmtName.size(),fmtName.ptr(),last_to_expire[6]->banner.size(),last_to_expire[6]->banner.ptr(),last_to_expire[6]->reason.size(),last_to_expire[6]->reason.ptr());
Jupiter::StringSmsg2=Jupiter::StringS::Format(IRCCOLOR"04[Alert] "IRCCOLORIRCBOLD"%.*s"IRCBOLDIRCCOLOR" is marked for monitoring by %.*s for: \"%.*s\"."IRCCOLOR,fmtName.size(),fmtName.ptr(),last_to_expire[6]->banner.size(),last_to_expire[6]->banner.ptr(),last_to_expire[6]->reason.size(),last_to_expire[6]->reason.ptr());
server->sendMessage(player,Jupiter::StringS::Format("You are now authenticated with access level %d; group: %.*s.",player->access,group->name.size(),group->name.ptr()));
server->sendLogChan(IRCCOLOR"03[Authentication] "IRCBOLD"%.*s"IRCBOLDIRCCOLOR" is now authenticated with access level %d; group: %.*s.",playerName.size(),playerName.ptr(),player->access,group->name.size(),group->name.ptr());