名字限制
parent
dcf5a3bcfa
commit
eb6cdbc27b
|
@ -107,12 +107,12 @@ public class PlayerLogic {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
if (length > SGameSetting.getGameSetting().getMaxNameLength() || length < 1) {
|
if (length > SGameSetting.getGameSetting().getMaxNameLength() || length < 1) {
|
||||||
MessageUtil.sendErrorResponse(iSession, Global.RENAME_DIRTY, msgId, "名字长度不符!");
|
MessageUtil.sendErrorResponse(iSession, Global.RENAME_SIZE_ERROR, msgId, "名字长度不符!");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
boolean result = ShieldedWordUtils.checkName( name,true);
|
boolean result = ShieldedWordUtils.checkName( name,true);
|
||||||
if (!result) {
|
if (!result) {
|
||||||
MessageUtil.sendErrorResponse(iSession, Global.RENAME_SIZE_ERROR, msgId, "名字不合法");
|
MessageUtil.sendErrorResponse(iSession, Global.RENAME_DIRTY, msgId, "名字不合法");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
|
Loading…
Reference in New Issue