fly

From SmartBots Developers Docs
Jump to: navigation, search

Starts or stops flying.

Bot.fly(enableFlying);

Reference

This command accepts the following parameters:

Variable Required Description


Input:
enableFlying yes boolean, true to start flying, false to stom
Output:
Function returns a Promise with the following data:
success bool true if command completed successfully
error string error string if command has failed


Examples

// Bots Playground script: [TEST] Fly (build 1 by Glaznah Gassner)
Bot.fly(true);

// Wait a bit and stop flying
await process.sleep(5_000);

Bot.fly(false);

// Gracefully exit the test script
process.exit();