Compare commits
	
		
			3 Commits
		
	
	
		
			1b21fcb096
			...
			f50e388c39
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					f50e388c39 | ||
| 
						 | 
					135ce6567b | ||
| 
						 | 
					e5803eee59 | 
@@ -62,7 +62,7 @@ reloadplugin = (event, filename, pluginpath) => {
 | 
				
			|||||||
        console.info(event, filename)
 | 
					        console.info(event, filename)
 | 
				
			||||||
        pluginpath = (pluginpath ? pluginpath : './plugins/') + filename
 | 
					        pluginpath = (pluginpath ? pluginpath : './plugins/') + filename
 | 
				
			||||||
        const check = Object.keys(cfg.plugins)
 | 
					        const check = Object.keys(cfg.plugins)
 | 
				
			||||||
        console.info(`reload file:`, pluginpath)
 | 
					        console.info(`reload file: ./lib/${pluginpath}`)
 | 
				
			||||||
        const plugin = require.resolve(pluginpath)
 | 
					        const plugin = require.resolve(pluginpath)
 | 
				
			||||||
        if (plugin && require.cache[plugin]) {
 | 
					        if (plugin && require.cache[plugin]) {
 | 
				
			||||||
            // console.debug(Object.keys(cfg.plugins))
 | 
					            // console.debug(Object.keys(cfg.plugins))
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -23,7 +23,7 @@ function initMoves(bot = bot, mcData = bot.mcData) {
 | 
				
			|||||||
    movements.push(normalMove)
 | 
					    movements.push(normalMove)
 | 
				
			||||||
    movements.defaultMove = movements[0]
 | 
					    movements.defaultMove = movements[0]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    bot.pathfinder.setMovements(defaultMove)
 | 
					    bot.pathfinder.setMovements(normalMove)
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -167,8 +167,8 @@ function moveOrRide(turn = false, reverse = -1, directionLabel, message_parts2)
 | 
				
			|||||||
    // bot.once("attach", state = "vehiccel")
 | 
					    // bot.once("attach", state = "vehiccel")
 | 
				
			||||||
    if (bot.vehicle) {
 | 
					    if (bot.vehicle) {
 | 
				
			||||||
        // FIXME moveVehicle should be +-1 or 0?
 | 
					        // FIXME moveVehicle should be +-1 or 0?
 | 
				
			||||||
        const amount = Math.sign(parseInt(message_parts2[0]) || -reverse)
 | 
					        const amount = parseInt(message_parts2[0]) * -reverse
 | 
				
			||||||
        bot.moveVehicle(turn && amount || 0, !turn && amount || 0)
 | 
					        bot.moveVehicle(turn && Math.sign(amount) || 0, !turn && amount || 0)
 | 
				
			||||||
    } else {
 | 
					    } else {
 | 
				
			||||||
        command([directionLabel].concat(message_parts2))
 | 
					        command([directionLabel].concat(message_parts2))
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user