Este site funciona melhor com JavaScript.
Página inicial
Explorar
Ajuda
Cadastrar
Acessar
gitlord
/
isleward
espelhamento de
https://gitlab.com/Isleward/isleward.git
Observar
1
Favorito
0
Fork
0
Código
Issues
0
Versões
203
Wiki
Atividade
Ver código fonte
bug
#1822
: Fixed an issue where name sprites weren't updating client side
tags/v0.10.0^2
Shaun
2 anos atrás
pai
f4a9d18ba2
commit
df334c4581
2 arquivos alterados
com
8 adições
e
2 exclusões
Visão dividida
Opções de diferenças
Mostrar estatísticas
Baixar arquivo de patch
Baixar arquivo de diferenças
+6
-1
src/client/js/objects/objects.js
+2
-1
src/server/config/clientConfig.js
+ 6
- 1
src/client/js/objects/objects.js
Ver arquivo
@@ -243,13 +243,18 @@ define([
if ((!obj.sprite) && (template.sheetName))
obj.sprite = renderer.buildObject(obj);
if ((!obj.nameSprite) && (template.name)) {
if (template.name) {
if (obj.nameSprite)
renderer.destroyObject({ sprite: obj.nameSprite });
obj.nameSprite = renderer.buildText({
layerName: 'effects',
text: template.name,
x: (obj.x * scale) + (scale / 2),
y: (obj.y * scale) + scale
});
obj.nameSprite.visible = config.showNames;
}
if ((template.x !== 0) || (template.y !== 0)) {
+ 2
- 1
src/server/config/clientConfig.js
Ver arquivo
@@ -42,7 +42,8 @@ const config = {
spriteSizes: {
'images/tiles.png': 8,
'images/walls.png': 8,
'images/objects.png': 8
'images/objects.png': 8,
'images/mobs.png': 8
},
blockingTileIndices: [
6, 7, 54, 55, 62, 63, 154, 189, 190, 192, 193, 194, 195, 196, 197
Escrever
Pré-visualização
Carregando…
Cancelar
Salvar