forked from devsam/core
feat: PenaltyKey::NoChiefTurnInput
This commit is contained in:
@@ -3,6 +3,7 @@ namespace sammo;
|
||||
|
||||
use sammo\Command\GeneralCommand;
|
||||
use sammo\Command\NationCommand;
|
||||
use sammo\Enums\PenaltyKey;
|
||||
|
||||
function getGeneralTurnBrief(General $generalObj, array $turnList) {
|
||||
$result = [];
|
||||
@@ -434,6 +435,13 @@ function setNationCommand(int $generalID, array $turnList, string $command, ?arr
|
||||
];
|
||||
}
|
||||
|
||||
if($general->hasPenalty(PenaltyKey::NoChiefTurnInput)){
|
||||
return [
|
||||
'result'=>false,
|
||||
'reason'=>'수뇌 턴 입력 불가능'
|
||||
];
|
||||
}
|
||||
|
||||
try{
|
||||
$commandObj = buildNationCommandClass($command, $general, $env, $general->getLastTurn(), $arg);
|
||||
}
|
||||
|
||||
@@ -11,4 +11,6 @@ enum PenaltyKey: string{
|
||||
case NoChief = 'noChief';
|
||||
case NoAmbassador = 'noAmbassador';
|
||||
case NoBanGeneral = 'noBanGeneral';
|
||||
case NoChiefTurnInput = 'noChiefTurnInput';
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user