Args refactoring

This commit is contained in:
2020-04-29 19:05:58 +03:00
parent 0b159d2397
commit d5f780197f
27 changed files with 29 additions and 29 deletions

View File

@ -1,6 +1,6 @@
import { ConsoleLogger, Logger } from '../Logger';
import { DataStorage } from '../DataStorage';
import { Args } from '../Args';
import { Args } from './Args';
const NAMESPACE = 'actions.v1';
const QUEUE_NAME = 'queue';

21
src/Queue/Args.ts Normal file
View File

@ -0,0 +1,21 @@
import { TaskId } from './TaskQueue';
import { ResourcesInterface } from '../Core/Resources';
import { CoordinatesInterface } from '../Core/Village';
export interface Args {
taskId?: TaskId;
targetTaskId?: TaskId;
villageId?: number;
buildId?: number;
categoryId?: number;
sheetId?: number;
tabId?: number;
buildTypeId?: number;
troopId?: number;
trainCount?: number;
resources?: ResourcesInterface;
coordinates?: CoordinatesInterface;
level?: number;
selector?: string;
path?: string;
}

View File

@ -1,7 +1,7 @@
import { uniqId } from '../utils';
import { ConsoleLogger, Logger } from '../Logger';
import { DataStorage } from '../DataStorage';
import { Args } from '../Args';
import { Args } from './Args';
const NAMESPACE = 'tasks:v1';
const QUEUE_NAME = 'queue';