diff --git a/package.json b/package.json index 1b1c624..8c296db 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,7 @@ ], "main": "lib/index.js", "author": "Michael Morrison", - "version": "0.2.20", + "version": "0.2.21", "repository" : { "type" : "git", "url" : "https://github.com/sonicsnes/node-gamedig.git" diff --git a/protocols/starmade.js b/protocols/starmade.js index a47fb8d..5d7aa8c 100644 --- a/protocols/starmade.js +++ b/protocols/starmade.js @@ -43,7 +43,7 @@ module.exports = require('./core').extend({ return true; } - if(typeof data[3] == 'number') state.raw.version = data[3]; + if(typeof data[3] == 'number') state.raw.version = data[3].toFixed(7).replace(/0+$/, ''); if(typeof data[4] == 'string') state.name = data[4]; if(typeof data[5] == 'string') state.raw.description = data[5]; if(typeof data[7] == 'number') state.raw.numplayers = data[7];