Skip to content

Commit bce298d

Browse files
Making dropping/picking up items cancel other actions in-progress
Also fixes a minor audit issue and makes woodcutting/mining stop their animation whenever the loop completes.
1 parent a41a063 commit bce298d

File tree

6 files changed

+76
-12
lines changed

6 files changed

+76
-12
lines changed

data/config/scenery-spawns.yaml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -604,3 +604,65 @@
604604
level: 0
605605
type: 10
606606
orientation: 0
607+
- objectId: 2213 # lumby castle west bank booth
608+
x: 3209
609+
'y': 3221
610+
level: 2
611+
type: 10
612+
orientation: 0
613+
- objectId: 2213 # lumby castle east bank booth
614+
x: 3210
615+
'y': 3221
616+
level: 2
617+
type: 10
618+
orientation: 0
619+
# Start lumby castle roof bank construction objects
620+
- objectId: 10293
621+
x: 3211
622+
'y': 3220
623+
level: 2
624+
type: 10
625+
orientation: 0
626+
- objectId: 357
627+
x: 3208
628+
'y': 3223
629+
level: 2
630+
type: 10
631+
orientation: 0
632+
- objectId: 357
633+
x: 3209
634+
'y': 3224
635+
level: 2
636+
type: 10
637+
orientation: 0
638+
- objectId: 357
639+
x: 3211
640+
'y': 3223
641+
level: 2
642+
type: 10
643+
orientation: 0
644+
- objectId: 357
645+
x: 3210
646+
'y': 3218
647+
level: 2
648+
type: 10
649+
orientation: 0
650+
- objectId: 10293
651+
x: 3211
652+
'y': 3217
653+
level: 2
654+
type: 10
655+
orientation: 0
656+
- objectId: 357
657+
x: 3211
658+
'y': 3216
659+
level: 2
660+
type: 10
661+
orientation: 1
662+
- objectId: 10293
663+
x: 3208
664+
'y': 3222
665+
level: 2
666+
type: 10
667+
orientation: 1
668+
# End lumby castle roof bank construction objects

package-lock.json

Lines changed: 10 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
"tslib": "^1.10.0",
4242
"typescript": "^3.7.2",
4343
"uuid": "^3.3.3",
44-
"yargs": "^15.0.2"
44+
"yargs": "^15.3.1"
4545
},
4646
"devDependencies": {
4747
"@halkeye/tscpaths": "0.0.9",

src/plugins/items/drop-item-plugin.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ export const action: itemAction = (details) => {
1919
player.outgoingPackets.sendUpdateSingleWidgetItem(widgets.inventory, itemSlot, null);
2020
player.playSound(soundIds.dropItem, 5);
2121
world.spawnWorldItem(item, player.position, player, 300);
22+
player.actionsCancelled.next();
2223
};
2324

2425
export default new RunePlugin({

src/plugins/items/pickup-item-plugin.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ export const action: worldItemAction = (details) => {
4444
inventory.add(item);
4545
player.outgoingPackets.sendUpdateSingleWidgetItem(widgets.inventory, slot, item);
4646
player.playSound(soundIds.pickupItem, 3);
47+
player.actionsCancelled.next();
4748
};
4849

4950
export default new RunePlugin({

src/world/skill-util/harvest-skill.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,5 +150,5 @@ export function handleHarvesting(details: ObjectActionDetails, tool: HarvestTool
150150
}
151151

152152
elapsedTicks++;
153-
});
153+
}, () => {}, () => details.player.playAnimation(null));
154154
}

0 commit comments

Comments
 (0)