-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconstants.js
More file actions
56 lines (51 loc) · 1.81 KB
/
Copy pathconstants.js
File metadata and controls
56 lines (51 loc) · 1.81 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
// Map Builder — shared constants.
export const TOOLS = {
SELECT: 'select',
PAN: 'pan',
TERRAIN: 'terrain',
SHAPE: 'shape',
STAMP: 'stamp',
TEXT: 'text',
EYEDROPPER: 'eyedropper',
};
export const CATEGORIES = [
{ id: 'nature', label: 'Nature' },
{ id: 'medieval', label: 'Medieval' },
{ id: 'modern', label: 'Modern' },
{ id: 'transit', label: 'Transit' },
{ id: 'symbols', label: 'Symbols' },
{ id: 'decoration', label: 'Decoration' },
];
export const SHAPE_TYPES = [
{ id: 'coast', label: 'Coast / Land', spline: true },
{ id: 'river', label: 'River', spline: true },
{ id: 'road', label: 'Road', spline: true },
{ id: 'rail', label: 'Railway', spline: true },
{ id: 'wall', label: 'Wall', spline: true },
{ id: 'zone', label: 'Zone / District', spline: true, closed: true },
{ id: 'contour', label: 'Contour', spline: true },
{ id: 'polygon', label: 'Polygon', closed: true },
{ id: 'rect', label: 'Rectangle', drag: true },
{ id: 'ellipse', label: 'Ellipse', drag: true },
{ id: 'line', label: 'Line', drag: true },
{ id: 'arrow', label: 'Arrow', drag: true },
{ id: 'freehand', label: 'Freehand', freehand: true },
];
export const TERRAIN_MATERIALS = [
{ id: 'grass', label: 'Grass' },
{ id: 'forest', label: 'Forest floor' },
{ id: 'water', label: 'Water' },
{ id: 'waterDeep', label: 'Deep water' },
{ id: 'sand', label: 'Sand' },
{ id: 'stone', label: 'Stone' },
{ id: 'snow', label: 'Snow' },
{ id: 'dirt', label: 'Dirt' },
{ id: 'road', label: 'Paving' },
];
export const DEFAULT_SPRITE_SIZE = 64;
export const SPRITE_PAD = 10; // bitmap padding so shadows/outlines aren't clipped
export const MIN_ZOOM = 0.06;
export const MAX_ZOOM = 14;
export const HISTORY_LIMIT = 40;
export const GRID_DEFAULT = 48;
export const AUTOSAVE_KEY = 'fez.mapbuilder.autosave.v1';