class Walker{
constructor(element,x,y,r){
this.x = x
this.y = y
this.dx = d3.randomNormal(0, 10)()
this.dy = d3.randomNormal(0, 10)()
this.circle = element.append("circle")
.attr("fill","steelblue")
.attr("stroke","black")
.attr("cx",x)
.attr("cy",y)
.attr("r",r)
}
step(dx,dy,delay){
this.x = this.x + dx * this.dx
this.y = this.y + dy * this.dy
return this.circle.transition().delay(500).duration(1000).ease(d3.easeLinear).attr("cx",this.x).attr("cy",this.y)
}
}