tree command

This commit is contained in:
Hri7566 2021-05-12 13:56:18 +00:00
parent e2a1f677fb
commit 811e90fcde
1 changed files with 12 additions and 0 deletions

View File

@ -809,4 +809,16 @@ module.exports = (bot) => {
}
});
}, false);
bot.addCommand(['tree', 'fruit', 'fruits'], 0, msg => {
db.getLocation(msg.p._id, location => {
if(location === "outside") {
db.getFruits(function(num_fruits) {
sendChat("Friend "+msg.p.name+": " + num_fruits + ".");
});
} else {
sendChat(rando("You can't even see it from "+location+", let alone any fruit that may theoretically have grown on it.", "<Schrödinger's fruit>", "You don't see a tree "+location+".", "None in sight."));
}
});
}, false);
}