This commit is contained in:
Vasyl Kazakov
2026-05-29 18:01:05 +03:00
parent 2633be60a1
commit 6363396f84
20 changed files with 978 additions and 81 deletions
@@ -0,0 +1,31 @@
import { PropType } from "../Map/PropType";
import { ResourceType } from "./ResourceType";
export type DropRule = {
resource: ResourceType;
minTotal: number;
maxTotal: number;
minSpawnHits: number;
maxSpawnHits: number;
};
export const PROP_DROPS: Record<PropType, DropRule[]> = {
[PropType.Box]: [
{
resource: ResourceType.Wood,
minTotal: 1,
maxTotal: 3,
minSpawnHits: 1,
maxSpawnHits: 2,
},
],
};
export function resolvePropType(objectName: string): PropType {
const name = objectName.toLowerCase();
if (name.includes("box") || name.includes("crate") || name.includes("wood")) {
return PropType.Box;
}
return PropType.Box;
}