- edited description
Sensor event triggers only once
Issue #3
resolved
Steps to reproduce: Go to url: http://bitsquest.bitbucket.org/index.html#2
run this code:
this.on('start', function() {
this.thrusters.right(true);
this.on('sensor:left', function(contact) {
console.log('left ' + contact)
this.thrusters.left(true)
this.thrusters.right(false)
});
this.on('sensor:right', function(contact) {
console.log('right ' + contact);
this.thrusters.left(false);
this.thrusters.right(true);
})
})
Expected result: the robot goes in both directions from one wall to another
Actual result: Robot stops on the second iteration
Comments (5)
-
reporter -
reporter - edited description
-
reporter - edited description
Updated steps for faster to reproducing
-
Account Deactivated - changed status to on hold
Sensors should fire correctly with both false and true "touching" statuses. Give it a shot now.
-
reporter - changed status to resolved
verified fixed
- Log in to comment