so basically
var blue = createSprite(200, 200);
var speed = 1;
var dir = randomNumber(0, 360);
function draw() {
background("white");
drawSprites();
blue.setSpeedAndDirection(speed, dir);
}
setInterval(function() {
dir = randomNumber(0, 360);
}, randomNumber(3000, 4000));//every 1000 is a second i think