goblin and rat tweaks
timfa Tim Falken · pushed by timfa
Authored 2026-09-01 · 2 months ago
- Hash
822c794c06729dd726056ff686800660b7130f13- Parent
5a37bff8
3 files changed
+44
−5
The contents of this binary file are not shown.
The contents of this binary file are not shown.
@@ -10,12 +10,14 @@ import { spellDefinition } from "./spells.js";
10
10
import { ClothTier } from "./materialTiers.js";
11
11
import { ClothItemId } from "./clothItems.js";
12
12
import { EssenceItemId } from "./essenceItems.js";
13
import { SwordItemId } from "./swordItems.js";
13
14
import { MagicElement } from "./attackTypes.js";
14
15
15
16
export const MobId = Object.freeze({
16
17
deer: "deer",
17
18
pigeon: "pigeon",
18
19
rat: "rat",
20
goblin: "goblin",
19
21
chicken: "chicken",
20
22
sheep: "sheep",
21
23
cashmereGoat: "cashmere-goat",
@@ -108,7 +110,7 @@ export const MOB_DEFINITIONS = Object.freeze({
108
110
displayName: "Rat",
109
111
health: 12,
110
112
maxHealth: 12,
111
attackSkill: 3,
113
attackSkill: 1,
112
114
attackCooldownMs: 900,
113
115
drops: Object.freeze([]),
114
116
sells: Object.freeze([]),
@@ -129,6 +131,32 @@ export const MOB_DEFINITIONS = Object.freeze({
129
131
framesPerRow: 1,
130
132
animationSpeed: 0
131
133
}),
134
[MobId.goblin]: Object.freeze({
135
mobTypeId: MobId.goblin,
136
key: "goblin",
137
assetFolder: "mobs",
138
displayName: "Goblin",
139
health: 16,
140
maxHealth: 16,
141
attackSkill: 5,
142
attackCooldownMs: 850,
143
drops: Object.freeze([]),
144
sells: Object.freeze([]),
145
dialogue: Object.freeze([]),
146
persistent: false,
147
flying: false,
148
freeFlight: false,
149
ambient: false,
150
talkable: false,
151
untargetable: false,
152
aggressive: true,
153
aggroRangeTiles: 5,
154
gait: "walk",
155
sex: "male",
156
frames: 1,
157
framesPerRow: 1,
158
animationSpeed: 0
159
}),
132
160
[MobId.chicken]: Object.freeze({
133
161
mobTypeId: MobId.chicken,
134
162
key: "chicken",
@@ -450,9 +478,11 @@ export function defaultSpawnerConfig (spawnerId, mobTypeId = MobId.deer)
450
478
const bodyNpc = humanoid || townGuard || centralExchange;
451
479
const level = townGuard
452
480
? 30
453
: (mobTypeId === MobId.sprite
454
? 25
455
: (mobTypeId === MobId.fairy ? 70 : 1));
481
: (mobTypeId === MobId.goblin
482
? 5
483
: (mobTypeId === MobId.sprite
484
? 25
485
: (mobTypeId === MobId.fairy ? 70 : 1)));
456
486
const bounty = townGuard ? 500 : 0;
457
487
return {
458
488
spawnerId,
@@ -479,7 +509,16 @@ export function defaultSpawnerConfig (spawnerId, mobTypeId = MobId.deer)
479
509
weapon: WoodItemId.oakQuarterstaff,
480
510
offhand: null
481
511
}
482
: emptySpawnerEquipment(),
512
: (mobTypeId === MobId.goblin
513
? {
514
head: null,
515
chest: null,
516
legs: null,
517
boots: null,
518
weapon: SwordItemId.bronzeSword,
519
offhand: null
520
}
521
: emptySpawnerEquipment()),
483
522
sells: [],
484
523
drops: [],
485
524
spells: [],
@@ -10,12 +10,14 @@ import { spellDefinition } from "./spells.js";10
import { ClothTier } from "./materialTiers.js";10
import { ClothTier } from "./materialTiers.js";11
import { ClothItemId } from "./clothItems.js";11
import { ClothItemId } from "./clothItems.js";12
import { EssenceItemId } from "./essenceItems.js";12
import { EssenceItemId } from "./essenceItems.js";13
import { SwordItemId } from "./swordItems.js";13
import { MagicElement } from "./attackTypes.js";14
import { MagicElement } from "./attackTypes.js";14
15
15
export const MobId = Object.freeze({16
export const MobId = Object.freeze({16
deer: "deer",17
deer: "deer",17
pigeon: "pigeon",18
pigeon: "pigeon",18
rat: "rat",19
rat: "rat",20
goblin: "goblin",19
chicken: "chicken",21
chicken: "chicken",20
sheep: "sheep",22
sheep: "sheep",21
cashmereGoat: "cashmere-goat",23
cashmereGoat: "cashmere-goat",@@ -108,7 +110,7 @@ export const MOB_DEFINITIONS = Object.freeze({108
displayName: "Rat",110
displayName: "Rat",109
health: 12,111
health: 12,110
maxHealth: 12,112
maxHealth: 12,111
attackSkill: 3,113
attackSkill: 1,112
attackCooldownMs: 900,114
attackCooldownMs: 900,113
drops: Object.freeze([]),115
drops: Object.freeze([]),114
sells: Object.freeze([]),116
sells: Object.freeze([]),@@ -129,6 +131,32 @@ export const MOB_DEFINITIONS = Object.freeze({129
framesPerRow: 1,131
framesPerRow: 1,130
animationSpeed: 0132
animationSpeed: 0131
}),133
}),134
[MobId.goblin]: Object.freeze({135
mobTypeId: MobId.goblin,136
key: "goblin",137
assetFolder: "mobs",138
displayName: "Goblin",139
health: 16,140
maxHealth: 16,141
attackSkill: 5,142
attackCooldownMs: 850,143
drops: Object.freeze([]),144
sells: Object.freeze([]),145
dialogue: Object.freeze([]),146
persistent: false,147
flying: false,148
freeFlight: false,149
ambient: false,150
talkable: false,151
untargetable: false,152
aggressive: true,153
aggroRangeTiles: 5,154
gait: "walk",155
sex: "male",156
frames: 1,157
framesPerRow: 1,158
animationSpeed: 0159
}),132
[MobId.chicken]: Object.freeze({160
[MobId.chicken]: Object.freeze({133
mobTypeId: MobId.chicken,161
mobTypeId: MobId.chicken,134
key: "chicken",162
key: "chicken",@@ -450,9 +478,11 @@ export function defaultSpawnerConfig (spawnerId, mobTypeId = MobId.deer)450
const bodyNpc = humanoid || townGuard || centralExchange;478
const bodyNpc = humanoid || townGuard || centralExchange;451
const level = townGuard479
const level = townGuard452
? 30480
? 30453
: (mobTypeId === MobId.sprite481
: (mobTypeId === MobId.goblin454
? 25482
? 5455
: (mobTypeId === MobId.fairy ? 70 : 1));483
: (mobTypeId === MobId.sprite484
? 25485
: (mobTypeId === MobId.fairy ? 70 : 1)));456
const bounty = townGuard ? 500 : 0;486
const bounty = townGuard ? 500 : 0;457
return {487
return {458
spawnerId,488
spawnerId,@@ -479,7 +509,16 @@ export function defaultSpawnerConfig (spawnerId, mobTypeId = MobId.deer)479
weapon: WoodItemId.oakQuarterstaff,509
weapon: WoodItemId.oakQuarterstaff,480
offhand: null510
offhand: null481
}511
}482
: emptySpawnerEquipment(),512
: (mobTypeId === MobId.goblin513
? {514
head: null,515
chest: null,516
legs: null,517
boots: null,518
weapon: SwordItemId.bronzeSword,519
offhand: null520
}521
: emptySpawnerEquipment()),483
sells: [],522
sells: [],484
drops: [],523
drops: [],485
spells: [],524
spells: [],