Skip to content

Commit

Permalink
fix trader.js cli
Browse files Browse the repository at this point in the history
  • Loading branch information
rom1504 committed Oct 8, 2016
1 parent 5429f90 commit 66dfdff
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions examples/trader.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,13 @@ var mcdata = require('minecraft-data')(mineflayer.version);

if(process.argv.length < 4 || process.argv.length > 6) {
console.log('Usage : node trader.js <host> <port> [<name>] [<password>]');
// process.exit(1);
} else {
var info = 'Commands :\n' +
' show villagers\n' +
' show inventory\n' +
' show trades <id>\n' +
' trade <id> <trade> [<times>]';
console.log(info);
process.exit(1);
}
console.log('Commands :\n' +
' show villagers\n' +
' show inventory\n' +
' show trades <id>\n' +
' trade <id> <trade> [<times>]');

var bot = mineflayer.createBot({
host: process.argv[2],
Expand Down

0 comments on commit 66dfdff

Please sign in to comment.