@hytopia.com/examples 1.0.23 → 1.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/frontiers-rpg-game/assets/ui/hud.html +2 -2
- package/frontiers-rpg-game/assets/ui/index.html +19 -19
- package/frontiers-rpg-game/assets/ui/menus/backpack.html +3 -3
- package/frontiers-rpg-game/assets/ui/menus/crafting.html +2 -2
- package/frontiers-rpg-game/assets/ui/menus/dialogue.html +2 -2
- package/frontiers-rpg-game/assets/ui/menus/help.html +1 -1
- package/frontiers-rpg-game/assets/ui/menus/merchant.html +4 -4
- package/frontiers-rpg-game/assets/ui/menus/quests.html +2 -2
- package/frontiers-rpg-game/assets/ui/menus/skills.html +3 -3
- package/frontiers-rpg-game/dev/persistence/player-421.json +42 -0
- package/frontiers-rpg-game/dev/persistence/player-player-1.json +33 -0
- package/frontiers-rpg-game/dev/persistence/player-player-2.json +31 -0
- package/frontiers-rpg-game/dev/persistence/player-player-4.json +31 -0
- package/frontiers-rpg-game/src/GamePlayer.ts +0 -11
- package/frontiers-rpg-game/src/GameRegion.ts +6 -3
- package/package.json +1 -1
|
@@ -212,7 +212,7 @@
|
|
|
212
212
|
|
|
213
213
|
// Setup click events
|
|
214
214
|
hotbarSlots.forEach((slot, index) => {
|
|
215
|
-
slot.addEventListener('
|
|
215
|
+
slot.addEventListener('click', () => setActiveSlot(index));
|
|
216
216
|
});
|
|
217
217
|
|
|
218
218
|
// Setup keyboard events
|
|
@@ -233,7 +233,7 @@
|
|
|
233
233
|
};
|
|
234
234
|
|
|
235
235
|
Object.entries(buttons).forEach(([id, handler]) => {
|
|
236
|
-
document.getElementById(id).addEventListener('
|
|
236
|
+
document.getElementById(id).addEventListener('click', handler);
|
|
237
237
|
});
|
|
238
238
|
|
|
239
239
|
// Setup death overlay respawn button
|
|
@@ -957,12 +957,12 @@ window.ItemTooltips = (function() {
|
|
|
957
957
|
|
|
958
958
|
function setupEventListeners() {
|
|
959
959
|
const closeButton = document.querySelector('.backpack-close');
|
|
960
|
-
closeButton.addEventListener('
|
|
960
|
+
closeButton.addEventListener('click', closeBackpack);
|
|
961
961
|
|
|
962
962
|
// Setup slot click handlers
|
|
963
963
|
document.querySelectorAll('.backpack-slot, .backpack-wearable-slot, .backpack-hotbar-slot')
|
|
964
964
|
.forEach(slot => {
|
|
965
|
-
slot.addEventListener('
|
|
965
|
+
slot.addEventListener('click', e => {
|
|
966
966
|
e.preventDefault();
|
|
967
967
|
e.stopPropagation();
|
|
968
968
|
|
|
@@ -991,7 +991,7 @@ window.ItemTooltips = (function() {
|
|
|
991
991
|
});
|
|
992
992
|
|
|
993
993
|
// Setup click outside containers handler for item dropping
|
|
994
|
-
document.addEventListener('
|
|
994
|
+
document.addEventListener('click', e => {
|
|
995
995
|
// Only handle if we have a held item
|
|
996
996
|
if (!heldItem) return;
|
|
997
997
|
|
|
@@ -1900,7 +1900,7 @@ window.ItemTooltips = (function() {
|
|
|
1900
1900
|
|
|
1901
1901
|
// Event Listeners
|
|
1902
1902
|
function setupEventListeners() {
|
|
1903
|
-
document.querySelector('.skills-close').addEventListener('
|
|
1903
|
+
document.querySelector('.skills-close').addEventListener('click', closeSkills);
|
|
1904
1904
|
|
|
1905
1905
|
// Setup mobile tooltip handling
|
|
1906
1906
|
setupMobileTooltips();
|
|
@@ -1913,10 +1913,10 @@ window.ItemTooltips = (function() {
|
|
|
1913
1913
|
if (!isMobile) return;
|
|
1914
1914
|
|
|
1915
1915
|
// Add click handler to skills container for event delegation
|
|
1916
|
-
document.querySelector('.skills-skills-grid').addEventListener('
|
|
1916
|
+
document.querySelector('.skills-skills-grid').addEventListener('click', handleMobileTooltipClick);
|
|
1917
1917
|
|
|
1918
1918
|
// Add click handler to document to close tooltips when clicking outside
|
|
1919
|
-
document.addEventListener('
|
|
1919
|
+
document.addEventListener('click', handleDocumentClick);
|
|
1920
1920
|
}
|
|
1921
1921
|
|
|
1922
1922
|
function handleMobileTooltipClick(e) {
|
|
@@ -2470,7 +2470,7 @@ window.ItemTooltips = (function() {
|
|
|
2470
2470
|
optionEl.textContent = option.text;
|
|
2471
2471
|
}
|
|
2472
2472
|
|
|
2473
|
-
optionEl.addEventListener('
|
|
2473
|
+
optionEl.addEventListener('click', () => {
|
|
2474
2474
|
if (option.dismiss) {
|
|
2475
2475
|
closeDialogue(option.pureExit);
|
|
2476
2476
|
}
|
|
@@ -2520,7 +2520,7 @@ window.ItemTooltips = (function() {
|
|
|
2520
2520
|
});
|
|
2521
2521
|
|
|
2522
2522
|
// Setup close button
|
|
2523
|
-
document.querySelector('.dialogue-close').addEventListener('
|
|
2523
|
+
document.querySelector('.dialogue-close').addEventListener('click', closeDialogue);
|
|
2524
2524
|
</script>
|
|
2525
2525
|
|
|
2526
2526
|
<style>
|
|
@@ -2952,7 +2952,7 @@ window.ItemTooltips = (function() {
|
|
|
2952
2952
|
|
|
2953
2953
|
function setupEventListeners() {
|
|
2954
2954
|
const closeButton = document.querySelector('.quests-close');
|
|
2955
|
-
closeButton.addEventListener('
|
|
2955
|
+
closeButton.addEventListener('click', closeQuests);
|
|
2956
2956
|
}
|
|
2957
2957
|
|
|
2958
2958
|
function updateQuestData(questData) {
|
|
@@ -3049,7 +3049,7 @@ window.ItemTooltips = (function() {
|
|
|
3049
3049
|
<div class="quests-item-progress">${progress}</div>
|
|
3050
3050
|
`;
|
|
3051
3051
|
|
|
3052
|
-
questItem.addEventListener('
|
|
3052
|
+
questItem.addEventListener('click', () => selectQuest(questId));
|
|
3053
3053
|
return questItem;
|
|
3054
3054
|
}
|
|
3055
3055
|
|
|
@@ -4071,7 +4071,7 @@ window.ItemTooltips = (function() {
|
|
|
4071
4071
|
// Add close button handler
|
|
4072
4072
|
const closeButton = document.querySelector('.merchant-close');
|
|
4073
4073
|
if (closeButton) {
|
|
4074
|
-
closeButton.addEventListener('
|
|
4074
|
+
closeButton.addEventListener('click', () => toggleMerchant(null));
|
|
4075
4075
|
}
|
|
4076
4076
|
}
|
|
4077
4077
|
|
|
@@ -4383,15 +4383,15 @@ window.ItemTooltips = (function() {
|
|
|
4383
4383
|
const confirmBtn = placeholder.querySelector('.merchant-confirm-action');
|
|
4384
4384
|
|
|
4385
4385
|
if (decreaseBtn) {
|
|
4386
|
-
decreaseBtn.addEventListener('
|
|
4386
|
+
decreaseBtn.addEventListener('click', () => changeQuantity(-1));
|
|
4387
4387
|
}
|
|
4388
4388
|
|
|
4389
4389
|
if (increaseBtn) {
|
|
4390
|
-
increaseBtn.addEventListener('
|
|
4390
|
+
increaseBtn.addEventListener('click', () => changeQuantity(1));
|
|
4391
4391
|
}
|
|
4392
4392
|
|
|
4393
4393
|
if (confirmBtn && price > 0) {
|
|
4394
|
-
confirmBtn.addEventListener('
|
|
4394
|
+
confirmBtn.addEventListener('click', confirmAction);
|
|
4395
4395
|
}
|
|
4396
4396
|
}
|
|
4397
4397
|
|
|
@@ -5169,7 +5169,7 @@ window.ItemTooltips = (function() {
|
|
|
5169
5169
|
// Add close button handler
|
|
5170
5170
|
const closeButton = document.querySelector('.crafting-close');
|
|
5171
5171
|
if (closeButton) {
|
|
5172
|
-
closeButton.addEventListener('
|
|
5172
|
+
closeButton.addEventListener('click', () => toggleCrafting(null));
|
|
5173
5173
|
}
|
|
5174
5174
|
}
|
|
5175
5175
|
|
|
@@ -5439,7 +5439,7 @@ window.ItemTooltips = (function() {
|
|
|
5439
5439
|
const confirmBtn = placeholder.querySelector('.crafting-confirm-action');
|
|
5440
5440
|
|
|
5441
5441
|
if (confirmBtn) {
|
|
5442
|
-
confirmBtn.addEventListener('
|
|
5442
|
+
confirmBtn.addEventListener('click', confirmCrafting);
|
|
5443
5443
|
}
|
|
5444
5444
|
|
|
5445
5445
|
// Add tooltips to requirement items
|
|
@@ -6265,7 +6265,7 @@ window.ItemTooltips = (function() {
|
|
|
6265
6265
|
|
|
6266
6266
|
// Event Listeners
|
|
6267
6267
|
function setupEventListeners() {
|
|
6268
|
-
document.querySelector('.help-close').addEventListener('
|
|
6268
|
+
document.querySelector('.help-close').addEventListener('click', closeHelp);
|
|
6269
6269
|
}
|
|
6270
6270
|
|
|
6271
6271
|
// Initialize
|
|
@@ -7257,7 +7257,7 @@ window.ItemTooltips = (function() {
|
|
|
7257
7257
|
|
|
7258
7258
|
// Setup click events
|
|
7259
7259
|
hotbarSlots.forEach((slot, index) => {
|
|
7260
|
-
slot.addEventListener('
|
|
7260
|
+
slot.addEventListener('click', () => setActiveSlot(index));
|
|
7261
7261
|
});
|
|
7262
7262
|
|
|
7263
7263
|
// Setup keyboard events
|
|
@@ -7278,7 +7278,7 @@ window.ItemTooltips = (function() {
|
|
|
7278
7278
|
};
|
|
7279
7279
|
|
|
7280
7280
|
Object.entries(buttons).forEach(([id, handler]) => {
|
|
7281
|
-
document.getElementById(id).addEventListener('
|
|
7281
|
+
document.getElementById(id).addEventListener('click', handler);
|
|
7282
7282
|
});
|
|
7283
7283
|
|
|
7284
7284
|
// Setup death overlay respawn button
|
|
@@ -288,12 +288,12 @@
|
|
|
288
288
|
|
|
289
289
|
function setupEventListeners() {
|
|
290
290
|
const closeButton = document.querySelector('.backpack-close');
|
|
291
|
-
closeButton.addEventListener('
|
|
291
|
+
closeButton.addEventListener('click', closeBackpack);
|
|
292
292
|
|
|
293
293
|
// Setup slot click handlers
|
|
294
294
|
document.querySelectorAll('.backpack-slot, .backpack-wearable-slot, .backpack-hotbar-slot')
|
|
295
295
|
.forEach(slot => {
|
|
296
|
-
slot.addEventListener('
|
|
296
|
+
slot.addEventListener('click', e => {
|
|
297
297
|
e.preventDefault();
|
|
298
298
|
e.stopPropagation();
|
|
299
299
|
|
|
@@ -322,7 +322,7 @@
|
|
|
322
322
|
});
|
|
323
323
|
|
|
324
324
|
// Setup click outside containers handler for item dropping
|
|
325
|
-
document.addEventListener('
|
|
325
|
+
document.addEventListener('click', e => {
|
|
326
326
|
// Only handle if we have a held item
|
|
327
327
|
if (!heldItem) return;
|
|
328
328
|
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
// Add close button handler
|
|
61
61
|
const closeButton = document.querySelector('.crafting-close');
|
|
62
62
|
if (closeButton) {
|
|
63
|
-
closeButton.addEventListener('
|
|
63
|
+
closeButton.addEventListener('click', () => toggleCrafting(null));
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
66
|
|
|
@@ -330,7 +330,7 @@
|
|
|
330
330
|
const confirmBtn = placeholder.querySelector('.crafting-confirm-action');
|
|
331
331
|
|
|
332
332
|
if (confirmBtn) {
|
|
333
|
-
confirmBtn.addEventListener('
|
|
333
|
+
confirmBtn.addEventListener('click', confirmCrafting);
|
|
334
334
|
}
|
|
335
335
|
|
|
336
336
|
// Add tooltips to requirement items
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
optionEl.textContent = option.text;
|
|
69
69
|
}
|
|
70
70
|
|
|
71
|
-
optionEl.addEventListener('
|
|
71
|
+
optionEl.addEventListener('click', () => {
|
|
72
72
|
if (option.dismiss) {
|
|
73
73
|
closeDialogue(option.pureExit);
|
|
74
74
|
}
|
|
@@ -118,7 +118,7 @@
|
|
|
118
118
|
});
|
|
119
119
|
|
|
120
120
|
// Setup close button
|
|
121
|
-
document.querySelector('.dialogue-close').addEventListener('
|
|
121
|
+
document.querySelector('.dialogue-close').addEventListener('click', closeDialogue);
|
|
122
122
|
</script>
|
|
123
123
|
|
|
124
124
|
<style>
|
|
@@ -155,7 +155,7 @@
|
|
|
155
155
|
|
|
156
156
|
// Event Listeners
|
|
157
157
|
function setupEventListeners() {
|
|
158
|
-
document.querySelector('.help-close').addEventListener('
|
|
158
|
+
document.querySelector('.help-close').addEventListener('click', closeHelp);
|
|
159
159
|
}
|
|
160
160
|
|
|
161
161
|
// Initialize
|
|
@@ -85,7 +85,7 @@
|
|
|
85
85
|
// Add close button handler
|
|
86
86
|
const closeButton = document.querySelector('.merchant-close');
|
|
87
87
|
if (closeButton) {
|
|
88
|
-
closeButton.addEventListener('
|
|
88
|
+
closeButton.addEventListener('click', () => toggleMerchant(null));
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
91
|
|
|
@@ -397,15 +397,15 @@
|
|
|
397
397
|
const confirmBtn = placeholder.querySelector('.merchant-confirm-action');
|
|
398
398
|
|
|
399
399
|
if (decreaseBtn) {
|
|
400
|
-
decreaseBtn.addEventListener('
|
|
400
|
+
decreaseBtn.addEventListener('click', () => changeQuantity(-1));
|
|
401
401
|
}
|
|
402
402
|
|
|
403
403
|
if (increaseBtn) {
|
|
404
|
-
increaseBtn.addEventListener('
|
|
404
|
+
increaseBtn.addEventListener('click', () => changeQuantity(1));
|
|
405
405
|
}
|
|
406
406
|
|
|
407
407
|
if (confirmBtn && price > 0) {
|
|
408
|
-
confirmBtn.addEventListener('
|
|
408
|
+
confirmBtn.addEventListener('click', confirmAction);
|
|
409
409
|
}
|
|
410
410
|
}
|
|
411
411
|
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
|
|
73
73
|
function setupEventListeners() {
|
|
74
74
|
const closeButton = document.querySelector('.quests-close');
|
|
75
|
-
closeButton.addEventListener('
|
|
75
|
+
closeButton.addEventListener('click', closeQuests);
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
function updateQuestData(questData) {
|
|
@@ -169,7 +169,7 @@
|
|
|
169
169
|
<div class="quests-item-progress">${progress}</div>
|
|
170
170
|
`;
|
|
171
171
|
|
|
172
|
-
questItem.addEventListener('
|
|
172
|
+
questItem.addEventListener('click', () => selectQuest(questId));
|
|
173
173
|
return questItem;
|
|
174
174
|
}
|
|
175
175
|
|
|
@@ -179,7 +179,7 @@
|
|
|
179
179
|
|
|
180
180
|
// Event Listeners
|
|
181
181
|
function setupEventListeners() {
|
|
182
|
-
document.querySelector('.skills-close').addEventListener('
|
|
182
|
+
document.querySelector('.skills-close').addEventListener('click', closeSkills);
|
|
183
183
|
|
|
184
184
|
// Setup mobile tooltip handling
|
|
185
185
|
setupMobileTooltips();
|
|
@@ -192,10 +192,10 @@
|
|
|
192
192
|
if (!isMobile) return;
|
|
193
193
|
|
|
194
194
|
// Add click handler to skills container for event delegation
|
|
195
|
-
document.querySelector('.skills-skills-grid').addEventListener('
|
|
195
|
+
document.querySelector('.skills-skills-grid').addEventListener('click', handleMobileTooltipClick);
|
|
196
196
|
|
|
197
197
|
// Add click handler to document to close tooltips when clicking outside
|
|
198
|
-
document.addEventListener('
|
|
198
|
+
document.addEventListener('click', handleDocumentClick);
|
|
199
199
|
}
|
|
200
200
|
|
|
201
201
|
function handleMobileTooltipClick(e) {
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
{
|
|
2
|
+
"health": 100,
|
|
3
|
+
"currentRegionId": "stalkhaven",
|
|
4
|
+
"currentRegionSpawnFacingAngle": 0,
|
|
5
|
+
"currentRegionSpawnPoint": {
|
|
6
|
+
"x": 1,
|
|
7
|
+
"y": 2,
|
|
8
|
+
"z": 40
|
|
9
|
+
},
|
|
10
|
+
"skillExperience": [],
|
|
11
|
+
"backpack": {
|
|
12
|
+
"items": []
|
|
13
|
+
},
|
|
14
|
+
"hotbar": {
|
|
15
|
+
"items": [
|
|
16
|
+
{
|
|
17
|
+
"position": 0,
|
|
18
|
+
"itemId": "toy_sword"
|
|
19
|
+
}
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
"questLog": {
|
|
23
|
+
"quests": [
|
|
24
|
+
{
|
|
25
|
+
"questId": "exploring-stalkhaven",
|
|
26
|
+
"state": "active",
|
|
27
|
+
"objectiveProgress": {
|
|
28
|
+
"talk-to-mycelis": 0,
|
|
29
|
+
"talk-to-finn": 0,
|
|
30
|
+
"talk-to-sporn": 0,
|
|
31
|
+
"talk-to-mark": 0
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
]
|
|
35
|
+
},
|
|
36
|
+
"storage": {
|
|
37
|
+
"items": []
|
|
38
|
+
},
|
|
39
|
+
"wearables": {
|
|
40
|
+
"items": []
|
|
41
|
+
}
|
|
42
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{
|
|
2
|
+
"health": 100,
|
|
3
|
+
"currentRegionId": "stalkhaven-port",
|
|
4
|
+
"skillExperience": [],
|
|
5
|
+
"backpack": {
|
|
6
|
+
"items": []
|
|
7
|
+
},
|
|
8
|
+
"hotbar": {
|
|
9
|
+
"items": [
|
|
10
|
+
{
|
|
11
|
+
"position": 0,
|
|
12
|
+
"itemId": "toy_sword"
|
|
13
|
+
}
|
|
14
|
+
]
|
|
15
|
+
},
|
|
16
|
+
"questLog": {
|
|
17
|
+
"quests": [
|
|
18
|
+
{
|
|
19
|
+
"questId": "welcome-to-stalkhaven",
|
|
20
|
+
"state": "active",
|
|
21
|
+
"objectiveProgress": {
|
|
22
|
+
"talk-to-mark": 0
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
]
|
|
26
|
+
},
|
|
27
|
+
"storage": {
|
|
28
|
+
"items": []
|
|
29
|
+
},
|
|
30
|
+
"wearables": {
|
|
31
|
+
"items": []
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"health": 100,
|
|
3
|
+
"currentRegionId": "stalkhaven",
|
|
4
|
+
"currentRegionSpawnFacingAngle": 90,
|
|
5
|
+
"currentRegionSpawnPoint": {
|
|
6
|
+
"x": 32,
|
|
7
|
+
"y": 2,
|
|
8
|
+
"z": 1
|
|
9
|
+
},
|
|
10
|
+
"skillExperience": [],
|
|
11
|
+
"backpack": {
|
|
12
|
+
"items": []
|
|
13
|
+
},
|
|
14
|
+
"hotbar": {
|
|
15
|
+
"items": [
|
|
16
|
+
{
|
|
17
|
+
"position": 0,
|
|
18
|
+
"itemId": "toy_sword"
|
|
19
|
+
}
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
"questLog": {
|
|
23
|
+
"quests": []
|
|
24
|
+
},
|
|
25
|
+
"storage": {
|
|
26
|
+
"items": []
|
|
27
|
+
},
|
|
28
|
+
"wearables": {
|
|
29
|
+
"items": []
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"health": 100,
|
|
3
|
+
"currentRegionId": "stalkhaven",
|
|
4
|
+
"currentRegionSpawnFacingAngle": 0,
|
|
5
|
+
"currentRegionSpawnPoint": {
|
|
6
|
+
"x": 1,
|
|
7
|
+
"y": 2,
|
|
8
|
+
"z": 40
|
|
9
|
+
},
|
|
10
|
+
"skillExperience": [],
|
|
11
|
+
"backpack": {
|
|
12
|
+
"items": []
|
|
13
|
+
},
|
|
14
|
+
"hotbar": {
|
|
15
|
+
"items": [
|
|
16
|
+
{
|
|
17
|
+
"position": 0,
|
|
18
|
+
"itemId": "toy_sword"
|
|
19
|
+
}
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
"questLog": {
|
|
23
|
+
"quests": []
|
|
24
|
+
},
|
|
25
|
+
"storage": {
|
|
26
|
+
"items": []
|
|
27
|
+
},
|
|
28
|
+
"wearables": {
|
|
29
|
+
"items": []
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -116,17 +116,6 @@ export default class GamePlayer {
|
|
|
116
116
|
}
|
|
117
117
|
}
|
|
118
118
|
|
|
119
|
-
public static cleanup(): void {
|
|
120
|
-
// Helper method to clean up all instances (useful for server shutdown)
|
|
121
|
-
for (const [playerId, gamePlayer] of this._instances) {
|
|
122
|
-
if (gamePlayer._currentEntity) {
|
|
123
|
-
gamePlayer._currentEntity.despawn();
|
|
124
|
-
}
|
|
125
|
-
gamePlayer.player.ui.off(PlayerUIEvent.DATA, gamePlayer._onPlayerUIData);
|
|
126
|
-
}
|
|
127
|
-
this._instances.clear();
|
|
128
|
-
}
|
|
129
|
-
|
|
130
119
|
// Getters
|
|
131
120
|
public get currentCraftingEntity(): BaseCraftingEntity | undefined {
|
|
132
121
|
return this._currentCraftingEntity;
|
|
@@ -174,9 +174,12 @@ export default class GameRegion {
|
|
|
174
174
|
}
|
|
175
175
|
|
|
176
176
|
protected onPlayerLeave(player: Player) {
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
177
|
+
// We assume the player left the game on region leave, we do all cleanup here.
|
|
178
|
+
// If they didn't, there's no downside and their player object will be reinitialized
|
|
179
|
+
// when they rejoin this or another rejoin before their connection times out.
|
|
180
|
+
// If this causes issues in the future, we should move .remove to the actualy
|
|
181
|
+
// Player closed connection event.
|
|
182
|
+
GamePlayer.remove(player);
|
|
180
183
|
|
|
181
184
|
this._playerCount--;
|
|
182
185
|
|