UNPKG
@storiny/obelisk
Version:
latest (1.1.3)
1.1.3
1.0.0
Build isometrics elements with canvas
github.com/storiny/obelisk
storiny/obelisk
@storiny/obelisk
/
src
/
geom
/
Point.ts
15 lines
(11 loc)
•
283 B
text/typescript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
export
class
Point
{
public
x
:
number
;
public
y
:
number
;
constructor
(
x
?:
number
,
y
?:
number
) {
this
.
x
= x ===
undefined
?
0
: x;
this
.
y
= y ===
undefined
?
0
: y; }
public
toString
():
string
{
return
`[Point x:
${
this
.x}
, y:
${
this
.y}
]`
; } }