Parcourir la source

fixed no particles on drops and other players being able to see your drops

tags/v0.3.0
Big Bad Waffle il y a 5 ans
Parent
révision
4b8d9e24de
2 fichiers modifiés avec 5 ajouts et 17 suppressions
  1. +4
    -16
      src/client/js/components/chest.js
  2. +1
    -1
      src/server/config/quests/templates/questLootGen.js

+ 4
- 16
src/client/js/components/chest.js Voir le fichier

@@ -30,19 +30,12 @@ define([
return {
type: 'chest',

ownerId: null,
ownerName: null,

init: function (blueprint) {
if (this.ownerId !== -1) {
if (!window.player) {
this.hideSprite();
return;
}

if (this.ownerId !== window.player.serverId) {
this.hideSprite();
return;
}
if (this.ownerName && (!window.player || window.player.name !== this.ownerName)) {
this.obj.sheetName = null;
return;
}

let index = indices[this.obj.cell];
@@ -71,11 +64,6 @@ define([
}
}
});
},

hideSprite: function () {
if (this.obj.sprite)
this.obj.sprite.visible = false;
}
};
});

+ 1
- 1
src/server/config/quests/templates/questLootGen.js Voir le fichier

@@ -69,7 +69,7 @@ module.exports = {
quantity: 1,
quest: true,
sprite: this.item.sprite,
ownerId: this.obj.serverId
ownerName: this.obj.name
});
},



Chargement…
Annuler
Enregistrer