fix(game): 국가 수 판정에서 합성 재야를 제외한다
Ref nation table에 없는 id=0 행이 정찰 차단과 월간 경매 난수 소비에 관여하지 않도록 모집단을 맞춘다. Ref의 maxnation 건국 표시 제한도 실행 제약을 늘리지 않고 명령표에 이관한다.
This commit is contained in:
@@ -87,16 +87,18 @@ const buildWorld = (
|
||||
describe('monthly scout block actions', () => {
|
||||
it('blocks joining for all nations and globally locks policy changes', async () => {
|
||||
const world = buildWorld(0);
|
||||
world.addNation(buildNation(0, 0));
|
||||
await createScoutBlockHandler({ actionName: 'BlockScoutAction', getWorld: () => world })(
|
||||
[true],
|
||||
{ year: 200, month: 1, startyear: 190, currentEventID: 1, turnTime: new Date() },
|
||||
event
|
||||
);
|
||||
|
||||
expect(world.listNations().map((nation) => nation.meta)).toEqual([
|
||||
{ scout: 1, marker: 1 },
|
||||
{ scout: 1, marker: 2 },
|
||||
]);
|
||||
expect(Object.fromEntries(world.listNations().map((nation) => [nation.id, nation.meta]))).toEqual({
|
||||
0: { scout: 0, marker: 0 },
|
||||
1: { scout: 1, marker: 1 },
|
||||
2: { scout: 1, marker: 2 },
|
||||
});
|
||||
expect(world.getState().meta.block_change_scout).toBe(true);
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user