fix:修复小bug

This commit is contained in:
ShakeFlower 2025-05-23 11:01:27 +08:00
parent 79c82025ee
commit 507465de0e
2 changed files with 2 additions and 2 deletions

View File

@ -3105,7 +3105,7 @@ control.prototype.playSound = function (sound, pitch, inputCallback) {
playingSoundList.push(sound);
const callback = () => {
playingSoundList = playingSoundList.filter((soundName) => soundName !== sound);
inputCallback();
if (inputCallback) inputCallback();
}
try {
if (core.musicStatus.audioContext != null) {

View File

@ -2550,7 +2550,7 @@ var plugins_bb40132b_638b_4a9f_b028_d3fe47acc8d1 =
if (!sortFunc) sortFunc = (itemId1, itemId2) => {
const item1Count = itemsUsedCount[itemId1] || 0,
item2Count = itemsUsedCount[itemId2] || 0;
return item1Count - item2Count;
return item2Count - item1Count;
}
let list = [];