Making your player mob change angle based on your mouse position is pretty simple. The following code will add such a feature to your project.
Client
onMouseMove(pDiob, pX, pY)
var x = ((this.mob.xPos + (this.mob.width / 2)) - this.getScreenPos().x) - pX
var y = pY - ((this.mob.yPos + (this.mob.height / 2)) - this.getScreenPos().y)
this.mob.angle = Math.atan2(y, x) + Math.PI
Keep in mind that an angle of 0 would be when the mouse is off to the right of the screen, so your icon for the mob should visually face the right and not upward. If you want the icon to face north, you'll need to add (Math.PI / 2) instead of Math.PI to the angle.
Client onMouseMove(pDiob, pX, pY) var x = ((this.mob.xPos + (this.mob.width / 2)) - this.getScreenPos().x) - pX var y = pY - ((this.mob.yPos + (this.mob.height / 2)) - this.getScreenPos().y) this.mob.angle = Math.atan2(y, x) + Math.PI
Keep in mind that an angle of 0 would be when the mouse is off to the right of the screen, so your icon for the mob should visually face the right and not upward. If you want the icon to face north, you'll need to add (Math.PI / 2) instead of Math.PI to the angle.