Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- _drawPointOrb(ctx,pt){
- let radius = 3;
- if(this.Layer.Level){
- this._applyTransform();
- let transformed = this.Transformation.MultiplyVec2(pt);
- let mouse = new Engine.Vector2(this.Layer.Level.Controller.Mouse.LastX, this.Layer.Level.Controller.Mouse.LastY);
- if(mouse.Distance(transformed) <= 10){
- radius = 15;
- }
- }
- ctx.moveTo(pt.X - this._optimized[0] + Math.cos(0)*radius,pt.Y - this._optimized[2] + Math.sin(0)*radius);
- ctx.arc(pt.X - this._optimized[0],pt.Y - this._optimized[2],radius,0,2*Math.PI,false);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement