{"versions":{"0.2.1":{"name":"gbxremote","description":"A pure JavaScript GBXRemote client.","keywords":["xml-rpc","xmlrpc","xml","rpc","gbxremote","maniaplanet","trackmania","shootmania","questmania","nadeo"],"version":"0.2.1","preferGlobal":false,"homepage":"https://github.com/MiniGod/node-gbxremote","author":{"name":"Kristjan Broder Lund","email":"kristjan.1234@gmail.com","url":"https://github.com/MiniGod"},"repository":{"type":"git","url":"git://github.com/MiniGod/node-gbxremote.git"},"bugs":{"url":"https://github.com/MiniGod/node-gbxremote/issues"},"directories":{"lib":"./lib"},"main":"./lib/gbxremote.js","dependencies":{"any-promise":"^1.1.0","barse":"~0.4.2","event-to-promise":"^0.7.0","string-to-stream":"^1.0.1","xmlrpc":"^1.3.1"},"devDependencies":{"nodemon":"^1.8.1","xo":"^0.12.1"},"scripts":{"watch":"nodemon -x npm test","test":"xo"},"engines":{"node":">=0.10"},"licenses":[{"type":"MIT","url":"https://github.com/MiniGod/node-gbxremote/raw/master/LICENSE"}],"gitHead":"2746dd1e2565a03c54be287eddd0f872b4de71de","_id":"gbxremote@0.2.1","_shasum":"84df4fbd781780dc5d692d24ac04a2d7f05ddb7c","_from":".","_npmVersion":"3.5.1","_nodeVersion":"5.6.0","_npmUser":{"name":"anonymous","email":"kristjan.1234@gmail.com"},"maintainers":[{"name":"anonymous","email":"kristjan@lund.is"}],"dist":{"shasum":"84df4fbd781780dc5d692d24ac04a2d7f05ddb7c","size":5184,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/gbxremote/-/gbxremote-0.2.1.tgz","integrity":"sha512-SMehu6Y6ndq2Qgp9VxAb8Np3f+UUD+RWoW2SAMaxzGS96rWXyr4T1GGkecO0HHtxeH1m7pEh4FJWB8a/6aM2XQ=="},"_npmOperationalInternal":{"host":"packages-9-west.internal.npmjs.com","tmp":"tmp/gbxremote-0.2.1.tgz_1455752650945_0.7386600736062974"},"publish_time":1455752655126,"_hasShrinkwrap":false,"_cnpm_publish_time":1455752655126,"_cnpmcore_publish_time":"2021-12-18T10:58:47.141Z","contributors":[]},"0.2.0":{"name":"gbxremote","description":"A pure JavaScript GBXRemote client.","keywords":["xml-rpc","xmlrpc","xml","rpc","gbxremote","maniaplanet","trackmania","shootmania","questmania","nadeo"],"version":"0.2.0","preferGlobal":false,"homepage":"https://github.com/MiniGod/node-gbxremote","author":{"name":"Kristjan Broder Lund","email":"kristjan.1234@gmail.com","url":"https://github.com/MiniGod"},"repository":{"type":"git","url":"git://github.com/MiniGod/node-gbxremote.git"},"bugs":{"url":"https://github.com/MiniGod/node-gbxremote/issues"},"directories":{"lib":"./lib"},"main":"./lib/gbxremote.js","dependencies":{"any-promise":"^1.1.0","barse":"~0.4.2","event-to-promise":"^0.7.0","string-to-stream":"^1.0.1","xmlrpc":"^1.3.1"},"devDependencies":{"nodemon":"^1.8.1","xo":"^0.12.1"},"scripts":{"watch":"nodemon -x npm test","test":"xo"},"engines":{"node":">=0.10"},"licenses":[{"type":"MIT","url":"https://github.com/MiniGod/node-gbxremote/raw/master/LICENSE"}],"gitHead":"6ed459f9630ce3ae80d767481fc3626e789076fd","_id":"gbxremote@0.2.0","_shasum":"efa708078d68f67e86b82de82a8497109d2a2101","_from":".","_npmVersion":"3.5.1","_nodeVersion":"5.6.0","_npmUser":{"name":"anonymous","email":"kristjan.1234@gmail.com"},"maintainers":[{"name":"anonymous","email":"kristjan@lund.is"}],"dist":{"shasum":"efa708078d68f67e86b82de82a8497109d2a2101","size":5684,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/gbxremote/-/gbxremote-0.2.0.tgz","integrity":"sha512-Omf43JhJ/DOsnqET4X8JGXL5brSwbj8269eLwNeY0ihqlmXNrebnZb9NhnVwkoCag2kF4YQKttaVt0Q/KQEBbA=="},"_npmOperationalInternal":{"host":"packages-5-east.internal.npmjs.com","tmp":"tmp/gbxremote-0.2.0.tgz_1455675322652_0.22720785485580564"},"publish_time":1455675325262,"_hasShrinkwrap":false,"_cnpm_publish_time":1455675325262,"_cnpmcore_publish_time":"2021-12-18T10:58:47.350Z","contributors":[]},"0.1.4":{"name":"gbxremote","description":"A pure JavaScript GBXRemote client.","keywords":["xml-rpc","xmlrpc","xml","rpc","gbxremote","maniaplanet","trackmania","shootmania","questmania","nadeo"],"version":"0.1.4","preferGlobal":false,"homepage":"https://github.com/MiniGod/node-gbxremote","author":{"name":"Kristjan Broder Lund","email":"kristjan.1234@gmail.com","url":"https://github.com/MiniGod"},"repository":{"type":"git","url":"git://github.com/MiniGod/node-gbxremote.git"},"bugs":{"url":"https://github.com/MiniGod/node-gbxremote/issues"},"directories":{"lib":"./lib"},"main":"./lib/gbxremote.js","dependencies":{"sax":"0.4.x","xmlbuilder":"0.3.1","barse":"~0.4.2"},"devDependencies":{"vows":"0.6.x"},"scripts":{"test":"make test"},"engines":{"node":">=0.4","npm":">=1.0.0"},"licenses":[{"type":"MIT","url":"https://github.com/MiniGod/node-gbxremote/raw/master/LICENSE"}],"readmeFilename":"README.md","_id":"gbxremote@0.1.4","dist":{"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/gbxremote/-/gbxremote-0.1.4.tgz","shasum":"c7ed22582e56051b4e17601b3dd5a3004eeefd43","size":17895,"noattachment":false,"integrity":"sha512-UK5BzZEm4bVxsNL2nwD4nBJplmmRk+84+OwT5AtnVSUnQ9M/PElaLoPAeT72zSTzQkp1IKwlOtLFCVyl0a/42Q=="},"_from":".","_npmVersion":"1.3.21","_npmUser":{"name":"anonymous","email":"kristjan.1234@gmail.com"},"maintainers":[{"name":"anonymous","email":"kristjan@lund.is"}],"publish_time":1388425083545,"_hasShrinkwrap":false,"_cnpm_publish_time":1388425083545,"_cnpmcore_publish_time":"2021-12-18T10:58:47.623Z","contributors":[]},"0.1.3":{"name":"gbxremote","description":"A pure JavaScript GBXRemote client.","keywords":["xml-rpc","xmlrpc","xml","rpc","gbxremote","maniaplanet","trackmania","shootmania","questmania","nadeo"],"version":"0.1.3","preferGlobal":false,"homepage":"https://github.com/MiniGod/node-gbxremote","author":{"name":"Kristjan Broder Lund","email":"kristjan.1234@gmail.com","url":"https://github.com/MiniGod"},"repository":{"type":"git","url":"git://github.com/MiniGod/node-gbxremote.git"},"bugs":{"url":"https://github.com/MiniGod/node-gbxremote/issues"},"directories":{"lib":"./lib"},"main":"./lib/gbxremote.js","dependencies":{"sax":"0.4.x","xmlbuilder":"0.3.1"},"devDependencies":{"vows":"0.6.x"},"scripts":{"test":"make test"},"engines":{"node":">=0.4","npm":">=1.0.0"},"licenses":[{"type":"MIT","url":"https://github.com/MiniGod/node-gbxremote/raw/master/LICENSE"}],"readmeFilename":"README.md","_id":"gbxremote@0.1.3","dist":{"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/gbxremote/-/gbxremote-0.1.3.tgz","shasum":"8309989094adef2b787f937a7c4358fc5c96ff46","size":18278,"noattachment":false,"integrity":"sha512-Hz/IKcvBHgu7ZLT7+wZOSDrfCJs4BXloxWnKNFmGVD1E7jh2UakXe9FT4ClSGiYLKGdvwJwLF+5JpNi0etnlLg=="},"_from":".","_npmVersion":"1.3.21","_npmUser":{"name":"anonymous","email":"kristjan.1234@gmail.com"},"maintainers":[{"name":"anonymous","email":"kristjan@lund.is"}],"publish_time":1388388004614,"_hasShrinkwrap":false,"_cnpm_publish_time":1388388004614,"_cnpmcore_publish_time":"2021-12-18T10:58:47.995Z","contributors":[]},"0.1.2":{"name":"gbxremote","description":"A pure JavaScript GBXRemote client.","keywords":["xml-rpc","xmlrpc","xml","rpc","gbxremote","maniaplanet","trackmania","shootmania","questmania","nadeo"],"version":"0.1.2","preferGlobal":false,"homepage":"https://github.com/MiniGod/node-gbxremote","author":{"name":"Kristjan Broder Lund","email":"kristjan.1234@gmail.com","url":"https://github.com/MiniGod"},"repository":{"type":"git","url":"git://github.com/MiniGod/node-gbxremote.git"},"bugs":{"url":"https://github.com/MiniGod/node-gbxremote/issues"},"directories":{"lib":"./lib"},"main":"./lib/gbxremote.js","dependencies":{"sax":"0.4.x","xmlbuilder":"0.3.1"},"devDependencies":{"vows":"0.6.x"},"scripts":{"test":"make test"},"engines":{"node":">=0.4","npm":">=1.0.0"},"licenses":[{"type":"MIT","url":"https://github.com/MiniGod/node-gbxremote/raw/master/LICENSE"}],"_id":"gbxremote@0.1.2","dist":{"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/gbxremote/-/gbxremote-0.1.2.tgz","shasum":"a181c47954d8c0cc7555954743f0d4a51862b9ec","size":11480,"noattachment":false,"integrity":"sha512-rL6ggZBuS1zb2H2YL7GgEOOR70qyGrKDEKnBPLArvykt7e0y3hnthxWPkyM1ZE02hXc0aGeAz8PF7KeQGF3kGg=="},"_npmVersion":"1.1.59","_npmUser":{"name":"anonymous","email":"kristjan.1234@gmail.com"},"maintainers":[{"name":"anonymous","email":"kristjan@lund.is"}],"publish_time":1346373379735,"_hasShrinkwrap":false,"_cnpm_publish_time":1346373379735,"_cnpmcore_publish_time":"2021-12-18T10:58:48.274Z","contributors":[]},"0.1.1":{"name":"gbxremote","description":"A pure JavaScript GBXRemote client.","keywords":["xml-rpc","xmlrpc","xml","rpc","gbxremote","trackmania"],"version":"0.1.1","preferGlobal":false,"homepage":"https://github.com/MiniGod/node-gbxremote","author":{"name":"Kristjan Broder Lund","email":"kristjan.1234@gmail.com","url":"https://github.com/MiniGod"},"repository":{"type":"git","url":"git://github.com/MiniGod/node-gbxremote.git"},"bugs":{"url":"https://github.com/MiniGod/node-gbxremote/issues"},"directories":{"lib":"./lib"},"main":"./lib/gbxremote.js","dependencies":{"sax":"0.4.x","xmlbuilder":"0.3.1"},"devDependencies":{"vows":"0.6.x"},"scripts":{"test":"make test"},"engines":{"node":">=0.4","npm":">=1.0.0"},"licenses":[{"type":"MIT","url":"https://github.com/MiniGod/node-gbxremote/raw/master/LICENSE"}],"_npmUser":{"name":"anonymous","email":"kristjan.1234@gmail.com"},"_id":"gbxremote@0.1.1","optionalDependencies":{},"_engineSupported":true,"_npmVersion":"1.1.12","_nodeVersion":"v0.6.14","_defaultsLoaded":true,"dist":{"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/gbxremote/-/gbxremote-0.1.1.tgz","shasum":"51b831ecb7743510fdde34fccf64ce4b240c27f3","size":9977,"noattachment":false,"integrity":"sha512-V6NDVDynTLnXJyigr7fHzIrVsitHdDiU384DF8ddcFAOl8WjOWo9IYyLWjmOvV2MTmtzn5TratMtzBK44wUG5w=="},"maintainers":[{"name":"anonymous","email":"kristjan@lund.is"}],"publish_time":1340419098140,"_hasShrinkwrap":false,"_cnpm_publish_time":1340419098140,"_cnpmcore_publish_time":"2021-12-18T10:58:48.546Z","contributors":[]},"0.1.0":{"name":"gbxremote","description":"A pure JavaScript GBXRemote client.","keywords":["xml-rpc","xmlrpc","xml","rpc","gbxremote","trackmania"],"version":"0.1.0","preferGlobal":false,"homepage":"https://github.com/MiniGod/node-gbxremote","author":{"name":"Kristjan Broder Lund","email":"kristjan.1234@gmail.com","url":"https://github.com/MiniGod"},"repository":{"type":"git","url":"git://github.com/MiniGod/node-gbxremote.git"},"bugs":{"url":"https://github.com/MiniGod/node-gbxremote/issues"},"directories":{"lib":"./lib"},"main":"./lib/gbxremote.js","dependencies":{"sax":"0.4.x","xmlbuilder":"0.3.1"},"devDependencies":{"vows":"0.6.x"},"scripts":{"test":"make test"},"engines":{"node":">=0.4","npm":">=1.0.0"},"licenses":[{"type":"MIT","url":"https://github.com/MiniGod/node-gbxremote/raw/master/LICENSE"}],"_npmUser":{"name":"anonymous","email":"kristjan.1234@gmail.com"},"_id":"gbxremote@0.1.0","optionalDependencies":{},"_engineSupported":true,"_npmVersion":"1.1.12","_nodeVersion":"v0.6.14","_defaultsLoaded":true,"dist":{"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/gbxremote/-/gbxremote-0.1.0.tgz","shasum":"3b0324278f58206d3140b9f12743799afb0c29ca","size":9944,"noattachment":false,"integrity":"sha512-j5FEswiY6fUJ94gMT7Gn6VMI4V8xA8ZLDngm5pnZ8VLK26OJ7+x7rqdV3j9eicoP3IsNp4SO2Th1/uL1t0VZsw=="},"maintainers":[{"name":"anonymous","email":"kristjan@lund.is"}],"publish_time":1340418309238,"_hasShrinkwrap":false,"_cnpm_publish_time":1340418309238,"_cnpmcore_publish_time":"2021-12-18T10:58:48.754Z","contributors":[]}},"dist-tags":{"latest":"0.2.1"},"name":"gbxremote","time":{"created":"2022-01-27T02:16:48.883Z","modified":"2022-01-27T02:16:48.883Z","0.2.1":"2016-02-17T23:44:15.126Z","0.2.0":"2016-02-17T02:15:25.262Z","0.1.4":"2013-12-30T17:38:03.545Z","0.1.3":"2013-12-30T07:20:04.614Z","0.1.2":"2012-08-31T00:36:19.735Z","0.1.1":"2012-06-23T02:38:18.140Z","0.1.0":"2012-06-23T02:25:09.238Z"},"readme":"Node-GbxRemote\n===\n\nJavaScript ([node.js](http://nodejs.org)) port of [GbxRemote](http://code.google.com/p/manialive/source/browse/trunk/libraries/DedicatedApi/Xmlrpc/Client.php) by [Nadeo](http://www.nadeo.com),\nwhich is built on [Incutio XML-RPC Library](http://scripts.incutio.com/xmlrpc/).\n\nUsed to communicate with [ManiaPlanet](http://www.maniaplanet.com) servers.\n\n*Note: The API may, or may not change!*\n\nInstall\n---\n\n```bash\nnpm install gbxremote\n```\n\nTo Use\n---\n\nLook in [/examples/](https://github.com/MiniGod/node-gbxremote/tree/master/example) for all examples.\n\n---\n\nThe following examples expects that `var gbxremote = require('gbxremote')`.\n\n### Connecting:\n\nTo connect to a server, use `var client = gbxremote.createClient(port, [host]);`\n\n*Examples of ways to connect to the server:*\n\n```javascript\n// Connect with port only\nvar client = gbxremote.createClient(5000);\nclient.on('connect', onConnect);\n\n// Connect with port and hostname\nvar client = gbxremote.createClient(5000, 'localhost');\nclient.on('connect', onConnect);\n\n// Connect with port and ip\nvar client = gbxremote.createClient(5000, '127.0.0.1');\nclient.on('connect', onConnect);\n\n// Create client and connect explicitly\nvar client = new gbxremote.Client(5000, 'localhost');\nclient.connect().then(onConnect);\n```\n\n### Querying:\n\nQueries are sent to the server by calling `client.query(method, [params]);`  \n`client.query` returns a promise.\n\n*Queries before the connect event has been emitted will be queued and sent on connect!*\n\n[See the full list of methods.](http://methods.xaseco.org/methodstmc.php)\n\n```javascript\nvar client = gbxremote.createClient(5000);\n\nclient.on('connect', function() {\n\n\t// GetVersion does not take any params.\n\tclient.query('GetVersion').then(function (res) {\n\t\tconsole.log('Server version:', res.join(', '));\n\t}).catch(function(err) {\n\t\tconsole.error('Error when querying server:', err);\n\t});\n\t\n\t// GetPlayerInfo takes 2 parameters, 1 optional.\n\t// GetPlayerInfo(string login, [int compatibility])\n\tclient.query('GetPlayerInfo', ['minigod']).then(function (res) {\n\t\tconsole.log('Player info:');\n\t\tconsole.log(res);\n\t}).catch(function (err) {\n\t\tconsole.error('Error getting player info:', err);\n\t});\n});\n```\n\n### Disconnecting:\n\n`client.terminate();`\n\n### Events:\n\n#### Event: connect()\n\nEmitted when connection to the server is successfull.  \nReady to receive queries!\n\n```javascript\nvar client = gbxremote.createClient(5000);\n\nclient.on('connect', function() {\n\tconsole.log('Connection successfull! Lets do some queries!');\n\tclient.query('EnableCallbacks', true);\n});\n```\nIf there is a problem connecting, the 'connect' event will not be emitted, the 'error' event will be emitted with the exception.\n\n#### Event: error(err)\n\nEmitted when:\n* Socket errors *(host is not listening on that port, loose connection, etc.)*\n* Handshake fails *(host* ***is*** *listening on that port, but its not a ManiaPlanet (GbxRemote 2) server)*\n\n```javascript\nvar client = gbxremote.createClient(5000);\n\nclient.on('error', function(err) {\n\tconsole.error('Connection failed: ' + err);\n});\n```\n\n#### Event: callback(method, params)\n\nAfter sending `EnableCallbacks(true)` to the server, it will send you callbacks when stuff happend on the server.  \nEg:\n* `ManiaPlanet.ServerStart`\n* `ManiaPlanet.ServerStop`\n* `ManiaPlanet.PlayerConnect`\n* `ManiaPlanet.PlayerChat`\n\n[See the full list of callbacks](http://server.xaseco.org/callbacks2.php)\n\n```javascript\nvar client = gbxremote.createClient(5000);\n\nclient.on('connect', function() {\n\tclient.query('SetApiVersion', ['2012-06-19']);\n\tclient.query('EnableCallbacks', [true]);\n});\n\nclient.on('callback', function(method, params) {\n\tconsole.log(\"Callback from server: %s - %d params\", method, params.length);\n\t\n\t// This would be the typical place to have a switch statement. Please dont do that. Use the events, as shown below.\n});\n```\n\n#### Event: \\<method\\>(params)\n\nCallbacks will also emit separate events for each method. It's hard to explain. Learn from example:\n\n```javascript\nvar client = gbxremote.createClient(5000);\n\nclient.on('connect', function() {\n\t// Before enabling callbacks, make sure you set the latest API.\n\tclient.query('SetApiVersion', ['2012-06-19']);\n\tclient.query('EnableCallbacks', [true]);\n});\n\n// ManiaPlanet.PlayerConnect(string Login, bool IsSpectator);\nclient.on('ManiaPlanet.PlayerConnect', function(params) {\n\tconsole.log('%s just joined as a %s', params[0], params[1] ? 'spectator' : 'player');\n});\n\n// ManiaPlanet.PlayerDisconnect(string Login); \nclient.on('ManiaPlanet.PlayerDisconnect', function(params) {\n\tconsole.log('%s left the server', params[0]);\n});\n```\n\nThese events can basically take over the big switch statements that is normal in todays server controllers.\n\n#### Event: close(had_error)\n\nEmitted once the socket is fully closed.\nThe argument had_error is a boolean which says if the socket was closed due to a transmission error.\n\n```javascript\nvar client = gbxremote.createClient(5000);\n\nclient.on('connect', function() {\n\t// Connected...\n\t\n\t// Do stuff?\n\t\n\t// Disconnect\n\tclient.terminate();\n});\n\nclient.on('close', function(had_error) {\n\tconsole.log('Connection to the server has been closed');\n});\n``` \n\nThe License (MIT)\n---\n\nReleased under the MIT license. See the LICENSE file for the complete wording.","users":{}}