convert classes to es6
(cherry picked from commit e7615d49a4071fe5b5f192884f142c9f3385211a)
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
window.IsometricRenderer = class {
|
||||
import TextCoord from "./TextCoord.js";
|
||||
import Point from "./Point.js";
|
||||
import Triangle from "./Triangle.js";
|
||||
|
||||
export default class IsometricRenderer {
|
||||
|
||||
// http://jsfiddle.net/xzL58dha/3/
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
window.Point = class {
|
||||
export default class Point {
|
||||
constructor(x, y) {
|
||||
this.x = x ? x : 0;
|
||||
this.y = y ? y : 0;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
window.TextCoord = class {
|
||||
export default class TextCoord {
|
||||
constructor(u, v) {
|
||||
this.u = u ? u : 0;
|
||||
this.v = v ? v : 0;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
window.Triangle = class {
|
||||
export default class Triangle {
|
||||
constructor(p0, p1, p2, t0, t1, t2) {
|
||||
this.p0 = p0;
|
||||
this.p1 = p1;
|
||||
|
||||
Reference in New Issue
Block a user