소스 검색

fixes #1146

tags/v0.3.2
Big Bad Waffle 5 년 전
부모
커밋
0bf0eba5a2
7개의 변경된 파일2565개의 추가작업 그리고 3050개의 파일을 삭제
  1. +475
    -566
      src/server/config/maps/cave/map.json
  2. +281
    -324
      src/server/config/maps/dungeon/map.json
  3. +512
    -600
      src/server/config/maps/estuary/map.json
  4. +885
    -1110
      src/server/config/maps/fjolarok/map.json
  5. +385
    -446
      src/server/config/maps/sewer/map.json
  6. +24
    -1
      src/server/world/map.js
  7. +3
    -3
      src/server/world/worker.js

+ 475
- 566
src/server/config/maps/cave/map.json
파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
파일 보기


+ 281
- 324
src/server/config/maps/dungeon/map.json
파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
파일 보기


+ 512
- 600
src/server/config/maps/estuary/map.json
파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
파일 보기


+ 885
- 1110
src/server/config/maps/fjolarok/map.json
파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
파일 보기


+ 385
- 446
src/server/config/maps/sewer/map.json
파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
파일 보기


+ 24
- 1
src/server/world/map.js 파일 보기

@@ -10,6 +10,18 @@ let mapFile = null;
let mapScale = null;
let padding = null;

const objectifyProperties = oldProperties => {
if (!oldProperties || !oldProperties.push)
return oldProperties || {};

let newProperties = {};
oldProperties.forEach(p => {
newProperties[p.name] = p.value;
});
return newProperties;
};

module.exports = {
name: null,
path: null,
@@ -82,7 +94,9 @@ module.exports = {

mapFile = require('../' + this.path + '/' + this.name + '/map');
this.mapFile = mapFile;
this.mapFile.properties = this.mapFile.properties || {};
//Fix for newer versions of Tiled
this.mapFile.properties = objectifyProperties(this.mapFile.properties);

mapScale = mapFile.tilesets[0].tileheight;

this.custom = mapFile.properties.custom;
@@ -148,6 +162,12 @@ module.exports = {
}
}

//Fix for newer versions of Tiled
randomMap.templates
.forEach(r => {
r.properties = objectifyProperties(r.properties);
});

randomMap.templates
.filter(r => r.properties.mapping)
.forEach(function (m) {
@@ -305,6 +325,9 @@ module.exports = {
}
},
object: function (layerName, cell) {
//Fix for newer versions of tiled
cell.properties = objectifyProperties(cell.properties);

let clientObj = (layerName === 'clientObjects');
let cellInfo = this.builders.getCellInfo(cell.gid);



+ 3
- 3
src/server/world/worker.js 파일 보기

@@ -56,9 +56,9 @@ let onDbReady = function () {
_.log('Error Logged: ' + e.toString());
_.log(e.stack);

io.set({
ent: new Date(),
field: 'error',
io.setAsync({
key: new Date(),
table: 'error',
value: e.toString() + ' | ' + e.stack.toString(),
callback: function () {
process.send({


불러오는 중...
취소
저장