Skip to content

Instantly share code, notes, and snippets.

@FreekPaans
Created July 23, 2015 06:31
Show Gist options
  • Save FreekPaans/8d244b9601a6fc316519 to your computer and use it in GitHub Desktop.
Save FreekPaans/8d244b9601a6fc316519 to your computer and use it in GitHub Desktop.
function Vector(x, y) {
this.x = x;
this.y = y;
this.Add = function(addend) {
return new Vector(this.x + addend.x, this.y+addend.y)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment